[cspice] Make URLs stable (#22794)

This commit is contained in:
Robert Schumacher 2022-01-26 15:19:58 -08:00 committed by GitHub
parent c482f03676
commit 173371c738
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 19 additions and 15 deletions

View File

@ -1,36 +1,34 @@
if (VCPKG_TARGET_IS_WINDOWS)
if (VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
set(URL "https://naif.jpl.nasa.gov/pub/naif/toolkit/C/PC_Windows_VisualC_32bit/packages/cspice.zip")
set(FILENAME "cspice_32bit.zip")
set(SUBPATH "PC_Windows_VisualC_32bit/packages/cspice.zip")
set(SHA512 1949fd12b30ca0e42f53311a97d8571e68737f6a667a56946d3415ee715dda0a1adca9bfc985b9b9447084189c50d261f2c00960cbe2ddf6a1d1d92cf8fa17ab)
elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
set(URL "https://naif.jpl.nasa.gov/pub/naif/toolkit/C/PC_Windows_VisualC_64bit/packages/cspice.zip")
set(FILENAME "cspice_64bit.zip")
set(SUBPATH "PC_Windows_VisualC_64bit/packages/cspice.zip")
set(SHA512 5457f24279fb485b0ac92713dab026d1c1ed766a358fcf7d9ce3f70693e75da85a656e72b1ada4dc334e9e68d6c0eb42b2a31f3ad0c83b491dd3afc79e5cda98)
endif()
elseif(VCPKG_TARGET_IS_OSX)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
set(URL "https://naif.jpl.nasa.gov/pub/naif/toolkit//C/MacIntel_OSX_AppleC_64bit/packages/cspice.tar.Z")
set(FILENAME "cspice_64bit.tar.Z")
set(SUBPATH "MacIntel_OSX_AppleC_64bit/packages/cspice.tar.Z")
set(SHA512 ea9a32c763cd54303de180b4895a195cd5ef6774051f18a1812f2fff39adc0ca9d5dd7878853af40e766882e79a0f542a45139656fb79fb4b436c4bc5bdecddc)
elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64")
set(URL "https://naif.jpl.nasa.gov/pub/naif/toolkit//C/MacM1_OSX_clang_64bit/packages/cspice.tar.Z")
set(FILENAME "cspice_64bit.tar.Z")
set(SUBPATH "MacM1_OSX_clang_64bit/packages/cspice.tar.Z")
set(SHA512 a64f028ec1935dbc7f8d03c903fbfa40cfff097ec4aa0ca4aa1d2ee08561833000e7caf99d6550b06d2a0874cbaf1767382e7a9aea6a39228f3eaa89c6c31a6d)
endif()
else()
if ((VCPKG_TARGET_ARCHITECTURE STREQUAL "x86") OR (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm"))
set(URL "https://naif.jpl.nasa.gov/pub/naif/toolkit/C/PC_Linux_GCC_32bit/packages/cspice.tar.Z")
set(FILENAME "cspice_32bit.tar.Z")
set(SUBPATH "PC_Linux_GCC_32bit/packages/cspice.tar.Z")
set(SHA512 22a6250376e9f98d75ecc8682c5432a07a89addc9812010ad97059491e2c19cab418d7aa3f591bded9df132fcfb6865686f0ecfe70821ad31061ae2f7b165f2b)
elseif((VCPKG_TARGET_ARCHITECTURE STREQUAL "x64") OR (VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64"))
set(URL "https://naif.jpl.nasa.gov/pub/naif/toolkit/C/PC_Linux_GCC_64bit/packages/cspice.tar.Z")
set(FILENAME "cspice_64bit.tar.Z")
set(SUBPATH "PC_Linux_GCC_64bit/packages/cspice.tar.Z")
set(SHA512 59946f628284cd31c75a23c152d725ae7e01b179f97c52b98518eceeda54bc38875b1dd93dc17574c0bf00e706e0ee35d06ecb5d7871d49633baa8f16eb6c7c8)
endif()
endif()
vcpkg_download_distfile(ARCHIVE URLS ${URL} FILENAME ${FILENAME} SHA512 ${SHA512})
set(VERSION 67)
set(URL "https://naif.jpl.nasa.gov/pub/naif/misc/toolkit_N00${VERSION}/C/${SUBPATH}")
get_filename_component(ext "${SUBPATH}" EXT)
string(SUBSTRING "${SHA512}" 0 6 subsha)
vcpkg_download_distfile(ARCHIVE URLS "${URL}" FILENAME "cspice-${subsha}${ext}" SHA512 "${SHA512}")
set(PATCHES isatty.patch)
if (NOT VCPKG_TARGET_IS_WINDOWS)

View File

@ -1,6 +1,7 @@
{
"name": "cspice",
"version-string": "67",
"version": "67",
"port-version": 1,
"description": "NASA C SPICE toolkit",
"homepage": "https://naif.jpl.nasa.gov/naif/toolkit_C.html",
"supports": "!((arm | arm64) & windows)",

View File

@ -1670,7 +1670,7 @@
},
"cspice": {
"baseline": "67",
"port-version": 0
"port-version": 1
},
"ctbignum": {
"baseline": "2019-08-02",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "2ad682ffd7b5b7cb6316fd77dc99dda7e6100731",
"version": "67",
"port-version": 1
},
{
"git-tree": "1c8f251f7712ff12e7b94d059a56eff69915fb43",
"version-string": "67",