diff --git a/graphics/openmvs/Makefile b/graphics/openmvs/Makefile index 3301245bf008..507e01a8cbde 100644 --- a/graphics/openmvs/Makefile +++ b/graphics/openmvs/Makefile @@ -1,48 +1,46 @@ PORTNAME= openmvs DISTVERSIONPREFIX= v -DISTVERSION= 2.2.0 -PORTREVISION= 9 +DISTVERSION= 2.3.0 CATEGORIES= graphics MAINTAINER= yuri@FreeBSD.org COMMENT= Open Multi-View Stereo reconstruction library WWW= https://github.com/cdcseacave/openMVS LICENSE= AGPLv3 LICENSE_FILE= ${WRKSRC}/LICENSE -BROKEN= compilation is broken because of the use of discontinued C++ features, see https://github.com/cdcseacave/openMVS/issues/1075 -BROKEN_aarch64= use of undeclared identifier '__builtin_ia32_emms' # https://github.com/cdcseacave/openMVS/issues/847 - -BUILD_DEPENDS= cgal>0:math/cgal \ - ${LOCALBASE}/include/sys/sysinfo.h:devel/libsysinfo \ - vcglib>0:devel/vcglib LIB_DEPENDS= libboost_thread.so:devel/boost-libs \ libceres.so:math/ceres-solver \ libgflags.so:devel/gflags \ libglog.so:devel/glog \ libgmp.so:math/gmp \ libmpfr.so:math/mpfr \ libopencv_core.so:graphics/opencv \ libpng16.so:graphics/png \ - libtiff.so:graphics/tiff + libtiff.so:graphics/tiff \ + ${PY_BOOST} \ + libpython${PYTHON_VER}${PYTHON_ABIVER}.so:lang/python${PYTHON_SUFFIX} +BUILD_DEPENDS= cgal>0:math/cgal \ + ${LOCALBASE}/include/sys/sysinfo.h:devel/libsysinfo \ + vcglib>0:devel/vcglib -USES= cmake:testing compiler:c++17-lang eigen:3 jpeg +USES= cmake:testing compiler:c++14-lang eigen:3 jpeg python USE_GITHUB= yes GH_ACCOUNT= cdcseacave GH_PROJECT= openMVS CMAKE_ON= BUILD_SHARED_LIBS OpenMVS_USE_CERES CMAKE_OFF= OpenMVS_BUILD_TOOLS # tools can't be built because of https://github.com/cdcseacave/openMVS/issues/846 CMAKE_OFF+= OpenMVS_ENABLE_TESTS CMAKE_ARGS= -DVCG_ROOT=${LOCALBASE}/include/vcglib CMAKE_TESTING_ON= OpenMVS_ENABLE_TESTS # tests fail to configure, see https://github.com/cdcseacave/openMVS/issues/911 .include .if ${ARCH} != amd64 && ${ARCH} != i386 CMAKE_ARGS+= -DOpenMVS_USE_SSE:BOOL=OFF .endif .include diff --git a/graphics/openmvs/distinfo b/graphics/openmvs/distinfo index e2dae598de94..3c81c967d383 100644 --- a/graphics/openmvs/distinfo +++ b/graphics/openmvs/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1688531169 -SHA256 (cdcseacave-openMVS-v2.2.0_GH0.tar.gz) = 849e6b9d0ab187e0ecb71c55827080fe63e24af42274de6c35c0c9b922ac6323 -SIZE (cdcseacave-openMVS-v2.2.0_GH0.tar.gz) = 2162877 +TIMESTAMP = 1764968217 +SHA256 (cdcseacave-openMVS-v2.3.0_GH0.tar.gz) = ac7312fb71dbab18c5b2755ad9ac3caa40ec689f6f369c330ca73c87c1f34258 +SIZE (cdcseacave-openMVS-v2.3.0_GH0.tar.gz) = 2169982 diff --git a/graphics/openmvs/files/patch-build_Utils.cmake b/graphics/openmvs/files/patch-build_Utils.cmake index 436115176d97..35547d765433 100644 --- a/graphics/openmvs/files/patch-build_Utils.cmake +++ b/graphics/openmvs/files/patch-build_Utils.cmake @@ -1,10 +1,18 @@ ---- build/Utils.cmake.orig 2022-04-17 08:46:34 UTC +--- build/Utils.cmake.orig 2024-05-27 00:00:00 UTC +++ build/Utils.cmake -@@ -433,6 +433,7 @@ macro(optimize_default_compiler_settings) - endif() +@@ -442,6 +442,7 @@ endif() endif() -+ set(CMAKE_CXX_STANDARD 14) - if(CLANG AND (CMAKE_CXX_STANDARD EQUAL 11 OR CMAKE_CXX_STANDARD EQUAL 14 OR CMAKE_CXX_STANDARD EQUAL 17)) + if(CLANG AND (CMAKE_CXX_STANDARD EQUAL 11 OR CMAKE_CXX_STANDARD EQUAL 14 OR CMAKE_CXX_STANDARD EQUAL 17 OR CMAKE_CXX_STANDARD EQUAL 20)) ++ set(CMAKE_CXX_STANDARD 14 CACHE STRING "C++ standard" FORCE) set(CMAKE_EXE_LINKER_FLAGS "-stdlib=libc++") add_extra_compiler_option(-stdlib=libc++) + endif() +@@ -497,6 +498,7 @@ + add_extra_compiler_option(-Wno-int-in-bool-context) + add_extra_compiler_option(-Wno-deprecated-declarations) + endif() ++ add_extra_compiler_option(-Wno-missing-template-arg-list-after-template-kw) + add_extra_compiler_option(-fdiagnostics-show-option) + add_extra_compiler_option(-ftemplate-backtrace-limit=0) + diff --git a/graphics/openmvs/files/patch-libs_MVS_Mesh.cpp b/graphics/openmvs/files/patch-libs_MVS_Mesh.cpp new file mode 100644 index 000000000000..fd6e20e61e5f --- /dev/null +++ b/graphics/openmvs/files/patch-libs_MVS_Mesh.cpp @@ -0,0 +1,25 @@ +--- libs/MVS/Mesh.cpp.orig 2024-05-27 00:00:00 UTC ++++ libs/MVS/Mesh.cpp +@@ -35,6 +35,22 @@ + #include + #include + #include ++// Fix for vcglib compatibility with modern C++ standard library ++#include ++#include ++namespace std { ++// Provide random_shuffle for C++14/17 when it's been removed ++template ++void random_shuffle(RandomIt first, RandomIt last, RandomFunc& r) { ++ std::shuffle(first, last, std::default_random_engine()); ++} ++// Provide unary_function for vcglib ++template ++struct unary_function { ++ typedef ArgumentType argument_type; ++ typedef ResultType result_type; ++}; ++} + #ifdef _MSC_VER + #pragma warning(push) + #pragma warning(disable: 4244 4267 4305) diff --git a/graphics/openmvs/pkg-plist b/graphics/openmvs/pkg-plist index 4106ec6de447..373cc4ad6b88 100644 --- a/graphics/openmvs/pkg-plist +++ b/graphics/openmvs/pkg-plist @@ -1,107 +1,108 @@ include/OpenMVS/Common/AABB.h include/OpenMVS/Common/AABB.inl include/OpenMVS/Common/AutoEstimator.h include/OpenMVS/Common/AutoPtr.h include/OpenMVS/Common/Common.h include/OpenMVS/Common/Config.h include/OpenMVS/Common/ConfigTable.h include/OpenMVS/Common/CriticalSection.h include/OpenMVS/Common/EventQueue.h include/OpenMVS/Common/FastDelegate.h include/OpenMVS/Common/FastDelegateBind.h include/OpenMVS/Common/FastDelegateCPP11.h include/OpenMVS/Common/File.h include/OpenMVS/Common/Filters.h include/OpenMVS/Common/HTMLDoc.h include/OpenMVS/Common/HalfFloat.h include/OpenMVS/Common/Hash.h include/OpenMVS/Common/Line.h include/OpenMVS/Common/Line.inl include/OpenMVS/Common/LinkLib.h include/OpenMVS/Common/List.h include/OpenMVS/Common/Log.h include/OpenMVS/Common/MemFile.h include/OpenMVS/Common/OBB.h include/OpenMVS/Common/OBB.inl include/OpenMVS/Common/Octree.h include/OpenMVS/Common/Octree.inl include/OpenMVS/Common/Plane.h include/OpenMVS/Common/Plane.inl include/OpenMVS/Common/Queue.h include/OpenMVS/Common/Random.h include/OpenMVS/Common/Ray.h include/OpenMVS/Common/Ray.inl include/OpenMVS/Common/Rotation.h include/OpenMVS/Common/Rotation.inl include/OpenMVS/Common/SML.h include/OpenMVS/Common/Sampler.inl include/OpenMVS/Common/Semaphore.h include/OpenMVS/Common/SharedPtr.h include/OpenMVS/Common/Sphere.h include/OpenMVS/Common/Sphere.inl include/OpenMVS/Common/Streams.h include/OpenMVS/Common/Strings.h include/OpenMVS/Common/Thread.h include/OpenMVS/Common/Timer.h include/OpenMVS/Common/Types.h include/OpenMVS/Common/Types.inl include/OpenMVS/Common/Util.h include/OpenMVS/Common/Util.inl include/OpenMVS/Common/UtilCUDA.h include/OpenMVS/ConfigLocal.h include/OpenMVS/IO/Common.h include/OpenMVS/IO/Image.h include/OpenMVS/IO/ImageBMP.h include/OpenMVS/IO/ImageDDS.h include/OpenMVS/IO/ImageJPG.h include/OpenMVS/IO/ImagePNG.h include/OpenMVS/IO/ImageSCI.h include/OpenMVS/IO/ImageTGA.h include/OpenMVS/IO/ImageTIFF.h include/OpenMVS/IO/OBJ.h include/OpenMVS/IO/PLY.h include/OpenMVS/IO/TinyXML2.h include/OpenMVS/IO/tiny_gltf.h include/OpenMVS/MVS.h include/OpenMVS/MVS/Camera.h include/OpenMVS/MVS/Common.h include/OpenMVS/MVS/DepthMap.h include/OpenMVS/MVS/Image.h include/OpenMVS/MVS/Interface.h include/OpenMVS/MVS/Mesh.h include/OpenMVS/MVS/PatchMatchCUDA.h include/OpenMVS/MVS/PatchMatchCUDA.inl include/OpenMVS/MVS/Platform.h include/OpenMVS/MVS/PointCloud.h include/OpenMVS/MVS/RectsBinPack.h include/OpenMVS/MVS/Scene.h include/OpenMVS/MVS/SceneDensify.h include/OpenMVS/MVS/SemiGlobalMatcher.h include/OpenMVS/Math/Common.h include/OpenMVS/Math/IBFS/IBFS.h include/OpenMVS/Math/LBP.h include/OpenMVS/Math/LMFit/lmmin.h include/OpenMVS/Math/RobustNorms.h include/OpenMVS/Math/SimilarityTransform.h include/OpenMVS/Math/TRWS/MRFEnergy.h include/OpenMVS/Math/TRWS/MRFEnergy.inl include/OpenMVS/Math/TRWS/instances.h include/OpenMVS/Math/TRWS/minimize.inl include/OpenMVS/Math/TRWS/ordering.inl include/OpenMVS/Math/TRWS/treeProbabilities.inl include/OpenMVS/Math/TRWS/typeBinary.h include/OpenMVS/Math/TRWS/typeBinaryFast.h include/OpenMVS/Math/TRWS/typeGeneral.h include/OpenMVS/Math/TRWS/typePotts.h include/OpenMVS/Math/TRWS/typeTruncatedLinear.h include/OpenMVS/Math/TRWS/typeTruncatedLinear2D.h include/OpenMVS/Math/TRWS/typeTruncatedQuadratic.h include/OpenMVS/Math/TRWS/typeTruncatedQuadratic2D.h lib/OpenMVS/libCommon.so lib/OpenMVS/libIO.so lib/OpenMVS/libMVS.so lib/OpenMVS/libMath.so +lib/pyOpenMVS.so lib/cmake/OpenMVS/OpenMVSConfig.cmake lib/cmake/OpenMVS/OpenMVSConfigVersion.cmake lib/cmake/OpenMVS/OpenMVSTargets-%%CMAKE_BUILD_TYPE%%.cmake lib/cmake/OpenMVS/OpenMVSTargets.cmake