Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.10.1
-
None
-
Cross-compile OSX on Linux.
```
MAKEFILE_GENERATOR = UNIX
CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname absolute_library_soname
QMAKE_INCREMENTAL_STYLE = sublib
include(../common/macx.conf)
include(../common/gcc-base-mac.conf)
include(../common/clang.conf)
include(../common/clang-mac.conf)
QMAKE_MAC_SDK_PATH=$$\{MAC_SDK_PATH}
QMAKE_XCODE_VERSION=4.3
QMAKE_XCODE_DEVELOPER_PATH=/Developer
QMAKE_MACOSX_DEPLOYMENT_TARGET = $$\{MAC_MIN_VERSION}
QMAKE_MAC_SDK=macosx
QMAKE_MAC_SDK.macosx.Path = $$\{MAC_SDK_PATH}
QMAKE_MAC_SDK.macosx.platform_name = macosx
QMAKE_MAC_SDK.macosx.SDKVersion = $$\{MAC_SDK_VERSION}
QMAKE_MAC_SDK.macosx.PlatformPath = /phony
!host_build: QMAKE_CFLAGS += -target $$\{MAC_TARGET}
!host_build: QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_CFLAGS
!host_build: QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
!host_build: QMAKE_LFLAGS += -target $$\{MAC_TARGET} -mlinker-version=$$\{MAC_LD64_VERSION}
QMAKE_AR = $$\{CROSS_COMPILE}ar cq
QMAKE_RANLIB=$$\{CROSS_COMPILE}ranlib
QMAKE_LIBTOOL=$$\{CROSS_COMPILE}libtool
QMAKE_INSTALL_NAME_TOOL=$$\{CROSS_COMPILE}install_name_tool
load(qt_config)
```Cross-compile OSX on Linux. ``` MAKEFILE_GENERATOR = UNIX CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname absolute_library_soname QMAKE_INCREMENTAL_STYLE = sublib include(../common/macx.conf) include(../common/gcc-base-mac.conf) include(../common/clang.conf) include(../common/clang-mac.conf) QMAKE_MAC_SDK_PATH=$$\{MAC_SDK_PATH} QMAKE_XCODE_VERSION=4.3 QMAKE_XCODE_DEVELOPER_PATH=/Developer QMAKE_MACOSX_DEPLOYMENT_TARGET = $$\{MAC_MIN_VERSION} QMAKE_MAC_SDK=macosx QMAKE_MAC_SDK.macosx.Path = $$\{MAC_SDK_PATH} QMAKE_MAC_SDK.macosx.platform_name = macosx QMAKE_MAC_SDK.macosx.SDKVersion = $$\{MAC_SDK_VERSION} QMAKE_MAC_SDK.macosx.PlatformPath = /phony !host_build: QMAKE_CFLAGS += -target $$\{MAC_TARGET} !host_build: QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_CFLAGS !host_build: QMAKE_CXXFLAGS += $$QMAKE_CFLAGS !host_build: QMAKE_LFLAGS += -target $$\{MAC_TARGET} -mlinker-version=$$\{MAC_LD64_VERSION} QMAKE_AR = $$\{CROSS_COMPILE}ar cq QMAKE_RANLIB=$$\{CROSS_COMPILE}ranlib QMAKE_LIBTOOL=$$\{CROSS_COMPILE}libtool QMAKE_INSTALL_NAME_TOOL=$$\{CROSS_COMPILE}install_name_tool load(qt_config) ```
-
30874fb2df83b21138860d7470a343221f7de6cb
Description
Hi, there is a bug in the mac configuration when it tries to determine QMAKE_MAC_SDK_PATH when QMAKE_MAC_SDK.macosx.Path. The bug arises because of the reuse of the 'info' variable. Fix is attached in a .patch.
in my case the issue came up because I am cross-building for OSX in a Linux box. /usr/bin/xcrun is not probably not present (I'm almost sure) but we do set a bunch of parameters like QMAKE_MAC_SDK and QMAKE_MAC_SDK.macosx.Path.
Attachments
Issue Links
- relates to
-
QTBUG-63641 OSX dirty QMAKE_MAC_SDK.$${sdk}.$${info}
- Closed