2018-04-17 19:25:31 +02:00
|
|
|
include(vcpkg_common_functions)
|
|
|
|
|
2018-11-12 19:55:47 +09:00
|
|
|
if(EXISTS "${CURRENT_INSTALLED_DIR}/include/openjpeg.h")
|
|
|
|
message(FATAL_ERROR "Can't build VXL with non built-in OpenJpeg in current version. Please remove OpenJpeg, and try install VXL again.")
|
|
|
|
endif()
|
|
|
|
|
2018-04-17 19:25:31 +02:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
2018-04-17 14:46:50 -07:00
|
|
|
REPO vxl/vxl
|
2018-11-12 19:55:47 +09:00
|
|
|
REF v1.18.0
|
|
|
|
SHA512 6666d647b2e7010b91cb0b05016b5f49ae46d198f6bd160fe13fc09bc674eff5b937331fa11d81a8496473968b63452d950eee4fc2512152af57304a14bed63f
|
2018-04-17 19:25:31 +02:00
|
|
|
HEAD_REF master
|
|
|
|
)
|
|
|
|
|
2018-11-12 19:55:47 +09:00
|
|
|
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "dynamic" SHARED_LIBS)
|
|
|
|
|
|
|
|
set(USE_WIN_WCHAR_T OFF)
|
|
|
|
if(WIN32)
|
|
|
|
set(USE_WIN_WCHAR_T ON)
|
|
|
|
endif()
|
|
|
|
|
2018-04-17 19:25:31 +02:00
|
|
|
vcpkg_configure_cmake(
|
|
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
|
|
PREFER_NINJA
|
2018-04-17 14:46:50 -07:00
|
|
|
OPTIONS
|
2018-11-12 19:55:47 +09:00
|
|
|
-DBUILD_SHARED_LIBS=${VXL_SHARED_LIBS}
|
2018-04-17 14:46:50 -07:00
|
|
|
-DBUILD_EXAMPLES=OFF
|
2018-11-12 19:55:47 +09:00
|
|
|
-DBUILD_TESTING=OFF
|
|
|
|
-DVXL_FORCE_V3P_BZLIB2=OFF
|
|
|
|
-DVXL_USING_NATIVE_BZLIB2=TRUE # for disable build built-in bzip2 (v3p/bzlib/CMakeLists.txt#L10-L26)
|
|
|
|
-DVXL_FORCE_V3P_CLIPPER=ON # TODO : need add clipper port to turn off
|
|
|
|
-DVXL_FORCE_V3P_DCMTK=OFF
|
|
|
|
-DVXL_FORCE_V3P_GEOTIFF=OFF
|
|
|
|
-DVXL_FORCE_V3P_J2K=OFF
|
|
|
|
-DVXL_FORCE_V3P_JPEG=OFF
|
|
|
|
-DVXL_FORCE_V3P_OPENJPEG2=ON # TODO : need fix compile error when using openjpeg port to turn off
|
|
|
|
-DVXL_FORCE_V3P_PNG=OFF
|
|
|
|
-DVXL_FORCE_V3P_TIFF=OFF
|
|
|
|
-DVXL_FORCE_V3P_ZLIB=OFF
|
|
|
|
-DVXL_USE_DCMTK=OFF # TODO : need fix dcmtk support to turn on
|
|
|
|
-DXVL_USE_GEOTIFF=ON
|
|
|
|
-DVXL_USE_WIN_WCHAR_T=${USE_WIN_WCHAR_T}
|
2018-04-17 19:25:31 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_install_cmake()
|
|
|
|
|
2018-04-17 14:46:50 -07:00
|
|
|
vcpkg_fixup_cmake_targets(CONFIG_PATH share/vxl/cmake)
|
2018-04-17 19:25:31 +02:00
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
|
|
|
|
|
|
|
file(INSTALL ${SOURCE_PATH}/core/vxl_copyright.h DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
|