early-access version 2853
This commit is contained in:
18
externals/vcpkg/ports/colmap/fix-dependencies.patch
vendored
Executable file
18
externals/vcpkg/ports/colmap/fix-dependencies.patch
vendored
Executable file
@@ -0,0 +1,18 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 4759a94..3d25164 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -98,9 +98,11 @@ find_package(Boost REQUIRED COMPONENTS
|
||||
|
||||
find_package(Eigen3 REQUIRED)
|
||||
|
||||
-find_package(FreeImage REQUIRED)
|
||||
+find_package(freeimage CONFIG REQUIRED)
|
||||
+set(FREEIMAGE_LIBRARIES freeimage::FreeImage)
|
||||
|
||||
-find_package(Metis REQUIRED)
|
||||
+find_package(metis CONFIG REQUIRED)
|
||||
+set(METIS_LIBRARIES metis)
|
||||
|
||||
find_package(Glog REQUIRED)
|
||||
|
||||
83
externals/vcpkg/ports/colmap/portfile.cmake
vendored
Executable file
83
externals/vcpkg/ports/colmap/portfile.cmake
vendored
Executable file
@@ -0,0 +1,83 @@
|
||||
set(COLMAP_REF "29a1e3642a3b00734a52b21e597ea4d576485fe6") # 3.7 fix
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO colmap/colmap
|
||||
REF ${COLMAP_REF}
|
||||
SHA512 c22511592dadd1fce51baeaa5ab3ca48b0df5f1c02f9e2a97593ea1b01c5aea0e1054063a5665e2653f2c7b1b7525ce4c62ae35fb4197df614112861045b76fd
|
||||
HEAD_REF dev
|
||||
PATCHES
|
||||
fix-dependencies.patch
|
||||
)
|
||||
|
||||
if (NOT TRIPLET_SYSTEM_ARCH STREQUAL "x64" AND ("cuda" IN_LIST FEATURES OR "cuda-redist" IN_LIST FEATURES))
|
||||
message(FATAL_ERROR "Feature cuda and cuda-redist require x64 triplet.")
|
||||
endif()
|
||||
|
||||
# set GIT_COMMIT_ID and GIT_COMMIT_DATE
|
||||
if(DEFINED VCPKG_HEAD_VERSION)
|
||||
set(GIT_COMMIT_ID "${VCPKG_HEAD_VERSION}")
|
||||
else()
|
||||
set(GIT_COMMIT_ID "${COLMAP_REF}")
|
||||
endif()
|
||||
|
||||
string(TIMESTAMP COLMAP_GIT_COMMIT_DATE "%Y-%m-%d")
|
||||
|
||||
set(CUDA_ENABLED OFF)
|
||||
set(TESTS_ENABLED OFF)
|
||||
|
||||
if("cuda" IN_LIST FEATURES)
|
||||
set(CUDA_ENABLED ON)
|
||||
endif()
|
||||
|
||||
if("cuda-redist" IN_LIST FEATURES)
|
||||
set(CUDA_ENABLED ON)
|
||||
set(CUDA_ARCHS "Common")
|
||||
endif()
|
||||
|
||||
if("tests" IN_LIST FEATURES)
|
||||
set(TESTS_ENABLED ON)
|
||||
endif()
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
DISABLE_PARALLEL_CONFIGURE
|
||||
OPTIONS
|
||||
-DCUDA_ENABLED=${CUDA_ENABLED}
|
||||
-DCUDA_ARCHS=${CUDA_ARCHS}
|
||||
-DTESTS_ENABLED=${TESTS_ENABLED}
|
||||
-DGIT_COMMIT_ID=${GIT_COMMIT_ID}
|
||||
-DGIT_COMMIT_DATE=${COLMAP_GIT_COMMIT_DATE}
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
|
||||
vcpkg_cmake_config_fixup()
|
||||
|
||||
file(GLOB TOOL_FILENAMES "${CURRENT_PACKAGES_DIR}/bin/*")
|
||||
foreach(TOOL_FILENAME ${TOOL_FILENAMES})
|
||||
get_filename_component(TEST_TOOL_NAME ${TOOL_FILENAME} NAME_WLE)
|
||||
list(APPEND COLMAP_TOOL_NAMES "${TEST_TOOL_NAME}")
|
||||
endforeach()
|
||||
|
||||
vcpkg_copy_tools(TOOL_NAMES ${COLMAP_TOOL_NAMES} AUTO_CLEAN)
|
||||
|
||||
# remove empty folders and unused files
|
||||
file(REMOVE_RECURSE
|
||||
"${CURRENT_PACKAGES_DIR}/debug/include"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/share"
|
||||
"${CURRENT_PACKAGES_DIR}/include/colmap/exe"
|
||||
"${CURRENT_PACKAGES_DIR}/include/colmap/lib/Graclus/multilevelLib"
|
||||
"${CURRENT_PACKAGES_DIR}/include/colmap/tools"
|
||||
"${CURRENT_PACKAGES_DIR}/include/colmap/ui/media"
|
||||
"${CURRENT_PACKAGES_DIR}/include/colmap/ui/shaders"
|
||||
"${CURRENT_PACKAGES_DIR}/COLMAP.bat"
|
||||
"${CURRENT_PACKAGES_DIR}/RUN_TESTS.bat"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/COLMAP.bat"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/RUN_TESTS.bat"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/bin"
|
||||
)
|
||||
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
file(INSTALL "${SOURCE_PATH}/COPYING.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
10
externals/vcpkg/ports/colmap/usage
vendored
Executable file
10
externals/vcpkg/ports/colmap/usage
vendored
Executable file
@@ -0,0 +1,10 @@
|
||||
For example, under Windows, execute COLMAP as:
|
||||
|
||||
<VCPKG-ROOT>\packages\colmap_<TRIPLET>\tools\colmap\colmap.exe gui
|
||||
<VCPKG-ROOT>\packages\colmap_<TRIPLET>\tools\colmap\colmap.exe mapper
|
||||
<VCPKG-ROOT>\packages\colmap_<TRIPLET>\tools\colmap\colmap.exe ...
|
||||
|
||||
The package colmap provides CMake integration:
|
||||
|
||||
find_package(COLMAP REQUIRED)
|
||||
target_link_libraries(main ${COLMAP_LIBRARIES})
|
||||
59
externals/vcpkg/ports/colmap/vcpkg.json
vendored
Executable file
59
externals/vcpkg/ports/colmap/vcpkg.json
vendored
Executable file
@@ -0,0 +1,59 @@
|
||||
{
|
||||
"name": "colmap",
|
||||
"version-date": "2022-03-14",
|
||||
"description": "COLMAP is a general-purpose Structure-from-Motion (SfM) and Multi-View Stereo (MVS) pipeline with a graphical and command-line interface. It offers a wide range of features for reconstruction of ordered and unordered image collections. The software is licensed under the new BSD license.",
|
||||
"homepage": "https://colmap.github.io/",
|
||||
"license": "BSD-3-Clause",
|
||||
"dependencies": [
|
||||
"boost-filesystem",
|
||||
"boost-graph",
|
||||
"boost-program-options",
|
||||
"boost-system",
|
||||
"boost-test",
|
||||
{
|
||||
"name": "ceres",
|
||||
"features": [
|
||||
"lapack",
|
||||
"suitesparse"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "cgal",
|
||||
"features": [
|
||||
"qt"
|
||||
]
|
||||
},
|
||||
"eigen3",
|
||||
"freeimage",
|
||||
"gflags",
|
||||
"glew",
|
||||
"glog",
|
||||
"qt5-base",
|
||||
"suitesparse",
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
},
|
||||
{
|
||||
"name": "vcpkg-cmake-config",
|
||||
"host": true
|
||||
}
|
||||
],
|
||||
"features": {
|
||||
"cuda": {
|
||||
"description": "CUDA support for current compute architecture of this machine.",
|
||||
"dependencies": [
|
||||
"cuda"
|
||||
]
|
||||
},
|
||||
"cuda-redist": {
|
||||
"description": "Redistributable CUDA support for common supported compute architectures.",
|
||||
"dependencies": [
|
||||
"cuda"
|
||||
]
|
||||
},
|
||||
"tests": {
|
||||
"description": "Build all tests."
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user