diff --git a/ports/cctag/portfile.cmake b/ports/cctag/portfile.cmake new file mode 100644 index 00000000000000..36cf48c04c4950 --- /dev/null +++ b/ports/cctag/portfile.cmake @@ -0,0 +1,49 @@ +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO alicevision/cctag + REF v1.0.0 + SHA512 49028356215dd703727b2eedd6aa72d81af84e5ca36f8dc7e9caf85a85c7f500b3eeaaa7369314a40049a72593d70049b709b453c30ff352d98ab0dea3afef76 + HEAD_REF develop +) + +vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS + FEATURES + cuda CCTAG_WITH_CUDA + apps CCTAG_BUILD_APPS +) + +if("cuda" IN_LIST FEATURES) + include(${CURRENT_INSTALLED_DIR}/share/vcpkg_find_cuda/vcpkg_find_cuda.cmake) + vcpkg_find_cuda(OUT_CUDA_TOOLKIT_ROOT CUDA_TOOLKIT_ROOT) + + message(STATUS "CUDA_TOOLKIT_ROOT ${CUDA_TOOLKIT_ROOT}") +endif() + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS -DCCTAG_BUILD_TESTS:BOOL=OFF ${FEATURE_OPTIONS} +) + +vcpkg_install_cmake() + +vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/CCTag) + +vcpkg_copy_pdbs() + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include ${CURRENT_PACKAGES_DIR}/debug/share) + +# remove test files +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/include/cctag/geometry/test" "${CURRENT_PACKAGES_DIR}/include/cctag/test") +# remove cuda headers +if(NOT "cuda" IN_LIST FEATURES) + file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/include/cctag/cuda") +endif() + + # move the bin directory to tools +if ("apps" IN_LIST FEATURES) + set(CCTAG_TOOLS detection regression simulation) + vcpkg_copy_tools(TOOL_NAMES ${CCTAG_TOOLS} AUTO_CLEAN) +endif() + +file(INSTALL ${SOURCE_PATH}/COPYING.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/cctag RENAME copyright) \ No newline at end of file diff --git a/ports/cctag/vcpkg.json b/ports/cctag/vcpkg.json new file mode 100644 index 00000000000000..b90383fc79d1ed --- /dev/null +++ b/ports/cctag/vcpkg.json @@ -0,0 +1,52 @@ +{ + "name": "cctag", + "version-semver": "1.0.0", + "maintainers": "alicevision-team@googlegroups.com", + "description": "Computer vision library for detecting CCTag markers made up of concentric circles", + "homepage": "https://github.com/alicevision/CCTag", + "documentation": "https://cctag.readthedocs.io/", + "supports": "!(uwp | arm | arm64 | android | x86)", + "dependencies": [ + "boost-accumulators", + "boost-algorithm", + "boost-container", + "boost-date-time", + "boost-exception", + "boost-filesystem", + "boost-iterator", + "boost-lexical-cast", + "boost-math", + "boost-mpl", + "boost-multi-array", + "boost-program-options", + "boost-ptr-container", + "boost-serialization", + "boost-spirit", + "boost-stacktrace", + "boost-static-assert", + "boost-test", + "boost-thread", + "boost-throw-exception", + "boost-timer", + "boost-type-traits", + "boost-unordered", + "eigen3", + "opencv3", + "tbb" + ], + "features": { + "apps": { + "description": "Sample applications for detecting CCTag markers in images and videos", + "dependencies": [ + "boost-program-options", + "boost-system" + ] + }, + "cuda": { + "description": "Enable Cuda support for faster detection", + "dependencies": [ + "cuda" + ] + } + } +} diff --git a/scripts/ci.baseline.txt b/scripts/ci.baseline.txt index a9ab3808409b2b..afc196ff32c586 100644 --- a/scripts/ci.baseline.txt +++ b/scripts/ci.baseline.txt @@ -91,6 +91,7 @@ catch-classic:x64-windows-static-md=skip catch-classic:x86-windows = skip ccd:arm-uwp=fail ccd:x64-uwp=fail +cctag:x64-windows-static-md=fail cello:arm-uwp=fail cello:x64-uwp=fail cfitsio:arm-uwp=fail diff --git a/versions/baseline.json b/versions/baseline.json index 9038ec334e41a9..e72e45b614f38e 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -1116,6 +1116,10 @@ "baseline": "2.5", "port-version": 6 }, + "cctag": { + "baseline": "1.0.0", + "port-version": 0 + }, "cctz": { "baseline": "2.3-2", "port-version": 0 diff --git a/versions/c-/cctag.json b/versions/c-/cctag.json new file mode 100644 index 00000000000000..fafc644be20c20 --- /dev/null +++ b/versions/c-/cctag.json @@ -0,0 +1,9 @@ +{ + "versions": [ + { + "git-tree": "8abc2227c7e5fc5232f928d407d5dac772afb48b", + "version-semver": "1.0.0", + "port-version": 0 + } + ] +}