Re: [cmake-developers] [CMake 0015669]: XCTest for iOS target has incorrect TEST_HOST
Hi Brad, On 21/08/15 15:36, Brad King wrote: Thanks. I merged to 'next' for testing last night. Please take a look at the failures: https://open.cdash.org/testSummary.php?project=1name=RunCMake.XcodeProjectdate=2015-08-21 It's all green now: https://open.cdash.org/testSummary.php?project=1name=RunCMake.XcodeProjectdate=2015-08-24 Thanks, Gregor -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers
Re: [cmake-developers] [CMake 0015669]: XCTest for iOS target has incorrect TEST_HOST
On 08/19/2015 03:46 PM, Gregor Jasny via cmake-developers wrote: The problem I see with this approach is that CMake provides no official iOS toolchain file (maybe we should?). And the popular cmake-ios project [1] for example sets SYSTEM_NAME to Darwin. Yes. This should be resolved by splitting the proper pieces of such toolchain files out into a Modules/Platform/iOS.cmake file. I'm not familiar enough with iOS development to do this though. Maybe we can detect iOS via SDK string for now. Okay. I pushed the ios-app-bundle-layout topic branch together with a test case. Thanks. I merged to 'next' for testing last night. Please take a look at the failures: https://open.cdash.org/testSummary.php?project=1name=RunCMake.XcodeProjectdate=2015-08-21 Thanks, -Brad -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers
Re: [cmake-developers] [CMake 0015669]: XCTest for iOS target has incorrect TEST_HOST
Hello, On 29/07/15 14:07, Mantis Bug Tracker wrote: == http://www.cmake.org/Bug/view.php?id=15669 == this bug caused by different App Bundle layout in MacOSX and iOS. Attached you'll find my proposed patch. Do you have a better idea to detect the usage of iphone/simulator SDK? Maybe we should handle this in the platform Darwin modules? Thanks, Gregor From fdbef203172af5d5603de9383077fbb503661f3f Mon Sep 17 00:00:00 2001 From: Gregor Jasny gja...@googlemail.com Date: Thu, 30 Jul 2015 13:26:10 +0200 Subject: [PATCH] Fix iOS App Bundle layout In contrast to Mac OS X App bundle layout the iOS one lacks the Contents/MacOSX structure. See also the Bundle Structures documentation in Mac Developer Library: https://developer.apple.com/library/mac/documentation/CoreFoundation/Conceptual/CFBundles/BundleTypes/BundleTypes.html --- Source/cmTarget.cxx | 26 +++--- Source/cmTarget.h | 3 +++ 2 files changed, 26 insertions(+), 3 deletions(-) diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index cf33791..c39f9c0 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -632,6 +632,22 @@ bool cmTarget::IsBundleOnApple() const } // +bool cmTarget::IsIosSdkOnApple() const +{ + if (!this-IsApple) +{ +return false; +} + + std::string sdkRoot; + sdkRoot = this-GetMakefile()-GetSafeDefinition(CMAKE_OSX_SYSROOT); + sdkRoot = cmSystemTools::LowerCase(sdkRoot); + + return sdkRoot.find(iphoneos) == 0 || + sdkRoot.find(/iphoneos) != std::string::npos; +} + +// static bool processSources(cmTarget const* tgt, const std::vectorcmTargetInternals::TargetPropertyEntry* entries, std::vectorstd::string srcs, @@ -6707,9 +6723,13 @@ std::string cmTarget::GetAppBundleDirectory(const std::string config, bool contentOnly) const { std::string fpath = this-GetFullName(config, false); - fpath += .app/Contents; - if(!contentOnly) -fpath += /MacOS; + fpath += .app; + if(!this-IsIosSdkOnApple()) +{ +fpath += /Contents; +if(!contentOnly) + fpath += /MacOS; +} return fpath; } diff --git a/Source/cmTarget.h b/Source/cmTarget.h index f567d50..d383219 100644 --- a/Source/cmTarget.h +++ b/Source/cmTarget.h @@ -524,6 +524,9 @@ public: or CFBundle on Apple. */ bool IsBundleOnApple() const; + /** Return whether this target uses iOS SDK on Apple */ + bool IsIosSdkOnApple() const; + /** Return the framework version string. Undefined if IsFrameworkOnApple returns false. */ std::string GetFrameworkVersion() const; -- 2.4.3 -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers
Re: [cmake-developers] [CMake 0015669]: XCTest for iOS target has incorrect TEST_HOST
On 07/30/2015 07:38 AM, Gregor Jasny via cmake-developers wrote: Do you have a better idea to detect the usage of iphone/simulator SDK? Maybe we should handle this in the platform Darwin modules? This occurs when cross-compiling to iOS, so should we check for CMAKE_SYSTEM_NAME set to iOS? There is already code to do this for Android. -Brad -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers
[cmake-developers] [CMake 0015669]: XCTest for iOS target has incorrect TEST_HOST
The following issue has been SUBMITTED. == http://www.cmake.org/Bug/view.php?id=15669 == Reported By:Seppo Tomperi Assigned To: == Project:CMake Issue ID: 15669 Category: Modules Reproducibility:always Severity: minor Priority: normal Status: new == Date Submitted: 2015-07-29 08:07 EDT Last Modified: 2015-07-29 08:07 EDT == Summary:XCTest for iOS target has incorrect TEST_HOST Description: Path to executable in TEST_HOST is not correct when targeting iOS device. Steps to Reproduce: unzip iOSNavAppXCTest.zip cd iOSNavAppXCTest mkdir build cd build cmake -G Xcode .. grep TEST_HOST NavApp3.xcodeproj/project.pbxproj TEST_HOST variable has extra directory: Contents/MacOS, which is not there. Executable is in NavApp3.app-directory. If Contents/MacOS is edited away from project file then project works and XCTests can be run in simulator and on iPhone. == Issue History Date ModifiedUsername FieldChange == 2015-07-29 08:07 Seppo Tomperi New Issue 2015-07-29 08:07 Seppo Tomperi File Added: iOSNavAppXCTest.zip == -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers