qt5base-lts/mkspecs/common/ios/qmake.conf
Tor Arne Vestbø 6e594a9451 iOS: Move device/simulator conditionals out of common mkspecs
Instead we deal with any differenced by setting variables in the top
level makespecs, that are used by the common makespec configs.

Change-Id: Iae1fb5fef8c95778511ed400008731989b446f3c
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2013-02-26 13:19:01 +01:00

53 lines
2.1 KiB
Plaintext

#
# Common build settings for all iOS configurations
#
# Depends on:
#
# QMAKE_XCODE_DEVELOPER_PATH - set in mkspecs/common/ios/versions.conf
# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
# QMAKE_IOS_SDK_VERSION - set in mkspecs/common/ios/versions.conf
# QMAKE_IOSSIMULATOR_SDK_VERSION - set in mkspecs/common/ios/versions.conf
#
QMAKE_XCODE_TOOLCHAIN_BIN_PATH = $$QMAKE_XCODE_DEVELOPER_PATH/Toolchains/XcodeDefault.xctoolchain/usr/bin
# iOS build tools
QMAKE_CC = $$QMAKE_XCODE_TOOLCHAIN_BIN_PATH/clang
QMAKE_CXX = $$QMAKE_XCODE_TOOLCHAIN_BIN_PATH/clang++
QMAKE_FIX_RPATH = $$QMAKE_XCODE_TOOLCHAIN_BIN_PATH/install_name_tool -id
QMAKE_AR = $$QMAKE_XCODE_TOOLCHAIN_BIN_PATH/ar cq
QMAKE_RANLIB = $$QMAKE_XCODE_TOOLCHAIN_BIN_PATH/ranlib -s
QMAKE_LINK = $$QMAKE_CXX
QMAKE_LINK_SHLIB = $$QMAKE_CXX
# Check that compiler is valid
!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the clang compiler")
QMAKE_CFLAGS += -isysroot $$QMAKE_IOS_SDK_PATH
QMAKE_CXXFLAGS += -isysroot $$QMAKE_IOS_SDK_PATH
QMAKE_OBJECTIVE_CFLAGS += -isysroot $$QMAKE_IOS_SDK_PATH
QMAKE_LFLAGS += -Wl,-syslibroot,$$QMAKE_IOS_SDK_PATH
# Basic iOS frameworks needed for any GUI app
QMAKE_LFLAGS += -framework Foundation -framework UIKit -framework QuartzCore -lz
# No OpenGL ES1
QMAKE_INCDIR_OPENGL_ES1 =
QMAKE_LIBDIR_OPENGL_ES1 =
QMAKE_LIBS_OPENGL_ES1 =
# OpenGL ES2
QMAKE_INCDIR_OPENGL_ES2 = $$QMAKE_IOS_SDK/System/Library/Frameworks/OpenGLES.framework/Headers
QMAKE_LIBDIR_OPENGL_ES2 =
QMAKE_LIBS_OPENGL_ES2 = -framework OpenGLES
# No desktop OpenGL
QMAKE_INCDIR_OPENGL =
QMAKE_LIBS_OPENGL =
# Objective-C/C++ precompile flags
QMAKE_OBJCFLAGS_PRECOMPILE = -x objective-c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_OBJCFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
QMAKE_OBJCXXFLAGS_PRECOMPILE = -x objective-c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_OBJCXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE