diff options
Diffstat (limited to 'vcpkg/ports/openmvg')
| -rw-r--r-- | vcpkg/ports/openmvg/0001-eigen_3.4.0.patch | 13 | ||||
| -rw-r--r-- | vcpkg/ports/openmvg/build_fixes.patch | 132 | ||||
| -rw-r--r-- | vcpkg/ports/openmvg/fast-c-language.diff | 25 | ||||
| -rw-r--r-- | vcpkg/ports/openmvg/no-absolute-paths.patch | 84 | ||||
| -rw-r--r-- | vcpkg/ports/openmvg/portfile.cmake | 177 | ||||
| -rw-r--r-- | vcpkg/ports/openmvg/vcpkg.json | 62 |
6 files changed, 493 insertions, 0 deletions
diff --git a/vcpkg/ports/openmvg/0001-eigen_3.4.0.patch b/vcpkg/ports/openmvg/0001-eigen_3.4.0.patch new file mode 100644 index 0000000..a4e759f --- /dev/null +++ b/vcpkg/ports/openmvg/0001-eigen_3.4.0.patch @@ -0,0 +1,13 @@ +diff --git a/src/openMVG/multiview/solver_fundamental_kernel.cpp b/src/openMVG/multiview/solver_fundamental_kernel.cpp +index 2ffd45a..bbf74b4 100644 +--- a/src/openMVG/multiview/solver_fundamental_kernel.cpp ++++ b/src/openMVG/multiview/solver_fundamental_kernel.cpp +@@ -110,7 +110,7 @@ void EightPointSolver::Solve + x2.colwise().homogeneous(), + &epipolar_constraint); + // Find the F matrice in the nullspace of epipolar_constraint. +- Eigen::SelfAdjointEigenSolver<Mat9> solver ++ Eigen::SelfAdjointEigenSolver<Eigen::Matrix<double, 9, 9>> solver + (epipolar_constraint.transpose() * epipolar_constraint); + f = solver.eigenvectors().leftCols<1>(); + diff --git a/vcpkg/ports/openmvg/build_fixes.patch b/vcpkg/ports/openmvg/build_fixes.patch new file mode 100644 index 0000000..1ec5ce6 --- /dev/null +++ b/vcpkg/ports/openmvg/build_fixes.patch @@ -0,0 +1,132 @@ +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 6879c4c..aa4167a 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -324,13 +324,18 @@ else() + if (TARGET flann::flann) + set(FLANN_LIBRARIES "flann::flann;flann::flann_cpp") + else() +- find_package(Flann QUIET) ++ set(FLANN_LIBRARIES "flann::flann_s;flann::flann_cpp_s") + endif() ++ set(FLANN_FOUND TRUE) + endif() + if (NOT FLANN_FOUND OR OpenMVG_USE_INTERNAL_FLANN) + set(FLANN_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/third_party/flann/src/cpp) + endif() + ++# Used together in openMVG/LinearProgramming ++find_package(PkgConfig REQUIRED) ++pkg_check_modules(OSI_CLP_COIN osi-clp clp osi coinutils REQUIRED) ++if(0) + # ============================================================================== + # CoinUtils + # ============================================================================== +@@ -391,6 +396,7 @@ if (OpenMVG_USE_INTERNAL_OSI AND OpenMVG_USE_INTERNAL_CLP AND OpenMVG_USE_INTERN + set_property(TARGET lib_Osi PROPERTY FOLDER OpenMVG/3rdParty/lib_Osi) + set_property(TARGET lib_OsiClpSolver PROPERTY FOLDER OpenMVG/3rdParty/lib_OsiClpSolver) + endif() ++endif() + + # ============================================================================== + # Lemon +@@ -402,7 +408,7 @@ if (NOT DEFINED LEMON_INCLUDE_DIR_HINTS) + set(LEMON_INCLUDE_DIR_HINTS ${CMAKE_CURRENT_SOURCE_DIR}/third_party/lemon) + set(OpenMVG_USE_INTERNAL_LEMON ON) + endif() +-find_package(Lemon QUIET) ++find_package(LEMON REQUIRED) + if (NOT LEMON_FOUND OR OpenMVG_USE_INTERNAL_LEMON) + set(LEMON_INCLUDE_DIRS + ${CMAKE_CURRENT_SOURCE_DIR}/third_party/lemon +diff --git a/src/cmakeFindModules/OpenMVGConfig.cmake.in b/src/cmakeFindModules/OpenMVGConfig.cmake.in +index 5a788b5..7a0afdb 100644 +--- a/src/cmakeFindModules/OpenMVGConfig.cmake.in ++++ b/src/cmakeFindModules/OpenMVGConfig.cmake.in +@@ -61,7 +61,7 @@ set(CMAKE_MODULE_PATH ${CURRENT_CONFIG_INSTALL_DIR}) + + # Build the absolute root install directory as a relative path + get_filename_component(CURRENT_ROOT_INSTALL_DIR +- ${CMAKE_MODULE_PATH}/../../../ ABSOLUTE) ++ "${CMAKE_CURRENT_LIST_DIR}/../.." ABSOLUTE) + if (NOT EXISTS ${CURRENT_ROOT_INSTALL_DIR}) + OPENMVG_REPORT_NOT_FOUND( + "OpenMVG install root: ${CURRENT_ROOT_INSTALL_DIR}, " +@@ -88,11 +88,14 @@ set(OpenMVG_USE_OPENMP "@OpenMVG_USE_OPENMP@") + + # Find transitive dependencies if required + include(CMakeFindDependencyMacro) ++find_dependency(flann CONFIG) ++find_dependency(Ceres CONFIG) ++find_dependency(vlfeat CONFIG) + if (OpenMVG_USE_OPENMP) +- find_dependency(OpenMP REQUIRED) ++ find_dependency(OpenMP) + endif() + if (NOT OpenMVG_USE_INTERNAL_CEREAL) +- find_dependency(cereal REQUIRED) ++ find_dependency(cereal CONFIG) + endif() + + # Import exported OpenMVG targets +diff --git a/src/nonFree/sift/CMakeLists.txt b/src/nonFree/sift/CMakeLists.txt +index 402a2d8..b2912ea 100644 +--- a/src/nonFree/sift/CMakeLists.txt ++++ b/src/nonFree/sift/CMakeLists.txt +@@ -25,7 +25,9 @@ set(FEATS + vl/mathop.c + vl/random.c) + set_source_files_properties(${FEATS} PROPERTIES LANGUAGE C) +-add_library(vlsift ${FEATS}) ++find_package(vlfeat CONFIG REQUIRED) ++add_library(vlsift INTERFACE) ++target_link_libraries(vlsift INTERFACE unofficial::vlfeat::vl) + install(TARGETS vlsift DESTINATION lib EXPORT openMVG-targets) + set_property(TARGET vlsift PROPERTY FOLDER OpenMVG/nonFree) + install( +diff --git a/src/nonFree/sift/SIFT_describer.hpp b/src/nonFree/sift/SIFT_describer.hpp +index cd800b0..9586d9b 100644 +--- a/src/nonFree/sift/SIFT_describer.hpp ++++ b/src/nonFree/sift/SIFT_describer.hpp +@@ -18,7 +18,7 @@ + #include <numeric> + + extern "C" { +-#include "nonFree/sift/vl/sift.h" ++#include <vl/sift.h> + } + + namespace openMVG { +diff --git a/src/openMVG/exif/sensor_width_database/CMakeLists.txt b/src/openMVG/exif/sensor_width_database/CMakeLists.txt +index 33d9f16..58b4761 100644 +--- a/src/openMVG/exif/sensor_width_database/CMakeLists.txt ++++ b/src/openMVG/exif/sensor_width_database/CMakeLists.txt +@@ -2,4 +2,4 @@ + UNIT_TEST(openMVG ParseDatabase "openMVG_testing;${STLPLUS_LIBRARY}") + + # Installation rules +-install(FILES sensor_width_camera_database.txt DESTINATION ${CMAKE_INSTALL_LIBDIR}/openMVG) ++install(FILES sensor_width_camera_database.txt DESTINATION share/openmvg) +diff --git a/src/openMVG/linearProgramming/CMakeLists.txt b/src/openMVG/linearProgramming/CMakeLists.txt +index 3a8a402..24151e9 100644 +--- a/src/openMVG/linearProgramming/CMakeLists.txt ++++ b/src/openMVG/linearProgramming/CMakeLists.txt +@@ -15,16 +15,12 @@ target_link_libraries(openMVG_linearProgramming + PUBLIC + openMVG_numeric + PRIVATE +- ${CLP_LIBRARIES} # clp + solver wrapper +- ${COINUTILS_LIBRARY} # container tools +- ${OSI_LIBRARY} # generic LP ++ ${OSI_CLP_COIN_LINK_LIBRARIES} + ) + + target_include_directories(openMVG_linearProgramming + PRIVATE +- ${CLP_INCLUDE_DIRS} +- ${COINUTILS_INCLUDE_DIRS} +- ${OSI_INCLUDE_DIRS} ++ ${OSI_CLP_COIN_INCLUDE_DIRS} + PUBLIC + $<INSTALL_INTERFACE:include> + ) diff --git a/vcpkg/ports/openmvg/fast-c-language.diff b/vcpkg/ports/openmvg/fast-c-language.diff new file mode 100644 index 0000000..1193e3b --- /dev/null +++ b/vcpkg/ports/openmvg/fast-c-language.diff @@ -0,0 +1,25 @@ +diff --git a/src/openMVG/features/fast/fast_detector.cpp b/src/openMVG/features/fast/fast_detector.cpp +index 7223149..0daa5db 100644 +--- a/src/openMVG/features/fast/fast_detector.cpp ++++ b/src/openMVG/features/fast/fast_detector.cpp +@@ -9,7 +9,9 @@ + #include "openMVG/features/fast/fast_detector.hpp" + + #include "openMVG/image/image_container.hpp" ++extern "C" { + #include "third_party/fast/fast.h" ++} + + #include <iostream> + // +diff --git a/src/third_party/fast/CMakeLists.txt b/src/third_party/fast/CMakeLists.txt +index dc0aba6..7361dc0 100644 +--- a/src/third_party/fast/CMakeLists.txt ++++ b/src/third_party/fast/CMakeLists.txt +@@ -1,6 +1,5 @@ + + file(GLOB_RECURSE C_FILES ${CMAKE_CURRENT_SOURCE_DIR} *.c) +-set_source_files_properties(${C_FILES} PROPERTIES LANGUAGE CXX) + add_library(openMVG_fast STATIC ${C_FILES}) + set_property(TARGET openMVG_fast PROPERTY FOLDER OpenMVG/3rdParty) + diff --git a/vcpkg/ports/openmvg/no-absolute-paths.patch b/vcpkg/ports/openmvg/no-absolute-paths.patch new file mode 100644 index 0000000..50c87cb --- /dev/null +++ b/vcpkg/ports/openmvg/no-absolute-paths.patch @@ -0,0 +1,84 @@ +diff --git a/src/software/SfM/SfM_GlobalPipeline.py.in b/src/software/SfM/SfM_GlobalPipeline.py.in +index 42b41cc..b1dc361 100644 +--- a/src/software/SfM/SfM_GlobalPipeline.py.in ++++ b/src/software/SfM/SfM_GlobalPipeline.py.in +@@ -17,13 +17,13 @@ + # if output_dir is not present script will create it + # + ++import os + # Indicate the openMVG binary directory +-OPENMVG_SFM_BIN = "@OPENMVG_SOFTWARE_SFM_BUILD_DIR@" ++OPENMVG_SFM_BIN = os.path.dirname(__file__) + + # Indicate the openMVG camera sensor width directory +-CAMERA_SENSOR_WIDTH_DIRECTORY = "@OPENMVG_SOFTWARE_SFM_SRC_DIR@" + "/../../openMVG/exif/sensor_width_database" ++CAMERA_SENSOR_WIDTH_DIRECTORY = OPENMVG_SFM_BIN + +-import os + import subprocess + import sys + +diff --git a/src/software/SfM/SfM_SequentialPipeline.py.in b/src/software/SfM/SfM_SequentialPipeline.py.in +index 423c85c..5335680 100644 +--- a/src/software/SfM/SfM_SequentialPipeline.py.in ++++ b/src/software/SfM/SfM_SequentialPipeline.py.in +@@ -17,13 +17,13 @@ + # if output_dir is not present script will create it + # + ++import os + # Indicate the openMVG binary directory +-OPENMVG_SFM_BIN = "@OPENMVG_SOFTWARE_SFM_BUILD_DIR@" ++OPENMVG_SFM_BIN = os.path.dirname(__file__) + + # Indicate the openMVG camera sensor width directory +-CAMERA_SENSOR_WIDTH_DIRECTORY = "@OPENMVG_SOFTWARE_SFM_SRC_DIR@" + "/../../openMVG/exif/sensor_width_database" ++CAMERA_SENSOR_WIDTH_DIRECTORY = OPENMVG_SFM_BIN + +-import os + import subprocess + import sys + +diff --git a/src/software/SfM/import/SfM_StructurePipeline.py.in b/src/software/SfM/import/SfM_StructurePipeline.py.in +index 3489eca..6d8b3d2 100644 +--- a/src/software/SfM/import/SfM_StructurePipeline.py.in ++++ b/src/software/SfM/import/SfM_StructurePipeline.py.in +@@ -18,13 +18,13 @@ + # if output_dir is not present script will create it + # + ++import os + # Indicate the openMVG binary directory +-OPENMVG_SFM_BIN = "@OPENMVG_SOFTWARE_SFM_BUILD_DIR@" ++OPENMVG_SFM_BIN = os.path.dirname(__file__) + + # Indicate the openMVG camera sensor width directory +-CAMERA_SENSOR_WIDTH_DIRECTORY = "@OPENMVG_SOFTWARE_SFM_SRC_DIR@" + "/../../openMVG/exif/sensor_width_database" ++CAMERA_SENSOR_WIDTH_DIRECTORY = OPENMVG_SFM_BIN + +-import os + import subprocess + import sys + +diff --git a/src/software/SfM/tutorial_demo.py.in b/src/software/SfM/tutorial_demo.py.in +index c7361f3..82f3378 100644 +--- a/src/software/SfM/tutorial_demo.py.in ++++ b/src/software/SfM/tutorial_demo.py.in +@@ -8,13 +8,13 @@ + # usage : python tutorial_demo.py + # + ++import os + # Indicate the openMVG binary directory +-OPENMVG_SFM_BIN = "@OPENMVG_SOFTWARE_SFM_BUILD_DIR@" ++OPENMVG_SFM_BIN = os.path.dirname(__file__) + + # Indicate the openMVG camera sensor width directory +-CAMERA_SENSOR_WIDTH_DIRECTORY = "@OPENMVG_SOFTWARE_SFM_SRC_DIR@" + "/../../openMVG/exif/sensor_width_database" ++CAMERA_SENSOR_WIDTH_DIRECTORY = OPENMVG_SFM_BIN + +-import os + import subprocess + import sys + diff --git a/vcpkg/ports/openmvg/portfile.cmake b/vcpkg/ports/openmvg/portfile.cmake new file mode 100644 index 0000000..f445a73 --- /dev/null +++ b/vcpkg/ports/openmvg/portfile.cmake @@ -0,0 +1,177 @@ +vcpkg_buildpath_length_warning(37) + +#the port produces some empty dlls when building shared libraries, since some components do not export anything, breaking the internal build itself +if(VCPKG_TARGET_IS_WINDOWS) + vcpkg_check_linkage(ONLY_STATIC_LIBRARY) +endif() + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO openMVG/openMVG + REF 01193a245ee3c36458e650b1cf4402caad8983ef # v2.1 + SHA512 ee98ca26426e7129917c920cd59817cb5d4faf1f5aa12f4085f9ac431875e9ec23ffee7792d65286bad4b922c474c56d5c2f2008b38fddf1ede096644f13ad47 + PATCHES + build_fixes.patch + 0001-eigen_3.4.0.patch + fast-c-language.diff + no-absolute-paths.patch +) +file(REMOVE_RECURSE + "${SOURCE_PATH}/src/cmakeFindModules/FindEigen.cmake" + "${SOURCE_PATH}/src/cmakeFindModules/FindFlann.cmake" + "${SOURCE_PATH}/src/cmakeFindModules/FindLemon.cmake" + "${SOURCE_PATH}/src/cmakeFindModules/FindClp.cmake" + "${SOURCE_PATH}/src/cmakeFindModules/FindCoinUtils.cmake" + "${SOURCE_PATH}/src/cmakeFindModules/FindOsi.cmake" + "${SOURCE_PATH}/src/nonFree/sift/vl" + "${SOURCE_PATH}/src/third_party/CppUnitLite" + "${SOURCE_PATH}/src/third_party/ceres-solver" + "${SOURCE_PATH}/src/third_party/cxsparse" + "${SOURCE_PATH}/src/third_party/eigen" + "${SOURCE_PATH}/src/third_party/flann" + "${SOURCE_PATH}/src/third_party/jpeg" + "${SOURCE_PATH}/src/third_party/lemon" + "${SOURCE_PATH}/src/third_party/png" + "${SOURCE_PATH}/src/third_party/tiff" + "${SOURCE_PATH}/src/third_party/zlib" +) +file(MAKE_DIRECTORY "${SOURCE_PATH}/src/dependencies/cereal/include/_placeholder") + +vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS + FEATURES + opencv OpenMVG_USE_OPENCV + opencv OpenMVG_USE_OCVSIFT + opencv VCPKG_LOCK_FIND_PACKAGE_OpenCV + openmp OpenMVG_USE_OPENMP + software OpenMVG_BUILD_SOFTWARES + software OpenMVG_BUILD_GUI_SOFTWARES +) + +string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "dynamic" OpenMVG_BUILD_SHARED) + +vcpkg_find_acquire_program(PKGCONFIG) +set(ENV{PKG_CONFIG} "${PKGCONFIG}") + +vcpkg_cmake_configure( + SOURCE_PATH "${SOURCE_PATH}/src" + OPTIONS + ${FEATURE_OPTIONS} + -DOpenMVG_BUILD_SHARED=${OpenMVG_BUILD_SHARED} + -DOpenMVG_BUILD_COVERAGE=OFF + -DOpenMVG_BUILD_DOC=OFF + -DOpenMVG_BUILD_EXAMPLES=OFF + -DOpenMVG_BUILD_OPENGL_EXAMPLES=OFF + -DOpenMVG_BUILD_TESTS=OFF + -DOpenMVG_USE_LIGT=OFF + "-DFLANN_INCLUDE_DIR_HINTS=${CURRENT_INSTALLED_DIR}/include" + "-DLEMON_INCLUDE_DIR_HINTS=${CURRENT_INSTALLED_DIR}/include" + -DVCPKG_LOCK_FIND_PACKAGE_cereal=ON + -DVCPKG_LOCK_FIND_PACKAGE_Ceres=ON + -DVCPKG_LOCK_FIND_PACKAGE_Eigen3=ON + -DVCPKG_LOCK_FIND_PACKAGE_Flann=ON + -DVCPKG_LOCK_FIND_PACKAGE_JPEG=ON + -DVCPKG_LOCK_FIND_PACKAGE_PNG=ON + -DVCPKG_LOCK_FIND_PACKAGE_TIFF=ON + OPTIONS_DEBUG + -DOpenMVG_USE_OPENCV=OFF + -DOpenMVG_BUILD_SOFTWARES=OFF + -DOpenMVG_BUILD_GUI_SOFTWARES=OFF + MAYBE_UNUSED_VARIABLES + FLANN_INCLUDE_DIR_HINTS # Must be "defined" + LEMON_INCLUDE_DIR_HINTS # Must be "defined" + VCPKG_LOCK_FIND_PACKAGE_OpenCV +) +vcpkg_cmake_install() +vcpkg_copy_pdbs() +vcpkg_cmake_config_fixup(CONFIG_PATH "lib/openMVG") + +file(REMOVE_RECURSE + "${CURRENT_PACKAGES_DIR}/debug/include" + "${CURRENT_PACKAGES_DIR}/debug/share" + "${CURRENT_PACKAGES_DIR}/include/openMVG_dependencies/cereal" + "${CURRENT_PACKAGES_DIR}/include/openMVG_dependencies/glfw" + "${CURRENT_PACKAGES_DIR}/include/openMVG_dependencies/osi_clp" + "${CURRENT_PACKAGES_DIR}/include/openMVG/image/image_test" + "${CURRENT_PACKAGES_DIR}/include/openMVG/exif/image_data" +) + +if("software" IN_LIST FEATURES) + if(VCPKG_TARGET_IS_OSX) + vcpkg_copy_tools(TOOL_NAMES + openMVG_main_AlternativeVO.app + ui_openMVG_MatchesViewer.app + ) + file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin/openMVG_main_AlternativeVO.app") + file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin/ui_openMVG_MatchesViewer.app") + file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/bin/openMVG_main_AlternativeVO.app") + file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/bin/ui_openMVG_MatchesViewer.app") + else() + vcpkg_copy_tools(AUTO_CLEAN TOOL_NAMES + openMVG_main_AlternativeVO + ui_openMVG_MatchesViewer + ) + endif() + vcpkg_copy_tools(AUTO_CLEAN TOOL_NAMES + openMVG_main_ChangeLocalOrigin + openMVG_main_ColHarmonize + openMVG_main_ComputeClusters + openMVG_main_ComputeFeatures + openMVG_main_ComputeMatches + openMVG_main_ComputeSfM_DataColor + openMVG_main_ComputeStructureFromKnownPoses + openMVG_main_ComputeVLAD + openMVG_main_ConvertList + openMVG_main_ConvertSfM_DataFormat + openMVG_main_evalQuality + openMVG_main_ExportCameraFrustums + openMVG_main_exportKeypoints + openMVG_main_exportMatches + openMVG_main_exportTracks + openMVG_main_ExportUndistortedImages + openMVG_main_FrustumFiltering + openMVG_main_geodesy_registration_to_gps_position + openMVG_main_ListMatchingPairs + openMVG_main_MatchesToTracks + openMVG_main_openMVG2Agisoft + openMVG_main_openMVG2CMPMVS + openMVG_main_openMVG2Colmap + openMVG_main_openMVG2MESHLAB + openMVG_main_openMVG2MVE2 + openMVG_main_openMVG2MVSTEXTURING + openMVG_main_openMVG2NVM + openMVG_main_openMVG2openMVS + openMVG_main_openMVG2PMVS + openMVG_main_openMVG2WebGL + openMVG_main_openMVGSpherical2Cubic + openMVG_main_PointsFiltering + openMVG_main_SfMInit_ImageListing + openMVG_main_SfMInit_ImageListingFromKnownPoses + openMVG_main_SfM_Localization + openMVG_main_SplitMatchFileIntoMatchFiles + ui_openMVG_control_points_registration + openMVG_main_GeometricFilter + openMVG_main_PairGenerator + openMVG_main_SfM + ) + if("opencv" IN_LIST FEATURES) + vcpkg_copy_tools(AUTO_CLEAN TOOL_NAMES + openMVG_main_ComputeFeatures_OpenCV) + endif() + + file(COPY "${CURRENT_PACKAGES_DIR}/share/${PORT}/sensor_width_camera_database.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}") + file(COPY_FILE "${SOURCE_PATH}/src/software/SfM/tutorial_demo.py.in" "${CURRENT_PACKAGES_DIR}/tools/${PORT}/tutorial_demo.py") + file(COPY_FILE "${SOURCE_PATH}/src/software/SfM/SfM_GlobalPipeline.py.in" "${CURRENT_PACKAGES_DIR}/tools/${PORT}/SfM_GlobalPipeline.py") + file(COPY_FILE "${SOURCE_PATH}/src/software/SfM/SfM_SequentialPipeline.py.in" "${CURRENT_PACKAGES_DIR}/tools/${PORT}/SfM_SequentialPipeline.py") + file(COPY_FILE "${SOURCE_PATH}/src/software/SfM/import/SfM_StructurePipeline.py.in" "${CURRENT_PACKAGES_DIR}/tools/${PORT}/SfM_StructurePipeline.py") +endif() + +set(third_party_notices "") +file(GLOB files "${SOURCE_PATH}/src/third_party/*/README.openMVG") +foreach(file IN LISTS files) + cmake_path(GET file PARENT_PATH parent_path) + cmake_path(GET parent_path FILENAME component) + set(extra_file "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/${component}") + file(COPY_FILE "${file}" "${extra_file}") + list(APPEND third_party_notices "${extra_file}") +endforeach() +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE" ${third_party_notices}) diff --git a/vcpkg/ports/openmvg/vcpkg.json b/vcpkg/ports/openmvg/vcpkg.json new file mode 100644 index 0000000..d93c643 --- /dev/null +++ b/vcpkg/ports/openmvg/vcpkg.json @@ -0,0 +1,62 @@ +{ + "name": "openmvg", + "version": "2.1", + "port-version": 2, + "description": "open Multiple View Geometry library. Basis for 3D computer vision and Structure from Motion.", + "license": null, + "supports": "(x86 | x64 | arm64) & !xbox", + "dependencies": [ + "cereal", + { + "name": "ceres", + "features": [ + "suitesparse" + ] + }, + "coin-or-clp", + "coin-or-osi", + "coinutils", + "eigen3", + "flann", + "libjpeg-turbo", + "liblemon", + "libpng", + { + "name": "tiff", + "default-features": false + }, + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + }, + "vlfeat", + "zlib" + ], + "features": { + "opencv": { + "description": "Build opencv+openMVG samples programs", + "dependencies": [ + { + "name": "opencv", + "features": [ + "contrib" + ] + } + ] + }, + "openmp": { + "description": "OpenMP support" + }, + "software": { + "description": "Build openMVG tools", + "dependencies": [ + "qt5-base", + "qt5-svg" + ] + } + } +} |