mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-25 11:28:59 +08:00
050e71d01d
* [various ports] remove references to CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS * [alac,benchmark,capnproto] Fix check_linkage call * [fastlz] Fix SHA512 * [coroutine] Fix dynamic build * [folly] Find double-conversion * [gamma] Use vcpkg_from_github * [librsync] Enable static builds * [netcdf-cxx4] Fix SHA512 * [octomap] Fix static build * [tidy-html5] Fix static build * [various ports] remove custom messages for shared/static builds, modernize some scripts in the meantime * [folly] Use ras0219's fix for link paths * [octomap] Fix exported targets * [uvatlas] Set tool download SHA512 * [duktape+python2] fix portfile to call configure with correct python version, manage python2 also outside win32 * [suitesparse] osx fix * [gtkmm] Call vcpkg_check_linkage after including vcpkg functions * [duktape] Resolve conflicts * [duktape] FIxed typo in Python paths * [wangle] Find zlib * [openssl-uwp] Fix SHA512 * [glib] Allow static builds on non-Windows * [suitesparse] Fix build on Windows * [multiple ports] Bump CONTROL version * [multiple ports] Fix description indent * [directxtk] Fix CONTROL file * [bde,duktape,qpid-proton] Build packages with python2 installed * [binn] remove CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS * [gdal,live555,uriparser] Fix regressions * [live555] Update to 2019.04.24
80 lines
2.9 KiB
CMake
80 lines
2.9 KiB
CMake
include(vcpkg_common_functions)
|
|
|
|
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO InsightSoftwareConsortium/ITK
|
|
REF 906736bd453e95ccf03b318d3d07cb7884285161
|
|
SHA512 8ac62262d46e7acbb0e5b2e964292ec17e1687bb162b8cec666e5b67acbe3449f093a0b1c03737e9951cb88248ed890805ffd57df6eae21220488620da833c57
|
|
HEAD_REF master
|
|
)
|
|
|
|
if ("vtk" IN_LIST FEATURES)
|
|
set(ITKVtkGlue ON)
|
|
else()
|
|
set(ITKVtkGlue OFF)
|
|
endif()
|
|
|
|
# directory path length needs to be shorter than 50 characters
|
|
set(ITK_BUILD_DIR ${CURRENT_BUILDTREES_DIR}/ITK)
|
|
if(EXISTS ${ITK_BUILD_DIR})
|
|
file(REMOVE_RECURSE ${ITK_BUILD_DIR})
|
|
endif()
|
|
file(RENAME ${SOURCE_PATH} ${ITK_BUILD_DIR})
|
|
set(SOURCE_PATH "${ITK_BUILD_DIR}")
|
|
|
|
vcpkg_configure_cmake(
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
PREFER_NINJA
|
|
DISABLE_PARALLEL_CONFIGURE
|
|
OPTIONS
|
|
-DBUILD_TESTING=OFF
|
|
-DBUILD_EXAMPLES=OFF
|
|
-DDO_NOT_INSTALL_ITK_TEST_DRIVER=ON
|
|
-DITK_INSTALL_DATA_DIR=share/itk/data
|
|
-DITK_INSTALL_DOC_DIR=share/itk/doc
|
|
-DITK_INSTALL_PACKAGE_DIR=share/itk
|
|
-DITK_LEGACY_REMOVE=ON
|
|
-DITK_FUTURE_LEGACY_REMOVE=ON
|
|
-DITK_USE_64BITS_IDS=ON
|
|
-DITK_USE_CONCEPT_CHECKING=ON
|
|
#-DITK_USE_SYSTEM_LIBRARIES=ON # enables USE_SYSTEM for all third party libraries, some of which do not have vcpkg ports such as CastXML, SWIG, MINC etc
|
|
-DITK_USE_SYSTEM_DOUBLECONVERSION=ON
|
|
-DITK_USE_SYSTEM_EXPAT=ON
|
|
-DITK_USE_SYSTEM_JPEG=ON
|
|
-DITK_USE_SYSTEM_PNG=ON
|
|
-DITK_USE_SYSTEM_TIFF=ON
|
|
-DITK_USE_SYSTEM_ZLIB=ON
|
|
-DITK_USE_SYSTEM_EIGEN=ON
|
|
# This should be turned on some day, however for now ITK does download specific versions so it shouldn't spontaneously break
|
|
-DITK_FORBID_DOWNLOADS=OFF
|
|
|
|
-DITK_SKIP_PATH_LENGTH_CHECKS=ON
|
|
|
|
# I haven't tried Python wrapping in vcpkg
|
|
#-DITK_WRAP_PYTHON=ON
|
|
#-DITK_PYTHON_VERSION=3
|
|
|
|
-DITK_USE_SYSTEM_HDF5=ON # HDF5 was problematic in the past
|
|
-DModule_ITKVtkGlue=${ITKVtkGlue} # optional feature
|
|
|
|
-DModule_IOSTL=ON # example how to turn on a non-default module
|
|
-DModule_MorphologicalContourInterpolation=ON # example how to turn on a remote module
|
|
-DModule_RLEImage=ON # example how to turn on a remote module
|
|
${ADDITIONAL_OPTIONS}
|
|
)
|
|
|
|
vcpkg_install_cmake()
|
|
vcpkg_copy_pdbs()
|
|
|
|
vcpkg_fixup_cmake_targets() # combines release and debug build configurations
|
|
|
|
file(RENAME ${CURRENT_PACKAGES_DIR}/vcl_compiler_detection.h ${CURRENT_PACKAGES_DIR}/include/ITK-5.0/vcl_compiler_detection.h)
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/vcl_compiler_detection.h)
|
|
|
|
# Handle copyright
|
|
file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/itk)
|
|
file(RENAME ${CURRENT_PACKAGES_DIR}/share/itk/LICENSE ${CURRENT_PACKAGES_DIR}/share/itk/copyright)
|