mirror of
https://github.com/cemu-project/vcpkg.git
synced 2025-02-23 02:57:09 +01:00
Merge pull request #1263 from mmazat/master
Add qhull and flann ports, way to add pcl
This commit is contained in:
commit
c5ac989899
3
ports/flann/CONTROL
Normal file
3
ports/flann/CONTROL
Normal file
@ -0,0 +1,3 @@
|
||||
Source: flann
|
||||
Version: 1.9.1
|
||||
Description: performing fast approximate nearest neighbor searches in high dimensional spaces
|
41
ports/flann/fix-install-flann.patch
Normal file
41
ports/flann/fix-install-flann.patch
Normal file
@ -0,0 +1,41 @@
|
||||
diff --git "a/src/cpp/CMakeLists.txt" "b/src/cpp/CMakeLists.txt"
|
||||
index 49c53f0..cc58c90 100644
|
||||
--- "a/src/cpp/CMakeLists.txt"
|
||||
+++ "b/src/cpp/CMakeLists.txt"
|
||||
@@ -87,7 +87,7 @@ if (BUILD_C_BINDINGS)
|
||||
set_target_properties(flann PROPERTIES LINKER_LANGUAGE CXX)
|
||||
target_link_libraries(flann -Wl,-whole-archive flann_s -Wl,-no-whole-archive)
|
||||
else()
|
||||
- add_library(flann SHARED ${C_SOURCES})
|
||||
+ add_library(flann ${C_SOURCES})
|
||||
|
||||
if(MINGW AND OPENMP_FOUND)
|
||||
target_link_libraries(flann gomp)
|
||||
@@ -111,12 +111,12 @@ endif()
|
||||
endif(WIN32)
|
||||
|
||||
|
||||
-install (
|
||||
- TARGETS flann_cpp flann_cpp_s
|
||||
- RUNTIME DESTINATION bin
|
||||
- LIBRARY DESTINATION ${FLANN_LIB_INSTALL_DIR}
|
||||
- ARCHIVE DESTINATION ${FLANN_LIB_INSTALL_DIR}
|
||||
-)
|
||||
+#install (
|
||||
+# TARGETS flann_cpp flann_cpp_s
|
||||
+# RUNTIME DESTINATION bin
|
||||
+# LIBRARY DESTINATION ${FLANN_LIB_INSTALL_DIR}
|
||||
+# ARCHIVE DESTINATION ${FLANN_LIB_INSTALL_DIR}
|
||||
+#)
|
||||
|
||||
if (BUILD_CUDA_LIB)
|
||||
install (
|
||||
@@ -129,7 +129,7 @@ endif()
|
||||
|
||||
if (BUILD_C_BINDINGS)
|
||||
install (
|
||||
- TARGETS flann flann_s
|
||||
+ TARGETS flann
|
||||
RUNTIME DESTINATION bin
|
||||
LIBRARY DESTINATION ${FLANN_LIB_INSTALL_DIR}
|
||||
ARCHIVE DESTINATION ${FLANN_LIB_INSTALL_DIR}
|
51
ports/flann/portfile.cmake
Normal file
51
ports/flann/portfile.cmake
Normal file
@ -0,0 +1,51 @@
|
||||
# Common Ambient Variables:
|
||||
# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT}
|
||||
# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET}
|
||||
# CURRENT_PORT DIR = ${VCPKG_ROOT_DIR}\ports\${PORT}
|
||||
# PORT = current port name (zlib, etc)
|
||||
# TARGET_TRIPLET = current triplet (x86-windows, x64-windows-static, etc)
|
||||
# VCPKG_CRT_LINKAGE = C runtime linkage type (static, dynamic)
|
||||
# VCPKG_LIBRARY_LINKAGE = target library linkage type (static, dynamic)
|
||||
# VCPKG_ROOT_DIR = <C:\path\to\current\vcpkg>
|
||||
# VCPKG_TARGET_ARCHITECTURE = target architecture (x64, x86, arm)
|
||||
#
|
||||
|
||||
include(vcpkg_common_functions)
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO mariusmuja/flann
|
||||
REF 1.9.1
|
||||
SHA512 0da78bb14111013318160dd3dee1f93eb6ed077b18439fd6496017b62a8a6070cc859cfb3e08dad4c614e48d9dc1da5f7c4a21726ee45896d360506da074a6f7
|
||||
)
|
||||
|
||||
vcpkg_apply_patches(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PATCHES "${CMAKE_CURRENT_LIST_DIR}/fix-install-flann.patch"
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
#PREFER_NINJA # Disable this option if project cannot be built with Ninja
|
||||
OPTIONS
|
||||
-DBUILD_EXAMPLES=OFF
|
||||
-DBUILD_PYTHON_BINDINGS=OFF
|
||||
-DBUILD_MATLAB_BINDINGS=OFF
|
||||
-DBUILD_DOC=OFF
|
||||
|
||||
OPTIONS_RELEASE
|
||||
-DFLANN_LIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/lib
|
||||
|
||||
OPTIONS_DEBUG
|
||||
-DFLANN_LIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/debug/lib
|
||||
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
|
||||
#clean
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
|
||||
# Handle copyright
|
||||
file(COPY ${SOURCE_PATH}/README.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/flann)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/share/flann/README.md ${CURRENT_PACKAGES_DIR}/share/flann/copyright)
|
3
ports/qhull/CONTROL
Normal file
3
ports/qhull/CONTROL
Normal file
@ -0,0 +1,3 @@
|
||||
Source: qhull
|
||||
Version:1.0
|
||||
Description: computes the convex hull, Delaunay triangulation, Voronoi diagram
|
46
ports/qhull/portfile.cmake
Normal file
46
ports/qhull/portfile.cmake
Normal file
@ -0,0 +1,46 @@
|
||||
# Common Ambient Variables:
|
||||
# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT}
|
||||
# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET}
|
||||
# CURRENT_PORT DIR = ${VCPKG_ROOT_DIR}\ports\${PORT}
|
||||
# PORT = current port name (zlib, etc)
|
||||
# TARGET_TRIPLET = current triplet (x86-windows, x64-windows-static, etc)
|
||||
# VCPKG_CRT_LINKAGE = C runtime linkage type (static, dynamic)
|
||||
# VCPKG_LIBRARY_LINKAGE = target library linkage type (static, dynamic)
|
||||
# VCPKG_ROOT_DIR = <C:\path\to\current\vcpkg>
|
||||
# VCPKG_TARGET_ARCHITECTURE = target architecture (x64, x86, arm)
|
||||
#
|
||||
|
||||
include(vcpkg_common_functions)
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO qhull/qhull
|
||||
REF master
|
||||
SHA512 16aa9f93ce6fe8342a3b579881f10bb417679b0a70849e6b0cc5a89551e4de773a43bb0d54948196690d68d168f3a2a215e4600745ff1566302b0b426565fb25
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
#PREFER_NINJA # Disable this option if project cannot be built with Ninja
|
||||
OPTIONS
|
||||
-DINCLUDE_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/include
|
||||
-DMAN_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/doc/qhull
|
||||
-DDOC_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/doc/qhull
|
||||
|
||||
OPTIONS_RELEASE
|
||||
-Dqhull_TARGETS_INSTALL=qhullcpp
|
||||
-DLIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/lib
|
||||
|
||||
OPTIONS_DEBUG
|
||||
-Dqhull_TARGETS_INSTALL=qhullcpp_d
|
||||
-DLIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/debug/lib
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
file(GLOB_RECURSE HTMFILES ${CURRENT_PACKAGES_DIR}/include/*.htm)
|
||||
file(REMOVE ${HTMFILES})
|
||||
|
||||
# Handle copyright
|
||||
file(COPY ${SOURCE_PATH}/README.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/qhull)
|
||||
file(RENAME ${CURRENT_PACKAGES_DIR}/share/qhull/README.txt ${CURRENT_PACKAGES_DIR}/share/qhull/copyright)
|
Loading…
x
Reference in New Issue
Block a user