aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLevin Li <lilinfeng303@outlook.com>2021-07-27 02:08:55 +0800
committerGitHub <noreply@github.com>2021-07-26 11:08:55 -0700
commit2ded2ea944328981bbb3d0aa4da5f76d707d67ef (patch)
tree66566534d314476e54e53b3dd3c61fae4f2fcb4c
parente2d85ffca65240503148020dcc3e1daf992d3579 (diff)
downloadvcpkg-2ded2ea944328981bbb3d0aa4da5f76d707d67ef.tar.gz
vcpkg-2ded2ea944328981bbb3d0aa4da5f76d707d67ef.zip
[cspice] Support building in UWP (#19109)
* Make cspice work on UWP * Bump cspice port version
-rw-r--r--ports/cspice/CMakeLists.txt4
-rw-r--r--ports/cspice/CONTROL3
-rw-r--r--ports/cspice/portfile.cmake7
-rw-r--r--versions/baseline.json2
-rw-r--r--versions/c-/cspice.json5
5 files changed, 14 insertions, 7 deletions
diff --git a/ports/cspice/CMakeLists.txt b/ports/cspice/CMakeLists.txt
index 0ccfcfab6..899a94033 100644
--- a/ports/cspice/CMakeLists.txt
+++ b/ports/cspice/CMakeLists.txt
@@ -15,7 +15,7 @@ endif()
target_include_directories(cspice PUBLIC "${INCLUDE_PATH}")
if (WIN32)
- target_compile_definitions(cspice PUBLIC "_COMPLEX_DEFINED;MSDOS;OMIT_BLANK_CC;NON_ANSI_STDIO")
+ target_compile_definitions(cspice PUBLIC "_COMPLEX_DEFINED;MSDOS;OMIT_BLANK_CC;NON_ANSI_STDIO;_CRT_SECURE_NO_WARNINGS")
set_target_properties(cspice PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS TRUE)
elseif (UNIX)
target_compile_definitions(cspice PUBLIC "NON_UNIX_STDIO")
@@ -29,7 +29,7 @@ endif ()
if (NOT _SKIP_HEADERS)
file(GLOB SPICE_HEADERS ${INCLUDE_PATH}/*.h)
- install(FILES ${SPICE_HEADERS} DESTINATION include/cspice)
+ install(FILES ${SPICE_HEADERS} DESTINATION include)
endif()
set_target_properties(
diff --git a/ports/cspice/CONTROL b/ports/cspice/CONTROL
index 310fbe48b..00c2943a3 100644
--- a/ports/cspice/CONTROL
+++ b/ports/cspice/CONTROL
@@ -1,6 +1,5 @@
Source: cspice
Version: 66
-Port-Version: 3
+Port-Version: 4
Homepage: https://naif.jpl.nasa.gov/naif/toolkit_C.html
Description: NASA C SPICE toolkit
-Supports: !uwp
diff --git a/ports/cspice/portfile.cmake b/ports/cspice/portfile.cmake
index 554c7b9d3..667785cac 100644
--- a/ports/cspice/portfile.cmake
+++ b/ports/cspice/portfile.cmake
@@ -1,5 +1,3 @@
-vcpkg_fail_port_install(ON_TARGET "uwp")
-
if (VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
if (VCPKG_TARGET_IS_WINDOWS)
vcpkg_download_distfile(ARCHIVE
@@ -60,6 +58,11 @@ if (VCPKG_LIBRARY_LINKAGE STREQUAL static)
set(_STATIC_BUILD ON)
endif()
+if (VCPKG_TARGET_IS_UWP)
+ set(VCPKG_C_FLAGS "/sdl- ${VCPKG_C_FLAGS}")
+ set(VCPKG_CXX_FLAGS "/sdl- ${VCPKG_CXX_FLAGS}")
+endif()
+
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
diff --git a/versions/baseline.json b/versions/baseline.json
index db7bc7632..1a7ac3680 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -1538,7 +1538,7 @@
},
"cspice": {
"baseline": "66",
- "port-version": 3
+ "port-version": 4
},
"ctbignum": {
"baseline": "2019-08-02",
diff --git a/versions/c-/cspice.json b/versions/c-/cspice.json
index 59a41ecb2..23ae3688c 100644
--- a/versions/c-/cspice.json
+++ b/versions/c-/cspice.json
@@ -1,6 +1,11 @@
{
"versions": [
{
+ "git-tree": "de8a1c53f62f307ac805ace26e3b9c9ece91829a",
+ "version-string": "66",
+ "port-version": 4
+ },
+ {
"git-tree": "743b26ef365d681a5252d2d72a58aa8c2e76d80b",
"version-string": "66",
"port-version": 3