[cmake] Update for vcpkg-provided cspice
parent
16051ed90a
commit
00ee0d4bcd
|
@ -122,6 +122,8 @@ if(ENABLE_SPICE)
|
|||
include_directories(${SPICE_INCLUDE_DIR})
|
||||
message(STATUS "Spice include directories: ${SPICE_INCLUDE_DIR}")
|
||||
add_library(CSPICE::CSPICE ALIAS Spice)
|
||||
else()
|
||||
include_directories(${CSPICE_INCLUDE_DIR})
|
||||
endif()
|
||||
add_definitions(-DUSE_SPICE)
|
||||
endif()
|
||||
|
|
|
@ -21,13 +21,16 @@
|
|||
|
||||
# Find include directory
|
||||
find_path(CSPICE_INCLUDE_DIR
|
||||
NAMES "SpiceOsc.h"
|
||||
NAMES "SpiceUsr.h"
|
||||
HINTS CSPICE_DIR
|
||||
PATH_SUFFIXES "include" "include/cspice"
|
||||
DOC "cspice include directory")
|
||||
mark_as_advanced(CSPICE_INCLUDE_DIR)
|
||||
|
||||
# Find CSPICE library
|
||||
find_library(CSPICE_LIBRARY
|
||||
NAMES "cspice" "libcspice" "cspice.a"
|
||||
HINTS CSPICE_DIR
|
||||
DOC "cspice libraries")
|
||||
mark_as_advanced(CSPICE_LIBRARY)
|
||||
|
||||
|
|
Loading…
Reference in New Issue