VirtualBox

Changeset 3557 in kBuild


Ignore:
Timestamp:
Feb 28, 2022 10:50:32 PM (3 years ago)
Author:
bird
Message:

Early qt6.kmk unit code.

File:
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/kBuild/units/qt6.kmk

    r3556 r3557  
    11# $Id$
    22## @file
    3 # Qt 5 unit.
    4 #
    5 
    6 #
    7 # Copyright (c) 2008-2017 knut st. osmundsen <[email protected]>
     3# Qt 6 unit.
     4#
     5
     6#
     7# Copyright (c) 2008-2022 knut st. osmundsen <[email protected]>
    88#
    99# This file is part of kBuild.
     
    3333
    3434
    35 ifdef UNIT_qt5
    36  $(error kBuild: The qt5 unit was included twice!)
    37 endif
    38 UNIT_qt5 = qt5
     35ifdef UNIT_qt6
     36 $(error kBuild: The qt6 unit was included twice!)
     37endif
     38UNIT_qt6 = qt6
    3939
    4040
     
    5151
    5252#
    53 # The QT5 SDK.
    54 #
    55 # This is implemented here rather than in sdks/QT5.kmk to enforce the global USES.
     53# The QT6 SDK.
     54#
     55# This is implemented here rather than in sdks/QT6.kmk to enforce the global USES.
    5656# It also makes things easier to develop, with fewer files I mean.
    5757#
    5858## @todo the SDK might actually not be necessary as it turns out... For now it servers
    5959# a purpose if the host differs from the target, in theory at least.
    60 SDK_QT5 = Qt5
     60SDK_QT6 = Qt6
    6161
    6262# SDK Specific Properties
    63 #       PATH_SDK_QT5           - The general Qt5 root directory.
    64 #       PATH_SDK_QT5_INC       - The include directory.
    65 #       PATH_SDK_QT5_LIB.amd64 - The lib directory for AMD64.
    66 #       PATH_SDK_QT5_LIB.x86   - The lib directory for X86.
    67 #       PATH_SDK_QT5_LIB       - The lib directory for KBUILD_TARGET.
    68 ifndef PATH_SDK_QT5
    69  PATH_SDK_QT5 := $(firstword $(rsort $(wildcard $(KBUILD_DEVTOOLS_TRG)/qt/v5*)))
    70  ifeq ($(PATH_SDK_QT5),)
     63#       PATH_SDK_QT6           - The general Qt6 root directory.
     64#       PATH_SDK_QT6_INC       - The include directory.
     65#       PATH_SDK_QT6_LIB.amd64 - The lib directory for AMD64.
     66#       PATH_SDK_QT6_LIB.x86   - The lib directory for X86.
     67#       PATH_SDK_QT6_LIB       - The lib directory for KBUILD_TARGET.
     68ifndef PATH_SDK_QT6
     69 PATH_SDK_QT6 := $(firstfile $(rversortfiles $(qwildcard ,$(KBUILD_DEVTOOLS_TRG)/qt/v6*)))
     70 ifeq ($(PATH_SDK_QT6),)
    7171  # If target == host, try look for Qt in the various platform specific places.
    7272  ifeq ($(KBUILD_TARGET),$(KBUILD_HOST))
    7373   ifeq ($(KBUILD_TARGET),darwin)
    74     PATH_SDK_QT5 := $(patsubst %/Frameworks/QtCore.framework/Versions/5,%,$(firstword $(wildcard /Library/Frameworks/QtCore.framework/Versions/5)))
     74    PATH_SDK_QT6 := $(patsubst %/Frameworks/QtCore.framework/Versions/6,%,$(firstword $(wildcard /Library/Frameworks/QtCore.framework/Versions/6)))
    7575   else ifeq ($(KBUILD_TARGET),win)
    7676    # No idea here yet...
     
    7878    # No port...
    7979   else
    80     # The Unices. Includes and esp. libs are tricky, so override the PATH_SDK_QT5_LIB* stuff if it doesn't work.
    81     # Try find the general root of thing by looking for the qt4to5 program, if not found, then look for rcc.
    82     PATH_SDK_QT5 := $(patsubst %/bin/qt4to5-qt5,%,$(firstword $(wildcard \
    83         /usr/bin/qt4to5-qt5 \
    84         /usr/local/bin/qt4to5-qt5 \
    85         /usr/qt/5/bin/qt4to5-qt5 \
    86         /usr/share/qt5/bin/qt4to5-qt5 \
     80    # The Unices. Includes and esp. libs are tricky, so override the PATH_SDK_QT6_LIB* stuff if it doesn't work.
     81    # Try find the general root of thing by looking for the rcc program, as there seems to be no qt6 specific one to look for.
     82    PATH_SDK_QT6 := $(patsubst %/bin/rcc-qt6,%,$(firstword $(wildcard \
     83        /usr/bin/rcc-qt6 \
     84        /usr/local/bin/rcc-qt6 \
     85        /usr/qt/6/bin/rcc-qt6 \
     86       $(if $(intersects $(KBUILD_HOST_ARCH),$(KBUILD_ARCHES_64)),/usr/lib64/qt6/bin/rcc-qt6) \
     87       /usr/lib/qt6/bin/rcc-qt6 \
     88        /usr/share/qt6/bin/rcc-qt6 \
    8789        )))
    88     ifeq ($(PATH_SDK_QT5),)
    89      PATH_SDK_QT5 := $(patsubst %/bin/qt4to5,%,$(firstword $(wildcard \
    90         /usr/bin/qt4to5 \
    91         /usr/local/bin/qt4to5 \
    92         /usr/qt/5/bin/qt4to5 \
    93         /usr/share/qt5/bin/qt4to5 \
    94         )))
    95     endif
    96     ifeq ($(PATH_SDK_QT5),)
    97      PATH_SDK_QT5 := $(patsubst %/bin/rcc-qt5,%,$(firstword $(wildcard \
    98         /usr/bin/rcc-qt5 \
    99         /usr/local/bin/rcc-qt5 \
    100         /usr/qt/5/bin/rcc-qt5 \
    101         /usr/share/qt5/bin/rcc-qt5 \
     90    ifeq ($(PATH_SDK_QT6),)
     91     PATH_SDK_QT6 := $(patsubst %/libexec/rcc-qt6,%,$(firstword $(wildcard \
     92        /usr/libexec/rcc-qt6 \
     93        /usr/local/libexec/rcc-qt6 \
     94        /usr/qt/6/libexec/rcc-qt6 \
     95        $(if $(intersects $(KBUILD_HOST_ARCH),$(KBUILD_ARCHES_64)),/usr/lib64/qt6/libexec/rcc-qt6) \
     96        /usr/lib/qt6/libexec/rcc-qt6 \
     97        /usr/share/qt6/libexec/rcc-qt6 \
    10298        )))
    10399    endif
    104     ifeq ($(PATH_SDK_QT5),)
    105      PATH_SDK_QT5 := $(patsubst %/bin/rcc,%,$(firstword $(wildcard \
    106        /usr/lib/*/qt5/bin/rcc \
     100    ifeq ($(PATH_SDK_QT6),)
     101     PATH_SDK_QT6 := $(patsubst %/libexec/rcc,%,$(firstword $(wildcard \
     102        /usr/qt/6/libexec/rcc \
     103        $(if $(intersects $(KBUILD_HOST_ARCH),$(KBUILD_ARCHES_64)),/usr/lib64/qt6/libexec/rcc) \
     104        /usr/lib/qt6/libexec/rcc \
     105        /usr/share/qt6/libexec/rcc \
     106        /usr/libexec/rcc \
     107        /usr/local/libexec/rcc \
     108        )))
     109    endif
     110    ifeq ($(PATH_SDK_QT6),)
     111     PATH_SDK_QT6 := $(patsubst %/bin/rcc,%,$(firstword $(wildcard \
     112        /usr/qt/6/bin/rcc \
     113        $(if $(intersects $(KBUILD_HOST_ARCH),$(KBUILD_ARCHES_64)),/usr/lib64/qt6/bin/rcc) \
     114        /usr/lib/qt6/bin/rcc \
     115        /usr/share/qt6/bin/rcc \
    107116        /usr/bin/rcc \
    108117        /usr/local/bin/rcc \
    109         /usr/qt/5/bin/rcc \
    110         /usr/share/qt5/bin/rcc \
    111118        )))
    112119    endif
    113     ifneq ($(PATH_SDK_QT5),)
    114      export PATH_SDK_QT5
    115 
    116      # Locate the include files. Check for qglobalstatic.h (since 5.1) first.
    117      ifeq ($(PATH_SDK_QT5_INC),)
    118       PATH_SDK_QT5_INC := $(patsubst %/QtCore/qglobalstatic.h,%,$(firstword $(wildcard \
    119         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/include/$(type)/qt5/QtCore/qglobalstatic.h) \
    120         $(PATH_SDK_QT5)/include/qt5/QtCore/qglobalstatic.h \
    121         /usr/include/qt5/QtCore/qtglobalstatic.h \
    122         /usr/local/include/qt5/QtCore/qtglobalstatic.h \
    123         $(PATH_SDK_QT5)/include/QtCore/qglobalstatic.h \
    124         /usr/include/qt/QtCore/qglobalstatic.h \
    125         /usr/local/include/qt/QtCore/qglobalstatic.h \
     120    ifneq ($(PATH_SDK_QT6),)
     121     export PATH_SDK_QT6
     122
     123     # Locate the include files. Check for QStringConverter (since 6.?) first.
     124     ifeq ($(PATH_SDK_QT6_INC),)
     125      PATH_SDK_QT6_INC := $(patsubst %/QtCore/QStringConverter,%,$(firstword $(wildcard \
     126        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/include/$(type)/qt6/QtCore/QStringConverter) \
     127        $(PATH_SDK_QT6)/include/qt6/QtCore/QStringConverter \
     128        /usr/include/qt6/QtCore/QStringConverter \
     129        /usr/local/include/qt6/QtCore/QStringConverter \
     130        $(PATH_SDK_QT6)/include/QtCore/QStringConverter \
     131        /usr/include/qt/QtCore/QStringConverter \
     132        /usr/local/include/qt/QtCore/QStringConverter \
    126133        )))
    127       ifeq ($(PATH_SDK_QT5_INC),)
    128        PATH_SDK_QT5_INC := $(patsubst %/QtCore/qglobal.h,%,$(firstword $(wildcard \
    129         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/include/$(type)/qt5/QtCore/qglobal.h) \
    130         $(PATH_SDK_QT5)/include/qt5/QtCore/qglobal.h \
    131         /usr/include/qt5/QtCore/qtglobal.h \
    132         /usr/local/include/qt5/QtCore/qtglobal.h \
    133         $(PATH_SDK_QT5)/include/QtCore/qglobal.h \
     134      ifeq ($(PATH_SDK_QT6_INC),)
     135       PATH_SDK_QT6_INC := $(patsubst %/QtCore/qglobal.h,%,$(firstword $(wildcard \
     136        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/include/$(type)/qt6/QtCore/qglobal.h) \
     137        $(PATH_SDK_QT6)/include/qt6/QtCore/qglobal.h \
     138        /usr/include/qt6/QtCore/qglobal.h \
     139        /usr/local/include/qt6/QtCore/qglobal.h \
     140        $(PATH_SDK_QT6)/include/QtCore/qglobal.h \
    134141        )))
    135142      endif
    136       ifneq ($(PATH_SDK_QT5_INC),)
    137        export PATH_SDK_QT5_INC
     143      ifneq ($(PATH_SDK_QT6_INC),)
     144       export PATH_SDK_QT6_INC
    138145      endif
    139146     endif
    140147
    141148     # Now for the libraries (mostly for helping out finding the KBUILD_TARGET libs).
    142      ifeq ($(PATH_SDK_QT5_LIB.x86),)
    143       PATH_SDK_QT5_LIB.x86   := $(patsubst %/libQt5Core$(SUFF_DLL),%,$(firstword $(wildcard \
    144         $(PATH_SDK_QT5)/lib32/libQt5Core$(SUFF_DLL) \
    145         $(PATH_SDK_QT5)/lib32/qt5/libQt5Core$(SUFF_DLL) \
    146         /usr/lib32/libQt5Core$(SUFF_DLL) \
    147         /usr/lib32/qt5/libQt5Core$(SUFF_DLL) \
    148         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).x86),/usr/lib/$(type)/libQt5Core$(SUFF_DLL)) \
    149         /usr/local/lib32/libQt5Core$(SUFF_DLL) \
    150         /usr/local/lib32/qt5/libQt5Core$(SUFF_DLL) \
    151         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).x86),/usr/local/lib/$(type)/libQt5Core$(SUFF_DLL)) \
    152         $(PATH_SDK_QT5)/lib/libQt5Core$(SUFF_DLL) \
    153         $(PATH_SDK_QT5)/lib/qt5/libQt5Core$(SUFF_DLL) \
    154         $(PATH_SDK_QT5)/lib/i386-linux-gnu/libQt5Core$(SUFF_DLL) \
     149     ifeq ($(PATH_SDK_QT6_LIB.x86),)
     150      PATH_SDK_QT6_LIB.x86   := $(patsubst %/libQt6Core$(SUFF_DLL),%,$(firstword $(wildcard \
     151        $(PATH_SDK_QT6)/lib32/libQt6Core$(SUFF_DLL) \
     152        $(PATH_SDK_QT6)/lib32/qt6/libQt6Core$(SUFF_DLL) \
     153        /usr/lib32/libQt6Core$(SUFF_DLL) \
     154        /usr/lib32/qt6/libQt6Core$(SUFF_DLL) \
     155        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).x86),/usr/lib/$(type)/libQt6Core$(SUFF_DLL)) \
     156        /usr/local/lib32/libQt6Core$(SUFF_DLL) \
     157        /usr/local/lib32/qt6/libQt6Core$(SUFF_DLL) \
     158        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).x86),/usr/local/lib/$(type)/libQt6Core$(SUFF_DLL)) \
     159        $(PATH_SDK_QT6)/lib/libQt6Core$(SUFF_DLL) \
     160        $(PATH_SDK_QT6)/lib/qt6/libQt6Core$(SUFF_DLL) \
     161        $(PATH_SDK_QT6)/lib/i386-linux-gnu/libQt6Core$(SUFF_DLL) \
    155162        )))
    156       ifneq ($(PATH_SDK_QT5_LIB.x86),)
    157        export PATH_SDK_QT5_LIB.x86
     163      ifneq ($(PATH_SDK_QT6_LIB.x86),)
     164       export PATH_SDK_QT6_LIB.x86
    158165      endif
    159166     endif
    160      ifeq ($(PATH_SDK_QT5_LIB.amd64),)
    161       PATH_SDK_QT5_LIB.amd64 := $(patsubst %/libQt5Core$(SUFF_DLL),%,$(firstword $(wildcard \
    162         $(PATH_SDK_QT5)/lib64/libQt5Core$(SUFF_DLL) \
    163         $(PATH_SDK_QT5)/lib64/qt5/libQt5Core$(SUFF_DLL) \
    164         $(PATH_SDK_QT5)/lib/amd64/libQt5Core$(SUFF_DLL) \
    165         /usr/lib64/libQt5Core$(SUFF_DLL) \
    166         /usr/lib64/qt5/libQt5Core$(SUFF_DLL) \
    167         /usr/lib/amd64/libQt5Core$(SUFF_DLL) \
    168         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).amd64),/usr/lib/$(type)/libQt5Core$(SUFF_DLL)) \
    169         /usr/local/lib64/libQt5Core$(SUFF_DLL) \
    170         /usr/local/lib64/qt5/libQt5Core$(SUFF_DLL) \
    171         /usr/local/lib/amd64/libQt5Core$(SUFF_DLL) \
    172         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).amd64),/usr/local/lib/$(type)/libQt5Core$(SUFF_DLL)) \
    173         $(PATH_SDK_QT5)/lib/libQt5Core$(SUFF_DLL) \
    174         $(PATH_SDK_QT5)/lib/qt5/libQt5Core$(SUFF_DLL) \
    175         $(PATH_SDK_QT5)/lib/x86_64-linux-gnu/libQt5Core$(SUFF_DLL) \
     167     ifeq ($(PATH_SDK_QT6_LIB.amd64),)
     168      PATH_SDK_QT6_LIB.amd64 := $(patsubst %/libQt6Core$(SUFF_DLL),%,$(firstword $(wildcard \
     169        $(PATH_SDK_QT6)/lib64/libQt6Core$(SUFF_DLL) \
     170        $(PATH_SDK_QT6)/lib64/qt6/libQt6Core$(SUFF_DLL) \
     171        $(PATH_SDK_QT6)/lib/amd64/libQt6Core$(SUFF_DLL) \
     172        /usr/lib64/libQt6Core$(SUFF_DLL) \
     173        /usr/lib64/qt6/libQt6Core$(SUFF_DLL) \
     174        /usr/lib/amd64/libQt6Core$(SUFF_DLL) \
     175        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).amd64),/usr/lib/$(type)/libQt6Core$(SUFF_DLL)) \
     176        /usr/local/lib64/libQt6Core$(SUFF_DLL) \
     177        /usr/local/lib64/qt6/libQt6Core$(SUFF_DLL) \
     178        /usr/local/lib/amd64/libQt6Core$(SUFF_DLL) \
     179        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).amd64),/usr/local/lib/$(type)/libQt6Core$(SUFF_DLL)) \
     180        $(PATH_SDK_QT6)/lib/libQt6Core$(SUFF_DLL) \
     181        $(PATH_SDK_QT6)/lib/qt6/libQt6Core$(SUFF_DLL) \
     182        $(PATH_SDK_QT6)/lib/x86_64-linux-gnu/libQt6Core$(SUFF_DLL) \
    176183        )))
    177       ifneq ($(PATH_SDK_QT5_LIB.amd64),)
    178        export PATH_SDK_QT5_LIB.amd64
     184      ifneq ($(PATH_SDK_QT6_LIB.amd64),)
     185       export PATH_SDK_QT6_LIB.amd64
    179186      endif
    180187     endif
     188     ifeq ($(PATH_SDK_QT6_LIB.arm64),)
     189      PATH_SDK_QT6_LIB.arm64 := $(patsubst %/libQt6Core$(SUFF_DLL),%,$(firstword $(wildcard \
     190        $(PATH_SDK_QT6)/lib64/libQt6Core$(SUFF_DLL) \
     191        $(PATH_SDK_QT6)/lib64/qt6/libQt6Core$(SUFF_DLL) \
     192        $(PATH_SDK_QT6)/lib/arm64/libQt6Core$(SUFF_DLL) \
     193        /usr/lib64/libQt6Core$(SUFF_DLL) \
     194        /usr/lib64/qt6/libQt6Core$(SUFF_DLL) \
     195        /usr/lib/arm64/libQt6Core$(SUFF_DLL) \
     196        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).arm64),/usr/lib/$(type)/libQt6Core$(SUFF_DLL)) \
     197        /usr/local/lib64/libQt6Core$(SUFF_DLL) \
     198        /usr/local/lib64/qt6/libQt6Core$(SUFF_DLL) \
     199        /usr/local/lib/arm64/libQt6Core$(SUFF_DLL) \
     200        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET).arm64),/usr/local/lib/$(type)/libQt6Core$(SUFF_DLL)) \
     201        $(PATH_SDK_QT6)/lib/libQt6Core$(SUFF_DLL) \
     202        $(PATH_SDK_QT6)/lib/qt6/libQt6Core$(SUFF_DLL) \
     203        $(PATH_SDK_QT6)/lib/x86_64-linux-gnu/libQt6Core$(SUFF_DLL) \
     204        )))
     205      ifneq ($(PATH_SDK_QT6_LIB.arm64),)
     206       export PATH_SDK_QT6_LIB.arm64
     207      endif
     208     endif
    181209
    182210     # And finally, the library path for KBUILD_TARGET.
    183      ifeq ($(PATH_SDK_QT5_LIB),)
    184       PATH_SDK_QT5_LIB := $(PATH_SDK_QT5_LIB.$(KBUILD_TARGET_ARCH))
    185       ifeq ($(PATH_SDK_QT5_LIB),)
    186        PATH_SDK_QT5_LIB := $(patsubst %/libQt5Core$(SUFF_DLL),%,$(firstword $(wildcard \
    187         $(PATH_SDK_QT5)/lib/libQt5Core$(SUFF_DLL) \
    188         $(PATH_SDK_QT5)/lib/qt5/libQt5Core$(SUFF_DLL) \
    189         /usr/lib/libQt5Core$(SUFF_DLL) \
    190         /usr/lib/qt5/libQt5Core$(SUFF_DLL) \
    191         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/lib/$(type)/libQt5Core$(SUFF_DLL)) \
    192         /usr/local/lib/libQt5Core$(SUFF_DLL) \
    193         /usr/local/lib/qt5/libQt5Core$(SUFF_DLL) \
    194         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/local/lib/$(type)/libQt5Core$(SUFF_DLL)) \
     211     ifeq ($(PATH_SDK_QT6_LIB),)
     212      PATH_SDK_QT6_LIB := $(PATH_SDK_QT6_LIB.$(KBUILD_TARGET_ARCH))
     213      ifeq ($(PATH_SDK_QT6_LIB),)
     214       PATH_SDK_QT6_LIB := $(patsubst %/libQt6Core$(SUFF_DLL),%,$(firstword $(wildcard \
     215        $(PATH_SDK_QT6)/lib/libQt6Core$(SUFF_DLL) \
     216        $(PATH_SDK_QT6)/lib/qt6/libQt6Core$(SUFF_DLL) \
     217        /usr/lib/libQt6Core$(SUFF_DLL) \
     218        /usr/lib/qt6/libQt6Core$(SUFF_DLL) \
     219        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/lib/$(type)/libQt6Core$(SUFF_DLL)) \
     220        /usr/local/lib/libQt6Core$(SUFF_DLL) \
     221        /usr/local/lib/qt6/libQt6Core$(SUFF_DLL) \
     222        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_TARGET_DOT_ARCH)),/usr/local/lib/$(type)/libQt6Core$(SUFF_DLL)) \
    195223        )))
    196224      endif
    197       ifneq ($(PATH_SDK_QT5_LIB),)
    198        export PATH_SDK_QT5_LIB
     225      ifneq ($(PATH_SDK_QT6_LIB),)
     226       export PATH_SDK_QT6_LIB
    199227      endif
    200228     endif
     
    204232  endif
    205233  # Found it?
    206   ifeq ($(PATH_SDK_QT5),)
    207    $(warning kBuild: Couldn't find the Qt5 headers and libaries...)
    208    PATH_SDK_QT5 := $(KBUILD_DEVTOOLS_TRG)/qt/not-found
     234  ifeq ($(PATH_SDK_QT6),)
     235   $(warning kBuild: Couldn't find the Qt6 headers and libaries...)
     236   PATH_SDK_QT6 := $(KBUILD_DEVTOOLS_TRG)/qt/not-found
    209237  endif
    210238 endif
    211239else
    212240 # Resolve any fancy stuff once and for all.
    213  PATH_SDK_QT5 := $(PATH_SDK_QT5)
     241 PATH_SDK_QT6 := $(PATH_SDK_QT6)
    214242endif
    215243
     
    217245# build it on the mac. The .dmg installs into Frameworks but builds into lib.
    218246ifeq ($(KBUILD_TARGET),darwin)
    219  ifndef PATH_SDK_QT5_LIB
    220   ifneq ($(wildcard $(PATH_SDK_QT5)/Frameworks),)
    221    PATH_SDK_QT5_LIB ?= $(PATH_SDK_QT5)/Frameworks
     247 ifndef PATH_SDK_QT6_LIB
     248  ifneq ($(wildcard $(PATH_SDK_QT6)/Frameworks),)
     249   PATH_SDK_QT6_LIB ?= $(PATH_SDK_QT6)/Frameworks
    222250  else
    223    PATH_SDK_QT5_LIB ?= $(PATH_SDK_QT5)/lib
     251   PATH_SDK_QT6_LIB ?= $(PATH_SDK_QT6)/lib
    224252  endif
    225253 endif
    226254else
    227  PATH_SDK_QT5_LIB ?= $(PATH_SDK_QT5)/lib
    228  PATH_SDK_QT5_INC ?= $(PATH_SDK_QT5)/include
     255 PATH_SDK_QT6_LIB ?= $(PATH_SDK_QT6)/lib
     256 PATH_SDK_QT6_INC ?= $(PATH_SDK_QT6)/include
    229257endif
    230258
     
    234262
    235263#
    236 # The QT5 tool.
    237 #
    238 # This is implemented here rather than in tools/QT5.kmk to enforce the global USES.
     264# The QT6 tool.
     265#
     266# This is implemented here rather than in tools/QT6.kmk to enforce the global USES.
    239267# It also makes things easier to develop, with fewer files I mean.
    240268#
    241 TOOL_QT5 = Qt5
     269TOOL_QT6 = Qt6
    242270
    243271# Tool Specific Properties
    244 #       PATH_TOOL_QT5     - Obsolete.
    245 #       PATH_TOOL_QT5_BIN - The
    246 #       TOOL_QT5_BIN_SUFF -
    247 if !defined(PATH_TOOL_QT5_BIN) && defined(PATH_TOOL_QT5)
    248  PATH_TOOL_QT5_BIN := $(PATH_TOOL_QT5)/bin
    249 endif
    250 ifndef PATH_TOOL_QT5_BIN
    251  PATH_TOOL_QT5_BIN := $(firstword $(rsort $(wildcard $(KBUILD_DEVTOOLS_HST)/qt/v5*/bin)))
    252  if "$(PATH_TOOL_QT5_BIN)" == "" && "$(KBUILD_DEVTOOLS_HST_ALT)" != ""
    253   PATH_TOOL_QT5_BIN := $(firstword $(rsort $(wildcard $(KBUILD_DEVTOOLS_HST_ALT)/qt/v5*/bin)))
    254  endif
    255  ifeq ($(PATH_TOOL_QT5_BIN),)
    256   ifdef TOOL_QT5_BIN_SUFF
    257    TOOL_QT5_BIN_SUFF := $(TOOL_QT5_BIN_SUFF)
     272#       PATH_TOOL_QT6         - Obsolete.
     273#       PATH_TOOL_QT6_BIN     - The path to the lrc and lupdate tools.
     274#       PATH_TOOL_QT6_LIBEXEC - The path to the moc, uic & rcc tools.
     275#       TOOL_QT6_BIN_SUFF     - The binary suffix for PATH_TOOL_QT6_BIN tools.
     276#       TOOL_QT6_LIBEXEC_SUFF - The binary suffix for PATH_TOOL_QT6_LIBEXEC tools.
     277if !defined(PATH_TOOL_QT6_BIN) && defined(PATH_TOOL_QT6)
     278 PATH_TOOL_QT6_BIN := $(PATH_TOOL_QT6)/bin
     279endif
     280ifndef PATH_TOOL_QT6_BIN
     281 PATH_TOOL_QT6_BIN := $(firstfile $(rversortfiles $(qwildcard ,$(KBUILD_DEVTOOLS_HST)/qt/v6*/bin)))
     282 if "$(PATH_TOOL_QT6_BIN)" == "" && "$(KBUILD_DEVTOOLS_HST_ALT)" != ""
     283  PATH_TOOL_QT6_BIN := $(firstfile $(rversortfiles $(qwildcard ,$(KBUILD_DEVTOOLS_HST_ALT)/qt/v6*/bin)))
     284 endif
     285 ifeq ($(PATH_TOOL_QT6_BIN),)
     286  ifdef TOOL_QT6_BIN_SUFF
     287   TOOL_QT6_BIN_SUFF := $(TOOL_QT6_BIN_SUFF)
    258288  endif
    259   # Try looking for moc-qt5 / moc-$(suffix) first.
    260   ifneq ($(TOOL_QT5_BIN_SUFF),)
    261    PATH_TOOL_QT5_BIN := $(patsubst %/moc$(TOOL_QT5_BIN_SUFF),%,$(firstword $(wildcard \
    262          $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt5/bin/moc$(TOOL_QT5_BIN_SUFF)) \
    263          /usr/lib/qt5/bin/moc$(TOOL_QT5_BIN_SUFF) \
    264          /usr/qt/5/bin/moc$(TOOL_QT5_BIN_SUFF) \
    265          /usr/share/qt5/bin/moc$(TOOL_QT5_BIN_SUFF) \
    266          /usr/local/bin/moc$(TOOL_QT5_BIN_SUFF) \
    267          /usr/bin/moc$(TOOL_QT5_BIN_SUFF) \
    268          )))
     289  # Try looking for lupdate-qt6 / lupdate-$(suffix) first (this is in bin rather than libexec).
     290  ifneq ($(TOOL_QT6_BIN_SUFF),)
     291   PATH_TOOL_QT6_BIN := $(patsubst %/lupdate$(TOOL_QT6_BIN_SUFF),%,$(firstword $(wildcard \
     292        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt6/bin/lupdate$(TOOL_QT6_BIN_SUFF)) \
     293        $(if $(intersects $(KBUILD_HOST_ARCH),$(KBUILD_ARCHES_64)),/usr/lib64/qt6/bin/lupdate$(TOOL_QT6_BIN_SUFF)) \
     294        /usr/lib/qt6/bin/lupdate$(TOOL_QT6_BIN_SUFF) \
     295        /usr/qt/6/bin/lupdate$(TOOL_QT6_BIN_SUFF) \
     296        /usr/share/qt6/bin/lupdate$(TOOL_QT6_BIN_SUFF) \
     297        /usr/local/bin/lupdate$(TOOL_QT6_BIN_SUFF) \
     298        /usr/bin/lupdate$(TOOL_QT6_BIN_SUFF) \
     299        )))
    269300  else
    270    # No suffix given, so before we check out -qt5 look at qt5 specific locations to avoid choosers and symlinks.
    271    PATH_TOOL_QT5_BIN := $(patsubst %/moc,%,$(firstword $(wildcard \
    272         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt5/bin/moc) \
    273         $(if $(intersects $(KBUILD_HOST_ARCH), $(KBUILD_ARCHES_64)),/usr/lib64/qt5/bin/moc,) \
    274         /usr/lib/qt5/bin/moc \
    275         /usr/local/lib/qt5/bin/moc \
    276         /usr/qt/5/bin/moc \
    277         /usr/local/qt/5/bin/moc \
    278         /usr/share/qt5/bin/moc \
    279         /usr/local/share/qt5/bin/moc \
     301   # No suffix given, so before we check out -qt6 look at qt6 specific locations to avoid choosers and symlinks.
     302   PATH_TOOL_QT6_BIN := $(patsubst %/lupdate,%,$(firstword $(wildcard \
     303        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt6/bin/lupdate) \
     304        $(if $(intersects $(KBUILD_HOST_ARCH), $(KBUILD_ARCHES_64)),/usr/lib64/qt6/bin/lupdate,) \
     305        /usr/lib/qt6/bin/lupdate \
     306        /usr/local/lib/qt6/bin/lupdate \
     307        /usr/qt/6/bin/lupdate \
     308        /usr/local/qt/6/bin/lupdate \
     309        /usr/share/qt6/bin/lupdate \
     310        /usr/local/share/qt6/bin/lupdate \
    280311        )))
    281    ifeq ($(PATH_TOOL_QT5_BIN),)
    282     PATH_TOOL_QT5_BIN := $(patsubst %/moc-qt5,%,$(firstword $(wildcard \
    283         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt5/bin/moc-qt5) \
    284         /usr/lib/qt5/bin/moc-qt5 \
    285         /usr/qt/5/bin/moc-qt5 \
    286         /usr/share/qt5/bin/moc-qt5 \
    287         /usr/local/bin/moc-qt5 \
    288         /usr/bin/moc-qt5 \
     312   ifeq ($(PATH_TOOL_QT6_BIN),)
     313    PATH_TOOL_QT6_BIN := $(patsubst %/lupdate-qt6,%,$(firstword $(wildcard \
     314        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt6/bin/lupdate-qt6) \
     315        $(if $(intersects $(KBUILD_HOST_ARCH), $(KBUILD_ARCHES_64)),/usr/lib64/qt6/bin/lupdate-qt6,) \
     316        /usr/lib/qt6/bin/lupdate-qt6 \
     317        /usr/qt/6/bin/lupdate-qt6 \
     318        /usr/share/qt6/bin/lupdate-qt6 \
     319        /usr/local/bin/lupdate-qt6 \
     320        /usr/bin/lupdate-qt6 \
    289321        )))
    290     ifneq ($(PATH_TOOL_QT5_BIN),)
    291      TOOL_QT5_BIN_SUFF := -qt5
     322    ifneq ($(PATH_TOOL_QT6_BIN),)
     323     TOOL_QT6_BIN_SUFF := -qt6
    292324    endif
    293325   endif
    294326  endif
    295   # If still no go, try looking for qt4to5 and rcc.
    296   ifeq ($(PATH_TOOL_QT5_BIN),)
    297    PATH_TOOL_QT5_BIN := $(patsubst %/qt4to5,%,$(firstword $(wildcard \
    298         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt5/bin/qt4to5) \
    299         /usr/lib/qt5/bin/qt4to5 \
    300         /usr/qt/5/bin/qt4to5 \
    301         /usr/share/qt5/bin/qt4to5 \
    302         /usr/local/bin/qt4to5 \
    303         /usr/bin/qt4to5 \
     327  # If still no go, try looking for qmake.
     328  ifeq ($(PATH_TOOL_QT6_BIN),)
     329   PATH_TOOL_QT6_BIN := $(patsubst %/qmake,%,$(firstword $(wildcard \
     330        $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt6/bin/qmake) \
     331        $(if $(intersects $(KBUILD_HOST_ARCH), $(KBUILD_ARCHES_64)),/usr/lib64/qt6/bin/qmake,) \
     332        /usr/lib/qt6/bin/qmake \
     333        /usr/qt/6/bin/qmake \
     334        /usr/share/qt6/bin/qmake \
     335        /usr/local/bin/qmake \
     336        /usr/bin/qmake \
    304337        )))
    305338  endif
    306   ifeq ($(PATH_TOOL_QT5_BIN),)
    307    PATH_TOOL_QT5_BIN := $(patsubst %/rcc$(TOOL_QT5_BIN_SUFF),%,$(firstword $(wildcard \
    308         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt5/bin/rcc$(TOOL_QT5_BIN_SUFF)) \
    309         /usr/lib/qt5/bin/rcc$(TOOL_QT5_BIN_SUFF) \
    310         /usr/qt/5/bin/rcc$(TOOL_QT5_BIN_SUFF) \
    311         /usr/share/qt5/bin/rcc$(TOOL_QT5_BIN_SUFF) \
    312         /usr/local/bin/rcc$(TOOL_QT5_BIN_SUFF) \
    313         /usr/bin/rcc$(TOOL_QT5_BIN_SUFF) \
    314         )))
     339  ifneq ($(PATH_TOOL_QT6_BIN),)
     340   export PATH_TOOL_QT6_BIN
    315341  endif
    316   if "$(PATH_TOOL_QT5_BIN)" == "" && "$(TOOL_QT5_BIN_SUFF)" != ""
    317    PATH_TOOL_QT5_BIN := $(patsubst %/rcc,%,$(firstword $(wildcard \
    318         $(foreach type,$(KBUILD_OSARCH_2_GNU_SYSTEM_TYPES.$(KBUILD_HOST_DOT_ARCH)),/usr/lib/$(type)/qt5/bin/rcc) \
    319         /usr/lib/qt5/bin/rcc \
    320         /usr/qt/5/bin/rcc \
    321         /usr/share/qt5/bin/rcc \
    322         /usr/local/bin/rcc \
    323         /usr/bin/rcc \
    324         )))
     342 endif
     343 # If not found, we'll enter the 'pathless' mode.
     344else
     345 # Resolve any fancy stuff once and for all.
     346 PATH_TOOL_QT6_BIN := $(PATH_TOOL_QT6_BIN)
     347endif
     348
     349# Unixes have moc, rcc, uic in a libexec dir rather than the bin dir, so try
     350# find that directory or alias the LIBEXEC stuff onto BIN.
     351ifndef PATH_TOOL_QT6_LIBEXEC
     352 ifneq ($(PATH_TOOL_QT6_BIN),)
     353  ifneq ($(qwildcard ,$(PATH_TOOL_QT6_BIN)/../libexec/moc*),)
     354   PATH_TOOL_QT6_LIBEXEC := $(qabspath ,$(PATH_TOOL_QT6_BIN)/../libexec)
     355  else
     356   PATH_TOOL_QT6_LIBEXEC := $(PATH_TOOL_QT6_BIN)
    325357  endif
    326   ifneq ($(PATH_TOOL_QT5_BIN),)
    327    export PATH_TOOL_QT5_BIN
    328   endif
    329  endif
    330  # If not found, we'll enter the 'pathless' mode.
    331 else
    332  # Resolve any fancy stuff once and for all.
    333  PATH_TOOL_QT5_BIN := $(PATH_TOOL_QT5_BIN)
    334 endif
    335 ifneq ($(PATH_TOOL_QT5_BIN),)
    336  TOOL_QT5_MOC       ?= $(PATH_TOOL_QT5_BIN)/moc$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    337  TOOL_QT5_UIC       ?= $(PATH_TOOL_QT5_BIN)/uic$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    338  ifndef TOOL_QT5_RCC
    339   TOOL_QT5_RCC      := $(PATH_TOOL_QT5_BIN)/rcc$(HOSTSUFF_EXE)
    340   ifeq ($(wildcard $(TOOL_QT5_RCC)),)
    341    TOOL_QT5_RCC     := $(PATH_TOOL_QT5_BIN)/rcc$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    342   endif
    343  endif
    344  TOOL_QT5_LRC       ?= $(PATH_TOOL_QT5_BIN)/lrelease$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    345  TOOL_QT5_LUPDATE   ?= $(PATH_TOOL_QT5_BIN)/lupdate$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
     358 endif
     359else
     360 PATH_TOOL_QT6_LIBEXEC := $(PATH_TOOL_QT6_LIBEXEC)
     361endif
     362if !defined(TOOL_QT6_LIBEXEC_SUFF) && defined(PATH_TOOL_QT6_LIBEXEC)
     363 ifneq ($(qwildcard ,$(PATH_TOOL_QT6_LIBEXEC)/moc-qt6$(HOSTSUFF_EXE)),)
     364  TOOL_QT6_LIBEXEC_SUFF := -qt6
     365 endif
     366endif
     367
     368ifneq ($(PATH_TOOL_QT6_BIN),)
     369 TOOL_QT6_MOC       ?= $(PATH_TOOL_QT6_LIBEXEC)/moc$(TOOL_QT6_LIBEXEC_SUFF)$(HOSTSUFF_EXE)
     370 TOOL_QT6_UIC       ?= $(PATH_TOOL_QT6_LIBEXEC)/uic$(TOOL_QT6_LIBEXEC_SUFF)$(HOSTSUFF_EXE)
     371 TOOL_QT6_RCC       ?= $(PATH_TOOL_QT6_LIBEXEC)/rcc$(TOOL_QT6_LIBEXEC_SUFF)$(HOSTSUFF_EXE)
     372 TOOL_QT6_LRC       ?= $(PATH_TOOL_QT6_BIN)/lrelease$(TOOL_QT6_BIN_SUFF)$(HOSTSUFF_EXE)
     373 TOOL_QT6_LUPDATE   ?= $(PATH_TOOL_QT6_BIN)/lupdate$(TOOL_QT6_BIN_SUFF)$(HOSTSUFF_EXE)
    346374else
    347375 # Pathless, relies on the environment.
    348  TOOL_QT5_MOC       ?= moc$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    349  TOOL_QT5_UIC       ?= uic$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    350  TOOL_QT5_RCC       ?= rcc$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    351  TOOL_QT5_LRC       ?= lrelease$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    352  TOOL_QT5_LUPDATE   ?= lupdate$(TOOL_QT5_BIN_SUFF)$(HOSTSUFF_EXE)
    353 endif
    354 ifdef TOOL_QT5_USE_KSUBMIT
     376 TOOL_QT6_MOC       ?= moc$(TOOL_QT6_LIBEXEC_SUFF)$(HOSTSUFF_EXE)
     377 TOOL_QT6_UIC       ?= uic$(TOOL_QT6_LIBEXEC_SUFF)$(HOSTSUFF_EXE)
     378 TOOL_QT6_RCC       ?= rcc$(TOOL_QT6_LIBEXEC_SUFF)$(HOSTSUFF_EXE)
     379 TOOL_QT6_LRC       ?= lrelease$(TOOL_QT6_BIN_SUFF)$(HOSTSUFF_EXE)
     380 TOOL_QT6_LUPDATE   ?= lupdate$(TOOL_QT6_BIN_SUFF)$(HOSTSUFF_EXE)
     381endif
     382ifdef TOOL_QT6_USE_KSUBMIT
    355383 ifeq ($(KBUILD_HOST),win)
    356   TOOL_QT5_MOC_KSUBMIT ?= kmk_builtin_kSubmit --$(SP)
     384  TOOL_QT6_MOC_KSUBMIT ?= kmk_builtin_kSubmit --$(SP)
    357385 endif
    358386endif
    359387
    360388# General Properties used by kBuild and/or units/qt.kmk
    361 TOOL_QT5_MOCFLAGS           ?=
    362 TOOL_QT5_MOCINCS            ?=
    363 TOOL_QT5_MOCDEFS            ?=
    364 TOOL_QT5_MOCDEFS.darwin     ?= __APPLE__ __GNUC__
    365 TOOL_QT5_MOCDEFS.solaris    ?= __sun
    366 TOOL_QT5_MOCDEFS.win.amd64  ?= WIN64
    367 TOOL_QT5_MOCDEFS.win.x86    ?= WIN32
     389TOOL_QT6_MOCFLAGS           ?=
     390TOOL_QT6_MOCINCS            ?=
     391TOOL_QT6_MOCDEFS            ?=
     392TOOL_QT6_MOCDEFS.darwin     ?= __APPLE__ __GNUC__
     393TOOL_QT6_MOCDEFS.solaris    ?= __sun
     394TOOL_QT6_MOCDEFS.win.amd64  ?= WIN64
     395TOOL_QT6_MOCDEFS.win.x86    ?= WIN32
    368396
    369397
     
    378406# @param    $(outbase)  Output basename (full). Use this for list files and such.
    379407#
    380 TOOL_QT5_MOC_CPP_DEPEND =
    381 TOOL_QT5_MOC_CPP_DEPORD =
    382 TOOL_QT5_MOC_CPP_OUTPUT =
    383 TOOL_QT5_MOC_CPP_OUTPUT_MAYBE =
     408TOOL_QT6_MOC_CPP_DEPEND =
     409TOOL_QT6_MOC_CPP_DEPORD =
     410TOOL_QT6_MOC_CPP_OUTPUT =
     411TOOL_QT6_MOC_CPP_OUTPUT_MAYBE =
    384412ifdef KMK_WITH_QUOTING
    385  define TOOL_QT5_MOC_CPP_CMDS
    386         $(QUIET)$(TOOL_QT5_MOC_KSUBMIT)$(TOOL_QT5_MOC)\
     413 define TOOL_QT6_MOC_CPP_CMDS
     414        $(QUIET)$(TOOL_QT6_MOC_KSUBMIT)$(TOOL_QT6_MOC)\
    387415                $(flags)\
    388416                $(qaddprefix sh,-I, $(incs))\
     
    392420 endef
    393421else
    394  define TOOL_QT5_MOC_CPP_CMDS
    395         $(QUIET)$(TOOL_QT5_MOC_KSUBMIT)$(TOOL_QT5_MOC)\
     422 define TOOL_QT6_MOC_CPP_CMDS
     423        $(QUIET)$(TOOL_QT6_MOC_KSUBMIT)$(TOOL_QT6_MOC)\
    396424                $(flags)\
    397425                $(addprefix -I, $(incs))\
     
    412440# @param    $(outbase)  Output basename (full). Use this for list files and such.
    413441#
    414 TOOL_QT5_MOC_HPP_DEPEND =
    415 TOOL_QT5_MOC_HPP_DEPORD =
    416 TOOL_QT5_MOC_HPP_OUTPUT =
    417 TOOL_QT5_MOC_HPP_OUTPUT_MAYBE =
     442TOOL_QT6_MOC_HPP_DEPEND =
     443TOOL_QT6_MOC_HPP_DEPORD =
     444TOOL_QT6_MOC_HPP_OUTPUT =
     445TOOL_QT6_MOC_HPP_OUTPUT_MAYBE =
    418446ifdef KMK_WITH_QUOTING
    419  define TOOL_QT5_MOC_HPP_CMDS
    420         $(QUIET)$(TOOL_QT5_MOC_KSUBMIT)$(TOOL_QT5_MOC)\
     447 define TOOL_QT6_MOC_HPP_CMDS
     448        $(QUIET)$(TOOL_QT6_MOC_KSUBMIT)$(TOOL_QT6_MOC)\
    421449                $(flags)\
    422450                $(qaddprefix sh,-I, $(incs))\
     
    426454 endef
    427455else
    428  define TOOL_QT5_MOC_HPP_CMDS
    429         $(QUIET)$(TOOL_QT5_MOC_KSUBMIT)$(TOOL_QT5_MOC)\
     456 define TOOL_QT6_MOC_HPP_CMDS
     457        $(QUIET)$(TOOL_QT6_MOC_KSUBMIT)$(TOOL_QT6_MOC)\
    430458                $(flags)\
    431459                $(addprefix -I, $(incs))\
     
    446474# @param    $(outbase)  Output basename (full). Use this for list files and such.
    447475#
    448 TOOL_QT5_UIC_UI_DEPEND =
    449 TOOL_QT5_UIC_UI_DEPORD =
    450 TOOL_QT5_UIC_UI_OUTPUT =
    451 TOOL_QT5_UIC_UI_OUTPUT_MAYBE =
    452 define TOOL_QT5_UIC_UI_CMDS
    453         $(QUIET)$(TOOL_QT5_UIC)\
     476TOOL_QT6_UIC_UI_DEPEND =
     477TOOL_QT6_UIC_UI_DEPORD =
     478TOOL_QT6_UIC_UI_OUTPUT =
     479TOOL_QT6_UIC_UI_OUTPUT_MAYBE =
     480define TOOL_QT6_UIC_UI_CMDS
     481        $(QUIET)$(TOOL_QT6_UIC)\
    454482                $(flags)\
    455483                -o $(out)\
     
    468496#
    469497# @remarks  The sed script generating the dependency file is a bit naive.
    470 TOOL_QT5_RCC_QRC_DEPEND =
    471 TOOL_QT5_RCC_QRC_DEPORD =
    472 TOOL_QT5_RCC_QRC_OUTPUT =
    473 TOOL_QT5_RCC_QRC_OUTPUT_MAYBE =
    474 define TOOL_QT5_RCC_QRC_CMDS
    475         $(QUIET)$(TOOL_QT5_RCC)\
     498TOOL_QT6_RCC_QRC_DEPEND =
     499TOOL_QT6_RCC_QRC_DEPORD =
     500TOOL_QT6_RCC_QRC_OUTPUT =
     501TOOL_QT6_RCC_QRC_OUTPUT_MAYBE =
     502define TOOL_QT6_RCC_QRC_CMDS
     503        $(QUIET)$(TOOL_QT6_RCC)\
    476504                $(flags)\
    477505                -o $(out)\
     
    508536# @param    $(outbase)  Output basename (full). Use this for list files and such.
    509537#
    510 TOOL_QT5_LRC_TS_DEPEND =
    511 TOOL_QT5_LRC_TS_DEPORD =
    512 TOOL_QT5_LRC_TS_OUTPUT =
    513 TOOL_QT5_LRC_TS_OUTPUT_MAYBE =
    514 define TOOL_QT5_LRC_TS_CMDS
    515         $(QUIET)$(TOOL_QT5_LRC)\
     538TOOL_QT6_LRC_TS_DEPEND =
     539TOOL_QT6_LRC_TS_DEPORD =
     540TOOL_QT6_LRC_TS_OUTPUT =
     541TOOL_QT6_LRC_TS_OUTPUT_MAYBE =
     542define TOOL_QT6_LRC_TS_CMDS
     543        $(QUIET)$(TOOL_QT6_LRC)\
    516544                $(flags)\
    517545                $(source)\
     
    523551#
    524552#
    525 # Back to the Qt5 unit.
     553# Back to the Qt6 unit.
    526554#
    527555#
     
    530558## wrapper for the lrelease (LRC) command dependencies.
    531559ifndef NO_COMPILE_CMDS_DEPS
    532  _UNIT_QT5_LRC_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT5_LRC_CMDS_PREV_),$$(commands $(out)),FORCE)
    533 else
    534  _UNIT_QT5_LRC_CMDS_DEP =
     560 _UNIT_QT6_LRC_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT6_LRC_CMDS_PREV_),$$(commands $(out)),FORCE)
     561else
     562 _UNIT_QT6_LRC_CMDS_DEP =
    535563endif
    536564
    537565##
    538 # def_unit_qt5_target_pre_handle_translation helper that is expanded before evaluation.
     566# def_unit_qt6_target_pre_handle_translation helper that is expanded before evaluation.
    539567#
    540568# This is necessary to resolve reference to local variables before doing
     
    542570# later in a different context and the result would be completely wrong.
    543571#
    544 define def_unit_qt5_target_pre_handle_translation_dx
     572define def_unit_qt6_target_pre_handle_translation_dx
    545573
    546574$(out) + $(more_output) +| $(maybe_output): \
    547575                $(deps) \
    548                 $(value _UNIT_QT5_LRC_CMDS_DEP) \
     576                $(value _UNIT_QT6_LRC_CMDS_DEP) \
    549577                | \
    550578                $(orderdeps)
     
    557585ifdef KBUILD_HAVE_OPTIMIZED_APPEND
    558586        %$$(QUIET2)$$(APPEND) -ni '$(dep)' \
    559                 'define $(target)_$(subst :,_,$(source))_QT5_LRC_CMDS_PREV_' \
     587                'define $(target)_$(subst :,_,$(source))_QT6_LRC_CMDS_PREV_' \
    560588                '--insert-command=$(out)' \
    561589                'endef'
    562590else
    563591        %$$(QUIET2)$$(APPEND) '$(dep)'
    564         %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT5_LRC_CMDS_PREV_'
     592        %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT6_LRC_CMDS_PREV_'
    565593        %$$(QUIET2)$$(APPEND) -c '$(dep)' '$(out)'
    566594        %$$(QUIET2)$$(APPEND) '$(dep)' 'endef'
     
    571599$(target)-inst-nls_SOURCES += $(out)
    572600
    573 endef # def_unit_qt5_target_pre_handle_translation_dx
     601endef # def_unit_qt6_target_pre_handle_translation_dx
    574602
    575603##
     
    580608#
    581609# @remarks Invoked via $(evalvalctx ).
    582 define def_unit_qt5_target_pre_handle_translation
     610define def_unit_qt6_target_pre_handle_translation
    583611local type      := LRC
    584612
     
    622650 $(eval includedep $(dep))
    623651endif
    624 $(eval $(def_unit_qt5_target_pre_handle_translation_dx))
    625 
    626 endef # def_unit_qt5_target_pre_handle_translation
     652$(eval $(def_unit_qt6_target_pre_handle_translation_dx))
     653
     654endef # def_unit_qt6_target_pre_handle_translation
    627655
    628656
     
    630658## wrapper for the UIC command dependencies.
    631659ifndef NO_COMPILE_CMDS_DEPS
    632  _UNIT_QT5_RCC_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT5_RCC_CMDS_PREV_),$$(commands $(out)),FORCE)
    633 else
    634  _UNIT_QT5_RCC_CMDS_DEP =
     660 _UNIT_QT6_RCC_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT6_RCC_CMDS_PREV_),$$(commands $(out)),FORCE)
     661else
     662 _UNIT_QT6_RCC_CMDS_DEP =
    635663endif
    636664
    637665##
    638 # def_unit_qt5_target_pre_handle_qrc helper that is expanded before evaluation.
     666# def_unit_qt6_target_pre_handle_qrc helper that is expanded before evaluation.
    639667#
    640668# This is necessary to resolve reference to local variables before doing
     
    642670# later in a different context and the result would be completely wrong.
    643671#
    644 define def_unit_qt5_target_pre_handle_rcc_dx
     672define def_unit_qt6_target_pre_handle_rcc_dx
    645673
    646674$(out) +| $(realout) $(more_output) $(maybe_output): \
    647675                $(deps) \
    648                 $(value _UNIT_QT5_RCC_CMDS_DEP) \
     676                $(value _UNIT_QT6_RCC_CMDS_DEP) \
    649677                | \
    650678                $(orderdeps)
     
    658686ifdef KBUILD_HAVE_OPTIMIZED_APPEND
    659687        %$$(QUIET2)$$(APPEND) -ni '$(dep)' \
    660                 'define $(target)_$(subst :,_,$(source))_QT5_RCC_CMDS_PREV_' \
     688                'define $(target)_$(subst :,_,$(source))_QT6_RCC_CMDS_PREV_' \
    661689                '--insert-command=$(out)' \
    662690                'endef'
    663691else
    664692        %$$(QUIET2)$$(APPEND) '$(dep)'
    665         %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT5_RCC_CMDS_PREV_'
     693        %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT6_RCC_CMDS_PREV_'
    666694        %$$(QUIET2)$$(APPEND) -c '$(dep)' '$(out)'
    667695        %$$(QUIET2)$$(APPEND) '$(dep)' 'endef'
     
    673701$(target)_CLEAN += $(out) $(realout) $(more_output) $(maybe_output) $(dep)
    674702
    675 endef # def_unit_qt5_target_pre_handle_rcc_dx
     703endef # def_unit_qt6_target_pre_handle_rcc_dx
    676704
    677705##
     
    679707#
    680708# @remarks $(evalvalctx me).
    681 define def_unit_qt5_src_handler_qrc
     709define def_unit_qt6_src_handler_qrc
    682710local type      := RCC
    683711
     
    722750 $(eval includedep $(dep))
    723751endif
    724 $(eval $(def_unit_qt5_target_pre_handle_rcc_dx))
    725 
    726 endef # def_unit_qt5_src_handler_qrc
     752$(eval $(def_unit_qt6_target_pre_handle_rcc_dx))
     753
     754endef # def_unit_qt6_src_handler_qrc
    727755
    728756
     
    730758## wrapper for the UIC command dependencies.
    731759ifndef NO_COMPILE_CMDS_DEPS
    732  _UNIT_QT5_UIC_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT5_UIC_CMDS_PREV_),$$(commands $(out)),FORCE)
    733 else
    734  _UNIT_QT5_UIC_CMDS_DEP =
     760 _UNIT_QT6_UIC_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT6_UIC_CMDS_PREV_),$$(commands $(out)),FORCE)
     761else
     762 _UNIT_QT6_UIC_CMDS_DEP =
    735763endif
    736764
    737765##
    738 # def_unit_qt5_src_handler_ui helper that is expanded before evaluation.
     766# def_unit_qt6_src_handler_ui helper that is expanded before evaluation.
    739767#
    740768# This is necessary to resolve reference to local variables before doing
     
    742770# later in a different context and the result would be completely wrong.
    743771#
    744 define def_unit_qt5_target_pre_handle_ui_dx
     772define def_unit_qt6_target_pre_handle_ui_dx
    745773
    746774$(out) +| $(realout) $(more_output) $(maybe_output): \
    747775                $(deps) \
    748                 $(value _UNIT_QT5_UIC_CMDS_DEP) \
     776                $(value _UNIT_QT6_UIC_CMDS_DEP) \
    749777                | \
    750778                $(orderdeps)
     
    758786ifdef KBUILD_HAVE_OPTIMIZED_APPEND
    759787        %$$(QUIET2)$$(APPEND) -ni '$(dep)' \
    760                 'define $(target)_$(subst :,_,$(source))_QT5_UIC_CMDS_PREV_' \
     788                'define $(target)_$(subst :,_,$(source))_QT6_UIC_CMDS_PREV_' \
    761789                '--insert-command=$(out)' \
    762790                'endef'
    763791else
    764792        %$$(QUIET2)$$(APPEND) '$(dep)'
    765         %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT5_UIC_CMDS_PREV_'
     793        %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT6_UIC_CMDS_PREV_'
    766794        %$$(QUIET2)$$(APPEND) -c '$(dep)' '$(out)'
    767795        %$$(QUIET2)$$(APPEND) '$(dep)' 'endef'
     
    772800$(target)_CLEAN += $(out) $(realout) $(more_output) $(maybe_output) $(dep)
    773801
    774 endef # def_unit_qt5_target_pre_handle_ui_dx
     802endef # def_unit_qt6_target_pre_handle_ui_dx
    775803
    776804##
     
    778806#
    779807# @remarks $(evalvalctx me).
    780 define def_unit_qt5_src_handler_ui
     808define def_unit_qt6_src_handler_ui
    781809local type      := UIC
    782810
     
    821849 $(eval includedep $(dep))
    822850endif
    823 $(eval $(def_unit_qt5_target_pre_handle_ui_dx))
    824 
    825 endef # def_unit_qt5_src_handler_ui
     851$(eval $(def_unit_qt6_target_pre_handle_ui_dx))
     852
     853endef # def_unit_qt6_src_handler_ui
    826854
    827855
     
    829857## wrapper for the MOC command dependencies.
    830858ifndef NO_COMPILE_CMDS_DEPS
    831  _UNIT_QT5_MOC_HPP_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT5_MOC_HPP_CMDS_PREV_),$$(commands $(out)),FORCE)
    832 else
    833  _UNIT_QT5_MOC_HPP_CMDS_DEP =
     859 _UNIT_QT6_MOC_HPP_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT6_MOC_HPP_CMDS_PREV_),$$(commands $(out)),FORCE)
     860else
     861 _UNIT_QT6_MOC_HPP_CMDS_DEP =
    834862endif
    835863
    836864##
    837 # def_unit_qt5_target_pre_handle_moc_hdr helper that is expanded before evaluation.
     865# def_unit_qt6_target_pre_handle_moc_hdr helper that is expanded before evaluation.
    838866#
    839867# This is necessary to resolve reference to local variables before doing
     
    841869# later in a different context and the result would be completely wrong.
    842870#
    843 define def_unit_qt5_target_pre_handle_moc_hdr_dx
     871define def_unit_qt6_target_pre_handle_moc_hdr_dx
    844872
    845873$(out) +| $(realout) $(more_output) $(maybe_output): \
    846874                $(deps) \
    847                 $(value _UNIT_QT5_MOC_HPP_CMDS_DEP) \
     875                $(value _UNIT_QT6_MOC_HPP_CMDS_DEP) \
    848876                | \
    849877                $(orderdeps) $(my_target_intermediate_vars)
     
    857885ifdef KBUILD_HAVE_OPTIMIZED_APPEND
    858886        %$$(QUIET2)$$(APPEND) -ni '$(dep)' \
    859                 'define $(target)_$(subst :,_,$(source))_QT5_MOC_HPP_CMDS_PREV_' \
     887                'define $(target)_$(subst :,_,$(source))_QT6_MOC_HPP_CMDS_PREV_' \
    860888                '--insert-command=$(out)' \
    861889                'endef'
    862890else
    863891        %$$(QUIET2)$$(APPEND) '$(dep)'
    864         %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT5_MOC_HPP_CMDS_PREV_'
     892        %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT6_MOC_HPP_CMDS_PREV_'
    865893        %$$(QUIET2)$$(APPEND) -c '$(dep)' '$(out)'
    866894        %$$(QUIET2)$$(APPEND) '$(dep)' 'endef'
     
    884912#
    885913# @remarks Invoked via $(evalvalctx ).
    886 define def_unit_qt5_target_pre_handle_moc_hdr
     914define def_unit_qt6_target_pre_handle_moc_hdr
    887915local type      := MOC
    888916
     
    928956 $(eval includedep $(dep))
    929957endif
    930 $(eval $(def_unit_qt5_target_pre_handle_moc_hdr_dx))
    931 
    932 endef # def_unit_qt5_target_pre_handle_moc_hdr
     958$(eval $(def_unit_qt6_target_pre_handle_moc_hdr_dx))
     959
     960endef # def_unit_qt6_target_pre_handle_moc_hdr
    933961
    934962
    935963## wrapper for the MOC command dependencies.
    936964ifndef NO_COMPILE_CMDS_DEPS
    937  _UNIT_QT5_MOC_CPP_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT5_MOC_CPP_CMDS_PREV_),$$(commands $(out)),FORCE)
    938 else
    939  _UNIT_QT5_MOC_CPP_CMDS_DEP =
     965 _UNIT_QT6_MOC_CPP_CMDS_DEP = $$(comp-cmds-ex $$($(target)_$(subst :,_,$(source))_QT6_MOC_CPP_CMDS_PREV_),$$(commands $(out)),FORCE)
     966else
     967 _UNIT_QT6_MOC_CPP_CMDS_DEP =
    940968endif
    941969
    942970##
    943 # def_unit_qt5_target_pre_handle_moc_src helper that is expanded before evaluation.
     971# def_unit_qt6_target_pre_handle_moc_src helper that is expanded before evaluation.
    944972#
    945973# This is necessary to resolve reference to local variables before doing
     
    947975# later in a different context and the result would be completely wrong.
    948976#
    949 define def_unit_qt5_target_pre_handle_moc_src_dx
     977define def_unit_qt6_target_pre_handle_moc_src_dx
    950978
    951979$(out) +| $(realout) $(more_output) $(maybe_output): \
    952980                $(deps) \
    953                 $(value _UNIT_QT5_MOC_CPP_CMDS_DEP) \
     981                $(value _UNIT_QT6_MOC_CPP_CMDS_DEP) \
    954982                | \
    955983                $(orderdeps) $(my_target_intermediate_vars)
     
    963991ifdef KBUILD_HAVE_OPTIMIZED_APPEND
    964992        %$$(QUIET2)$$(APPEND) -ni '$(dep)' \
    965                 'define $(target)_$(subst :,_,$(source))_QT5_MOC_CPP_CMDS_PREV_' \
     993                'define $(target)_$(subst :,_,$(source))_QT6_MOC_CPP_CMDS_PREV_' \
    966994                '--insert-command=$(out)' \
    967995                'endef'
    968996else
    969997        %$$(QUIET2)$$(APPEND) '$(dep)'
    970         %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT5_MOC_CPP_CMDS_PREV_'
     998        %$$(QUIET2)$$(APPEND) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT6_MOC_CPP_CMDS_PREV_'
    971999        %$$(QUIET2)$$(APPEND) -c '$(dep)' '$(out)'
    9721000        %$$(QUIET2)$$(APPEND) '$(dep)' 'endef'
     
    9861014#
    9871015# @remarks Invoked via $(evalvalctx ).
    988 define def_unit_qt5_target_pre_handle_moc_src
     1016define def_unit_qt6_target_pre_handle_moc_src
    9891017local type      := MOC
    9901018
     
    10301058 $(eval includedep $(dep))
    10311059endif
    1032 $(eval $(def_unit_qt5_target_pre_handle_moc_src_dx))
    1033 
    1034 endef # def_unit_qt5_target_pre_handle_moc_src
     1060$(eval $(def_unit_qt6_target_pre_handle_moc_src_dx))
     1061
     1062endef # def_unit_qt6_target_pre_handle_moc_src
    10351063
    10361064
    10371065##
    10381066# Adds sources containing Q_OBJECT to QT_MOCSRCS.
    1039 define def_unit_qt5_target_pre_cpp_source
     1067define def_unit_qt6_target_pre_cpp_source
    10401068ifneq ($(file-size $(source)),-1)
    10411069 ifneq ($(strip $(shell $(SED) -f $(KBUILD_PATH)/units/qt-Q_OBJECT.sed $(source))),)
     
    10431071 endif
    10441072endif
    1045 endef # def_unit_qt5_target_pre_cpp_source
     1073endef # def_unit_qt6_target_pre_cpp_source
    10461074
    10471075##
     
    10541082# a .moc files and generate rules and dependencies fofor these
    10551083#
    1056 define def_unit_qt5_target_pre
     1084define def_unit_qt6_target_pre
    10571085
    10581086# Make QTTOOL the default for the specific Qt tools instead of TOOL.
     
    10961124ifeq ($(bld_trg),darwin)
    10971125 # Adding -F to CXXFLAGS is necessary to make #include <QtCore/qstring.h> stuff work...
    1098  $(eval $(target)_CXXFLAGS += -F$(PATH_SDK_QT5_LIB) )
    1099  $(eval $(target)_OBJCXXFLAGS += -F$(PATH_SDK_QT5_LIB) )
    1100  $(eval $(target)_LDFLAGS  += -F$(PATH_SDK_QT5_LIB) $(foreach module,$(qt_modules), -framework $(qt_prefix)Qt$(module)$(qt_infix)) )
    1101  $(eval $(target)_INCS     += $(foreach module,$(qt_modules), $(PATH_SDK_QT5_LIB)/$(qt_prefix)Qt$(module)$(qt_infix).framework/Versions/5/Headers) )
     1126 $(eval $(target)_CXXFLAGS += -F$(PATH_SDK_QT6_LIB) )
     1127 $(eval $(target)_OBJCXXFLAGS += -F$(PATH_SDK_QT6_LIB) )
     1128 $(eval $(target)_LDFLAGS  += -F$(PATH_SDK_QT6_LIB) $(foreach module,$(qt_modules), -framework $(qt_prefix)Qt$(module)$(qt_infix)) )
     1129 $(eval $(target)_INCS     += $(foreach module,$(qt_modules), $(PATH_SDK_QT6_LIB)/$(qt_prefix)Qt$(module)$(qt_infix).framework/Versions/6/Headers) )
    11021130else
    11031131 ifeq ($(bld_trg),win)
    1104   $(eval $(target)_LIBS    += $(foreach module,$(qt_modules), $(PATH_SDK_QT5_LIB)/$(qt_prefix)Qt5$(module)$(qt_infix)$(SUFF_LIB)) )
     1132  $(eval $(target)_LIBS    += $(foreach module,$(qt_modules), $(PATH_SDK_QT6_LIB)/$(qt_prefix)Qt6$(module)$(qt_infix)$(SUFF_LIB)) )
    11051133  ifeq ($(tool_do),LINK_PROGRAM)
    1106    $(eval $(target)_LIBS   += $(PATH_SDK_QT5_LIB)/$(qt_prefix)qtmain$(qt_infix)$(SUFF_LIB) )
     1134   $(eval $(target)_LIBS   += $(PATH_SDK_QT6_LIB)/$(qt_prefix)qtmain$(qt_infix)$(SUFF_LIB) )
    11071135  endif
    11081136 else
    1109   $(eval $(target)_LIBS    += $(foreach module,$(qt_modules), $(PATH_SDK_QT5_LIB)/lib$(qt_prefix)Qt5$(module)$(qt_infix)$(SUFF_DLL)) )
    1110  endif
    1111  $(eval $(target)_INCS     += $(addprefix $(PATH_SDK_QT5_INC)/Qt,$(qt_modules)) $(PATH_SDK_QT5_INC) )
     1137  $(eval $(target)_LIBS    += $(foreach module,$(qt_modules), $(PATH_SDK_QT6_LIB)/lib$(qt_prefix)Qt6$(module)$(qt_infix)$(SUFF_DLL)) )
     1138 endif
     1139 $(eval $(target)_INCS     += $(addprefix $(PATH_SDK_QT6_INC)/Qt,$(qt_modules)) $(PATH_SDK_QT6_INC) )
    11121140endif
    11131141$(eval $(target)_DEFS      += $(foreach module,$(toupper $(qt_modules)), QT_$(module)_LIB) )
     
    11241152        $($(target)_SOURCES.$(bld_type)) \
    11251153        $($(target)_SOURCES) \
    1126         ), $(evalval def_unit_qt5_target_pre_cpp_source))
     1154        ), $(evalval def_unit_qt6_target_pre_cpp_source))
    11271155endif
    11281156
    11291157# Install source handlers for .ui files.
    11301158$(target)_SRC_HANDLERS += \
    1131          .ui:def_unit_qt5_src_handler_ui \
    1132          .UI:def_unit_qt5_src_handler_ui \
    1133         .qrc:def_unit_qt5_src_handler_qrc \
    1134         .qrc:def_unit_qt5_src_handler_qrc
     1159         .ui:def_unit_qt6_src_handler_ui \
     1160         .UI:def_unit_qt6_src_handler_ui \
     1161        .qrc:def_unit_qt6_src_handler_qrc \
     1162        .qrc:def_unit_qt6_src_handler_qrc
    11351163
    11361164# Calc the MOC and UI output directories and add them to BLDDIRS and INCS.
     
    11541182        $($(target)_QT_MOCSRCS.$(bld_type)) \
    11551183        $($(target)_QT_MOCSRCS) \
    1156         , $(evalvalctx def_unit_qt5_target_pre_handle_moc_src))
     1184        , $(evalvalctx def_unit_qt6_target_pre_handle_moc_src))
    11571185
    11581186# Deal with QT_MOCHDRS.
     
    11641192        $($(target)_QT_MOCHDRS.$(bld_type)) \
    11651193        $($(target)_QT_MOCHDRS) \
    1166         , $(evalvalctx def_unit_qt5_target_pre_handle_moc_hdr))
     1194        , $(evalvalctx def_unit_qt6_target_pre_handle_moc_hdr))
    11671195
    11681196# Deal with QT_TRANSLATIONS.
     
    11881216 $(target)-inst-nls_SOURCES :=
    11891217 $(foreach source, $(translations)\
    1190         , $(evalvalctx def_unit_qt5_target_pre_handle_translation))
    1191 endif
    1192 
    1193 endef # def_unit_qt5_target_pre
     1218        , $(evalvalctx def_unit_qt6_target_pre_handle_translation))
     1219endif
     1220
     1221endef # def_unit_qt6_target_pre
    11941222
    11951223
     
    11971225# Rule for debugging.
    11981226#
    1199 unit-qt5-show-vars:
    1200         @$(ECHO) 'The Qt5 SDK variables:'
    1201         @$(ECHO) '  PATH_SDK_QT5           = "$(PATH_SDK_QT5)"'
    1202         @$(ECHO) '  PATH_SDK_QT5_INC       = "$(PATH_SDK_QT5_INC)"'
    1203         @$(ECHO) '  PATH_SDK_QT5_LIB       = "$(PATH_SDK_QT5_LIB)"'
    1204         @$(ECHO) '  PATH_SDK_QT5_LIB.amd64 = "$(PATH_SDK_QT5_LIB.amd64)"'
    1205         @$(ECHO) '  PATH_SDK_QT5_LIB.x86   = "$(PATH_SDK_QT5_LIB.x86)"'
    1206         @$(ECHO) 'The Qt5 TOOL variables:'
    1207         @$(ECHO) '  PATH_TOOL_QT5_BIN      = "$(PATH_TOOL_QT5_BIN)"'
    1208         @$(ECHO) '  TOOL_QT5_BIN_SUFF      = "$(TOOL_QT5_BIN_SUFF)"'
    1209         @$(ECHO) '  TOOL_QT5_MOC           = "$(TOOL_QT5_MOC)"'
    1210         @$(ECHO) '  TOOL_QT5_UIC           = "$(TOOL_QT5_UIC)"'
    1211         @$(ECHO) '  TOOL_QT5_RCC           = "$(TOOL_QT5_RCC)"'
    1212         @$(ECHO) '  TOOL_QT5_LRC           = "$(TOOL_QT5_LRC)"'
    1213         @$(ECHO) '  TOOL_QT5_LUPDATE       = "$(TOOL_QT5_LUPDATE)"'
    1214 
     1227unit-qt6-show-vars:
     1228        @$(ECHO) 'The Qt6 SDK variables:'
     1229        @$(ECHO) '  PATH_SDK_QT6           = "$(PATH_SDK_QT6)"'
     1230        @$(ECHO) '  PATH_SDK_QT6_INC       = "$(PATH_SDK_QT6_INC)"'
     1231        @$(ECHO) '  PATH_SDK_QT6_LIB       = "$(PATH_SDK_QT6_LIB)"'
     1232        @$(ECHO) '  PATH_SDK_QT6_LIB.amd64 = "$(PATH_SDK_QT6_LIB.amd64)"'
     1233        @$(ECHO) '  PATH_SDK_QT6_LIB.x86   = "$(PATH_SDK_QT6_LIB.x86)"'
     1234        @$(ECHO) 'The Qt6 TOOL variables:'
     1235        @$(ECHO) '  PATH_TOOL_QT6_BIN      = "$(PATH_TOOL_QT6_BIN)"'
     1236        @$(ECHO) '  PATH_TOOL_QT6_LIBEXEC  = "$(PATH_TOOL_QT6_LIBEXEC)"'
     1237        @$(ECHO) '  TOOL_QT6_BIN_SUFF      = "$(TOOL_QT6_BIN_SUFF)"'
     1238        @$(ECHO) '  TOOL_QT6_LIBEXEC_SUFF  = "$(TOOL_QT6_LIBEXEC_SUFF)"'
     1239        @$(ECHO) '  TOOL_QT6_MOC           = "$(TOOL_QT6_MOC)"'
     1240        @$(ECHO) '  TOOL_QT6_UIC           = "$(TOOL_QT6_UIC)"'
     1241        @$(ECHO) '  TOOL_QT6_RCC           = "$(TOOL_QT6_RCC)"'
     1242        @$(ECHO) '  TOOL_QT6_LRC           = "$(TOOL_QT6_LRC)"'
     1243        @$(ECHO) '  TOOL_QT6_LUPDATE       = "$(TOOL_QT6_LUPDATE)"'
     1244
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette