diff options
Diffstat (limited to 'Tests')
5 files changed, 0 insertions, 102 deletions
diff --git a/Tests/RunCMake/CMakePackage/ApplePlatformGenSubdir-stdout.txt b/Tests/RunCMake/CMakePackage/ApplePlatformGenSubdir-stdout.txt deleted file mode 100644 index 8821dad..0000000 --- a/Tests/RunCMake/CMakePackage/ApplePlatformGenSubdir-stdout.txt +++ /dev/null @@ -1,3 +0,0 @@ -(-- )?Hello from platform switch -(-- )?Hello from arch switch -(-- )?Hello from pkg_a diff --git a/Tests/RunCMake/CMakePackage/ApplePlatformGenSubdir.cmake b/Tests/RunCMake/CMakePackage/ApplePlatformGenSubdir.cmake deleted file mode 100644 index a8a3168..0000000 --- a/Tests/RunCMake/CMakePackage/ApplePlatformGenSubdir.cmake +++ /dev/null @@ -1,50 +0,0 @@ -set(CMAKE_INSTALL_DATADIR share) -set(SWITCH_DIR platform/cmake) - -include(CMakePackageConfigHelpers) - -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/pkg_a-config.cmake.in [[ -@PACKAGE_INIT@ -include("@PACKAGE_SWITCH_DIR@/platform-switch.cmake") -include("@PACKAGE_CMAKE_INSTALL_DATADIR@/pkg_a_included.cmake") -]]) -configure_package_config_file( - ${CMAKE_CURRENT_BINARY_DIR}/pkg_a-config.cmake.in - ${CMAKE_CURRENT_BINARY_DIR}/install/pkg_a-config.cmake - INSTALL_DESTINATION . - PATH_VARS CMAKE_INSTALL_DATADIR SWITCH_DIR -) -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/install/${CMAKE_INSTALL_DATADIR}/pkg_a_included.cmake - [[message(STATUS "Hello from pkg_a")]] -) - -# To expose re-using the same package prefix variable, we need to use a -# different install prefix but still with the same package name. This is -# really contrived and not representative of what a package should do. -generate_apple_platform_selection_file( - ${CMAKE_CURRENT_BINARY_DIR}/install/platform/cmake/platform-switch.cmake - INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX}/platform - INSTALL_DESTINATION cmake - MACOS_INCLUDE_FILE cmake/switch_included.cmake # relative to install prefix -) -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/install/platform/cmake/switch_included.cmake -[[ -message(STATUS "Hello from platform switch") -include("${CMAKE_CURRENT_LIST_DIR}/../arch/cmake/arch-switch.cmake") -]] -) - -generate_apple_architecture_selection_file( - ${CMAKE_CURRENT_BINARY_DIR}/install/platform/arch/cmake/arch-switch.cmake - INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX}/platform/arch - INSTALL_DESTINATION cmake - UNIVERSAL_ARCHITECTURES i386 x86_64 arm64 $(ARCHS_STANDARD) - UNIVERSAL_INCLUDE_FILE cmake/switch_included.cmake # relative to install prefix -) -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/install/platform/arch/cmake/switch_included.cmake - [[message(STATUS "Hello from arch switch")]] -) - -find_package(pkg_a REQUIRED NO_DEFAULT_PATH - PATHS ${CMAKE_CURRENT_BINARY_DIR}/install -) diff --git a/Tests/RunCMake/CMakePackage/NestedConfigFile-stdout.txt b/Tests/RunCMake/CMakePackage/NestedConfigFile-stdout.txt deleted file mode 100644 index a95ef87..0000000 --- a/Tests/RunCMake/CMakePackage/NestedConfigFile-stdout.txt +++ /dev/null @@ -1,2 +0,0 @@ -(-- )?Hello from pkg_a -(-- )?Hello from pkg_b diff --git a/Tests/RunCMake/CMakePackage/NestedConfigFile.cmake b/Tests/RunCMake/CMakePackage/NestedConfigFile.cmake deleted file mode 100644 index e62c46b..0000000 --- a/Tests/RunCMake/CMakePackage/NestedConfigFile.cmake +++ /dev/null @@ -1,39 +0,0 @@ -set(CMAKE_INSTALL_DATADIR share) - -include(CMakePackageConfigHelpers) - -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/pkg_a-config.cmake.in [[ -@PACKAGE_INIT@ -include("@PACKAGE_CMAKE_INSTALL_DATADIR@/pkg_a_included.cmake") -]]) -configure_package_config_file( - ${CMAKE_CURRENT_BINARY_DIR}/pkg_a-config.cmake.in - ${CMAKE_CURRENT_BINARY_DIR}/install_pkg_a/pkg_a-config.cmake - INSTALL_DESTINATION . - PATH_VARS CMAKE_INSTALL_DATADIR -) -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/install_pkg_a/share/pkg_a_included.cmake - [[message(STATUS "Hello from pkg_a")]] -) - -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/pkg_b-config.cmake.in [[ -@PACKAGE_INIT@ -include(CMakeFindDependencyMacro) -find_dependency(pkg_a NO_DEFAULT_PATH - PATHS "@CMAKE_CURRENT_BINARY_DIR@/install_pkg_a" -) -include("@PACKAGE_CMAKE_INSTALL_DATADIR@/pkg_b_included.cmake") -]]) -configure_package_config_file( - ${CMAKE_CURRENT_BINARY_DIR}/pkg_b-config.cmake.in - ${CMAKE_CURRENT_BINARY_DIR}/install_pkg_b/pkg_b-config.cmake - INSTALL_DESTINATION . - PATH_VARS CMAKE_INSTALL_DATADIR -) -file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/install_pkg_b/share/pkg_b_included.cmake - [[message(STATUS "Hello from pkg_b")]] -) - -find_package(pkg_b REQUIRED NO_DEFAULT_PATH - PATHS ${CMAKE_CURRENT_BINARY_DIR}/install_pkg_b -) diff --git a/Tests/RunCMake/CMakePackage/RunCMakeTest.cmake b/Tests/RunCMake/CMakePackage/RunCMakeTest.cmake index 6663f38..1551b55 100644 --- a/Tests/RunCMake/CMakePackage/RunCMakeTest.cmake +++ b/Tests/RunCMake/CMakePackage/RunCMakeTest.cmake @@ -4,8 +4,6 @@ if(NOT RunCMake_GENERATOR_IS_MULTI_CONFIG) set(maybe_CMAKE_BUILD_TYPE -DCMAKE_BUILD_TYPE=Release) endif() -run_cmake_with_options(NestedConfigFile ${maybe_CMAKE_BUILD_TYPE}) - function(apple_export platform system_name archs sysroot) set(RunCMake_TEST_BINARY_DIR ${RunCMake_BINARY_DIR}/apple-export-${platform}-build) string(REPLACE ";" "\\;" archs "${archs}") @@ -80,12 +78,6 @@ if(APPLE AND CMAKE_C_COMPILER_ID STREQUAL "AppleClang") set(enable_visionos 1) endif() - string(REPLACE ";" "\\;" macos_archs_for_cmd "${macos_archs}") - run_cmake_with_options(ApplePlatformGenSubdir - "-DCMAKE_OSX_ARCHITECTURES=${macos_archs_for_cmd}" - ${maybe_CMAKE_BUILD_TYPE} - ) - apple_export(macos Darwin "${macos_archs}" macosx) apple_export(ios iOS "arm64" iphoneos) apple_export(tvos tvOS "arm64" appletvos) |