-
Notifications
You must be signed in to change notification settings - Fork 285
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
IOS Toolchain for static probe #261
base: master
Are you sure you want to change the base?
Conversation
CMakeLists.txt
Outdated
@@ -233,8 +233,8 @@ endif() | |||
# linker flags | |||
if(NOT ECM_ENABLE_SANITIZERS AND (CMAKE_SYSTEM_NAME MATCHES Linux OR CMAKE_SYSTEM_NAME STREQUAL GNU)) | |||
if(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") | |||
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--fatal-warnings -Wl,--no-undefined -lc ${CMAKE_SHARED_LINKER_FLAGS}") | |||
set(CMAKE_MODULE_LINKER_FLAGS "-Wl,--fatal-warnings -Wl,--no-undefined -lc ${CMAKE_MODULE_LINKER_FLAGS}") | |||
set(CMAKE_SHARED_LINKER_FLAGS "-lc ${CMAKE_SHARED_LINKER_FLAGS}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why removing the flags ?
CMakeLists.txt
Outdated
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--fatal-warnings -Wl,--no-undefined -lc ${CMAKE_SHARED_LINKER_FLAGS}") | ||
set(CMAKE_MODULE_LINKER_FLAGS "-Wl,--fatal-warnings -Wl,--no-undefined -lc ${CMAKE_MODULE_LINKER_FLAGS}") | ||
set(CMAKE_SHARED_LINKER_FLAGS "-lc ${CMAKE_SHARED_LINKER_FLAGS}") | ||
set(CMAKE_MODULE_LINKER_FLAGS "-lc ${CMAKE_MODULE_LINKER_FLAGS}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same
Install.txt
Outdated
% export QT_DIR=<QT HOME> <--- set to QT's home | ||
% mkdir build | ||
% cd build | ||
% cmake -DCMAKE_TOOLCHAIN_FILE=../cmake/Toolchain-IOS.cmake -DCMAKE_PREFIX_PATH=${QT_DIR}/5.7/ios -DGAMMARAY_STATIC_PROBE=TRUE -DCMAKE_INSTALL_PREFIX=$SYSROOT/usr/ -DGAMMARAY_BUILD_UI=OFF -G Xcode .. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GAMMARAY_BUILD_UI is already OFF for static probe.
Do use default Unix makefiles (gcc/clang), not xcode.
% mkdir build | ||
% cd build | ||
% cmake -DCMAKE_TOOLCHAIN_FILE=../cmake/Toolchain-IOS.cmake -DCMAKE_PREFIX_PATH=${QT_DIR}/5.7/ios -DGAMMARAY_STATIC_PROBE=TRUE -DCMAKE_INSTALL_PREFIX=$SYSROOT/usr/ -DGAMMARAY_BUILD_UI=OFF -G Xcode .. | ||
% /usr/bin/xcodebuild -project GammaRay.xcodeproj build -target gammaray_probe -configuration Release |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If requested changes are done, then a simple: make is needed.
@@ -0,0 +1,66 @@ | |||
# Basic cmake toolchain file for IOS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would have simply duplicate the OSX one and change i686 to arm (or armv7).
If any errors, report them to us.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried that + unix makefiles as the backend but I'm afraid I could not get it to generate arm code, only x86. On my machine at least it's not as simple as just duplicating the OSX toolchain and changing the architecture. It could be my setup is broken for gcc. Feel free to decline this PR as it doesn't really fit your requirements.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested with Qt 5.9.2 and master - does not works.
Everything is built as x86_64 using unix makefile generator, and fails to build with Xcode generator.
All using the default sdk (ie, no version path).
Is it possible you rebase / fix your changes ?
Paul Nader seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
Enable building an IOS static probe library