mirror of
https://github.com/apple/swift-system
synced 2026-11-24 04:38:14 +00:00
Update cmake setup so that the library can be used by SwiftPM cmake build Motivation: integrate with SwiftPM changes: * rename the top level project to SwiftSystem instead of swift-system to align with other projects * rename System to SystemPackage to align with SwifPM setup * update architectures to include arm64 * Update cmake/modules/SwiftSystemConfig.cmake.in * Update cmake/modules/SwiftSupport.cmake
25 lines
738 B
CMake
25 lines
738 B
CMake
#[[
|
|
This source file is part of the Swift System open source project
|
|
|
|
Copyright (c) 2020 Apple Inc. and the Swift System project authors
|
|
Licensed under Apache License v2.0 with Runtime Library Exception
|
|
|
|
See https://swift.org/LICENSE.txt for license information
|
|
#]]
|
|
|
|
cmake_minimum_required(VERSION 3.16.0)
|
|
project(SwiftSystem
|
|
LANGUAGES C Swift)
|
|
|
|
list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules)
|
|
|
|
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
|
|
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
|
|
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
|
|
set(CMAKE_Swift_MODULE_DIRECTORY ${CMAKE_BINARY_DIR}/swift)
|
|
|
|
include(SwiftSupport)
|
|
|
|
add_subdirectory(Sources)
|
|
add_subdirectory(cmake/modules)
|