2016-12-08 04:25:54 +01:00
|
|
|
PORTNAME= colmap
|
2023-02-08 17:51:17 +01:00
|
|
|
DISTVERSION= 3.8
|
2023-10-03 22:04:27 +02:00
|
|
|
PORTREVISION= 4
|
2016-12-08 04:25:54 +01:00
|
|
|
CATEGORIES= graphics
|
|
|
|
|
2023-02-08 12:31:15 +01:00
|
|
|
MAINTAINER= fuz@FreeBSD.org
|
2016-12-08 04:25:54 +01:00
|
|
|
COMMENT= Structure from motion and multi-view stereo
|
2022-09-07 23:06:12 +02:00
|
|
|
WWW= https://colmap.github.io/
|
2016-12-08 04:25:54 +01:00
|
|
|
|
|
|
|
LICENSE= BSD2CLAUSE BSD3CLAUSE CC-BY-3.0 GPLv3+ MIT SIFTGPU
|
|
|
|
LICENSE_COMB= multi
|
|
|
|
LICENSE_NAME_SIFTGPU= SiftGPU non-commercial license
|
2022-11-11 21:40:16 +01:00
|
|
|
LICENSE_FILE_BSD2CLAUSE= ${WRKSRC}/lib/VLFeat/LICENSE
|
|
|
|
LICENSE_FILE_BSD3CLAUSE= ${WRKSRC}/COPYING.txt # also FLANN
|
2016-12-08 04:25:54 +01:00
|
|
|
LICENSE_FILE_CC-BY-3.0= ${WRKSRC}/src/ui/media/LICENSE
|
2018-08-27 13:05:13 +02:00
|
|
|
LICENSE_FILE_GPLv3+ = ${WRKSRC}/lib/PBA/LICENSE # also Graclus, LSD
|
|
|
|
LICENSE_FILE_MIT= ${WRKSRC}/lib/PoissonRecon/LICENSE
|
|
|
|
LICENSE_FILE_SIFTGPU= ${WRKSRC}/lib/SiftGPU/LICENSE
|
2016-12-08 04:25:54 +01:00
|
|
|
LICENSE_PERMS_SIFTGPU= dist-mirror pkg-mirror auto-accept
|
|
|
|
|
|
|
|
LIB_DEPENDS= libboost_filesystem.so:devel/boost-libs \
|
2022-11-11 21:40:16 +01:00
|
|
|
libceres.so:math/ceres-solver \
|
2023-02-08 17:51:17 +01:00
|
|
|
libflann.so:math/flann \
|
2016-12-08 04:25:54 +01:00
|
|
|
libfreeimage.so:graphics/freeimage \
|
2023-02-08 17:51:17 +01:00
|
|
|
libglog.so:devel/glog \
|
|
|
|
liblz4.so:archivers/liblz4 \
|
|
|
|
libmetis.so:math/metis
|
2016-12-08 04:25:54 +01:00
|
|
|
|
2022-11-11 21:40:16 +01:00
|
|
|
USES= cmake compiler:${OPENMP}c++11-lib desktop-file-utils eigen:3 gl \
|
|
|
|
localbase python:env qt:5 sqlite
|
2023-10-03 22:04:27 +02:00
|
|
|
USE_CXXSTD= c++17
|
2016-12-08 04:25:54 +01:00
|
|
|
USE_GITHUB= yes
|
2017-09-05 03:05:19 +02:00
|
|
|
USE_GL= gl glew
|
2022-11-11 21:40:16 +01:00
|
|
|
USE_QT= core gui widgets buildtools:build opengl:build qmake:build
|
2016-12-08 04:25:54 +01:00
|
|
|
EXCLUDE= SQLite
|
2018-01-01 14:42:54 +01:00
|
|
|
CMAKE_OFF= BOOST_STATIC CUDA_ENABLED
|
2019-09-27 19:25:50 +02:00
|
|
|
TEST_TARGET= test
|
2016-12-08 04:25:54 +01:00
|
|
|
|
2022-11-11 21:40:16 +01:00
|
|
|
LDFLAGS+= -Wl,--as-needed # gflags, glu, xi, xmu
|
|
|
|
|
|
|
|
EXTRACT_AFTER_ARGS= ${EXCLUDE:S,^,--exclude lib/,}
|
|
|
|
|
2018-08-27 13:05:13 +02:00
|
|
|
OPTIONS_DEFINE= CGAL DOCS OPENMP SIMD TEST
|
|
|
|
OPTIONS_DEFAULT= CGAL OPENMP SIMD
|
|
|
|
|
|
|
|
CGAL_DESC= Graph-cut on Delaunay triangulation based meshing algorithm
|
2020-05-08 07:35:11 +02:00
|
|
|
CGAL_BUILD_DEPENDS= cgal>0:math/cgal
|
2022-11-11 21:40:16 +01:00
|
|
|
CGAL_LIB_DEPENDS= libgmp.so:math/gmp
|
2018-08-27 13:05:13 +02:00
|
|
|
CGAL_CMAKE_BOOL= CGAL_ENABLED
|
2016-12-08 04:25:54 +01:00
|
|
|
|
2022-11-11 21:40:16 +01:00
|
|
|
DOCS_BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}sphinx_rtd_theme>0:textproc/py-sphinx_rtd_theme@${PY_FLAVOR} \
|
|
|
|
gmake:devel/gmake \
|
|
|
|
sphinx-build:textproc/py-sphinx
|
2016-12-08 04:25:54 +01:00
|
|
|
DOCS_PORTDOCS= *
|
|
|
|
|
|
|
|
OPENMP_CMAKE_BOOL= OPENMP_ENABLED
|
2021-01-31 02:17:38 +01:00
|
|
|
.if !exists(/usr/include/omp.h)
|
2021-01-31 02:17:52 +01:00
|
|
|
# XXX ports/199603: LLVM openmp in base doesn't support armv6, armv7 yet
|
2016-12-17 18:32:35 +01:00
|
|
|
OPENMP_VARS= OPENMP=gcc-
|
2019-04-22 19:38:04 +02:00
|
|
|
.endif
|
2016-12-08 04:25:54 +01:00
|
|
|
|
2016-12-19 07:37:20 +01:00
|
|
|
SIMD_CMAKE_BOOL= SIMD_ENABLED
|
2016-12-08 04:25:54 +01:00
|
|
|
|
2017-05-24 06:26:26 +02:00
|
|
|
TEST_CMAKE_BOOL= TESTS_ENABLED
|
|
|
|
|
2016-12-08 04:25:54 +01:00
|
|
|
post-patch:
|
2018-08-27 13:05:13 +02:00
|
|
|
# XXX math/flann has -DUSE_OPENMP=OFF and lacks tunning:
|
|
|
|
# https://github.com/colmap/colmap/commit/4b594eb85c13
|
|
|
|
# https://github.com/colmap/colmap/commit/1e9f1f3324cd
|
2016-12-08 04:25:54 +01:00
|
|
|
.if !defined(DISPLAY) # QApplication
|
|
|
|
@${REINPLACE_CMD} -e '/opengl_utils_test/d' \
|
|
|
|
${WRKSRC}/src/util/CMakeLists.txt
|
|
|
|
.endif
|
|
|
|
|
|
|
|
post-build-DOCS-on:
|
2019-04-22 19:37:39 +02:00
|
|
|
@${SETENV} ${MAKE_ENV} ${GMAKE} ${_MAKE_JOBS} html -C${WRKSRC}/doc
|
2016-12-08 04:25:54 +01:00
|
|
|
|
2017-05-24 06:26:26 +02:00
|
|
|
pre-install-TEST-on: do-test
|
2016-12-08 04:25:54 +01:00
|
|
|
|
2018-08-27 13:05:13 +02:00
|
|
|
post-install:
|
|
|
|
# XXX Clean up garbage after install(DIRECTORY)
|
|
|
|
@${FIND} ${STAGEDIR}${PREFIX}/include -type d -empty -delete
|
|
|
|
|
2016-12-08 04:25:54 +01:00
|
|
|
post-install-DOCS-on:
|
|
|
|
(cd ${WRKSRC}/doc/_build/html && ${COPYTREE_SHARE} \
|
|
|
|
"${PORTDOCS}" ${STAGEDIR}${DOCSDIR})
|
|
|
|
|
|
|
|
.include <bsd.port.mk>
|