View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0014258 | CMake | CMake | public | 2013-06-29 06:12 | 2016-05-02 08:30 | ||||
Reporter | Andrew S. | ||||||||
Assigned To | |||||||||
Priority | high | Severity | major | Reproducibility | always | ||||
Status | closed | Resolution | fixed | ||||||
Platform | OS | OS Version | |||||||
Product Version | CMake 2.8.11.1 | ||||||||
Target Version | CMake 3.5 | Fixed in Version | CMake 3.5 | ||||||
Summary | 0014258: MACOSX_BUNDLE path problem when building for iOS with Xcode | ||||||||
Description | (Copied from backlogged issue submitted by Duron http://public.kitware.com/Bug/view.php?id=12451 [^]): I'm not sure if building for iOS is officially supported, but here goes... When building for iOS with MACOSX_BUNDLE specified on the target, this generates an XCODE_DEPEND_HELPER.make with Foo.app/Contents/MacOS/foo paths in it. However for iOS builds, Xcode places the executable 'foo' in Foo.app/foo. I couldn't find an option to change this behavior. The result is that dependency checking does not work and a clean build is required every time the app is compiled. End of original message ---- This bug is very annoying: you always have to change something each time in a main target to force full project relink when developing a depend library. See proposed patch below. It introduces MACOSX_BUNDLE_BUILD_FOR_IOS property which will allow to remove "Contents/MacOS" from output paths when building for iOS. The patch is fully working - tried successfully on our big project. | ||||||||
Steps To Reproduce | Set up an iOS project by setting CMAKE_OSX_SYSROOT, CMAKE_OSX_ARCHITECTURES and MACOSX_BUNDLE_GUI_IDENTIFIER. Specify MACOSX_BUNDLE for the target executable. Make a change in a dependency and rebuild the app. The app will not be updated. | ||||||||
Additional Information | diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index b14db43..fb3902f 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -6473,6 +6473,8 @@ std::string cmTarget::GetAppBundleDirectory(const char* config, bool contentOnly) { std::string fpath = this->GetFullName(config, false); + if (this->GetPropertyAsBool("MACOSX_BUNDLE_BUILD_FOR_IOS")) + return fpath + ".app"; fpath += ".app/Contents"; if(!contentOnly) fpath += "/MacOS"; | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
Relationships | ||||||
|
Relationships |
Notes | |
(0033441) Brad King (manager) 2013-07-01 15:43 |
Clinton, will your post-2.8.11 refactoring resolve this? |
(0033443) Clinton Stimpson (developer) 2013-07-01 15:56 |
No, the refactoring doesn't resolve this. It didn't really cover application bundles, let alone various types of application bundles. If there was another something controlling whether we are building for iOS, I'm wondering why we need another flag, MACOSX_BUNDLE_BUILD_FOR_IOS. I ask because somehow the cmake generated Xcode project was told to create Foo.app/foo instead of Foo.app/Contents/MacOS/foo. It would help if one attached a sample CMakeLists.txt file with instructions on setting up the project for iOS, or at least pointed to an existing example. |
(0033444) Brad King (manager) 2013-07-01 16:01 |
iOS project generation is not fully supported AFAIK. A possible reason the target is not going where CMake expects it is this change: http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=0c030ef7 [^] Look at the UsesDefaultOutputDir case. |
(0033445) Clinton Stimpson (developer) 2013-07-01 16:06 |
Also related is this: http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=59a22655 [^] |
(0039996) Bartosz (reporter) 2015-12-18 05:18 |
This issue was already fixed in CMake 3.5 |
(0039997) Brad King (manager) 2015-12-18 08:17 |
Re 0014258:0039996: For reference: iOS: Fix App Bundle layout https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=34f5ef56 [^] |
(0040989) Robert Maynard (manager) 2016-05-02 08:30 |
Closing resolved issues that have not been updated in more than 4 months. |
Notes |
Issue History | |||
Date Modified | Username | Field | Change |
2013-06-29 06:12 | Andrew S. | New Issue | |
2013-07-01 15:43 | Brad King | Assigned To | => Clinton Stimpson |
2013-07-01 15:43 | Brad King | Status | new => assigned |
2013-07-01 15:43 | Brad King | Note Added: 0033441 | |
2013-07-01 15:44 | Brad King | Relationship added | has duplicate 0012451 |
2013-07-01 15:46 | Brad King | Summary | MACOSX_BUNDLE path problem when => MACOSX_BUNDLE path problem when building for iOS with Xcode |
2013-07-01 15:46 | Brad King | Additional Information Updated | |
2013-07-01 15:56 | Clinton Stimpson | Note Added: 0033443 | |
2013-07-01 15:57 | Brad King | Assigned To | Clinton Stimpson => |
2013-07-01 15:57 | Brad King | Status | assigned => backlog |
2013-07-01 16:01 | Brad King | Note Added: 0033444 | |
2013-07-01 16:06 | Clinton Stimpson | Note Added: 0033445 | |
2015-12-18 05:18 | Bartosz | Note Added: 0039996 | |
2015-12-18 08:17 | Brad King | Note Added: 0039997 | |
2015-12-18 08:18 | Brad King | Status | backlog => resolved |
2015-12-18 08:18 | Brad King | Resolution | open => fixed |
2015-12-18 08:18 | Brad King | Fixed in Version | => CMake 3.5 |
2015-12-18 08:18 | Brad King | Target Version | => CMake 3.5 |
2016-05-02 08:30 | Robert Maynard | Note Added: 0040989 | |
2016-05-02 08:30 | Robert Maynard | Status | resolved => closed |
Issue History |
Copyright © 2000 - 2018 MantisBT Team |