svn commit: r467320 - in head/graphics: . cloudcompare cloudcompare/files
Yuri Victorovich
yuri at FreeBSD.org
Sat Apr 14 14:52:06 UTC 2018
Author: yuri
Date: Sat Apr 14 14:52:04 2018
New Revision: 467320
URL: https://svnweb.freebsd.org/changeset/ports/467320
Log:
New port: graphics/cloudcompare: 3D point cloud processing software
Doesn't build on 12 with PLUGINS=on due to the math/vtk6 failure:
https://gitlab.kitware.com/vtk/vtk/issues/17285
It builds with PLUGINS=off.
Compared to the original submission, sevaral changes have been made:
* Added the PLUGINS option
* Fixed the GAMEPAD option
* etc.
PR: 226239
Submitted by: Neel Chauhan <neel at neelc.org>
Added:
head/graphics/cloudcompare/
head/graphics/cloudcompare/Makefile (contents, props changed)
head/graphics/cloudcompare/distinfo (contents, props changed)
head/graphics/cloudcompare/files/
head/graphics/cloudcompare/files/patch-CMakeExternalLibs.cmake (contents, props changed)
head/graphics/cloudcompare/files/patch-contrib_ShapeLibSupport.cmake (contents, props changed)
head/graphics/cloudcompare/files/patch-plugins_qFacets_CMakeLists.txt (contents, props changed)
head/graphics/cloudcompare/files/patch-plugins_qPCL_PclUtils_filters_MLSSmoothingUpsampling.cpp (contents, props changed)
head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_GfxTL_FlatCopyVector.h (contents, props changed)
head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_GfxTL_KdTree.h (contents, props changed)
head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_MiscLib_AlignedAllocator.h (contents, props changed)
head/graphics/cloudcompare/files/patch-snap_gui_ccViewer.desktop (contents, props changed)
head/graphics/cloudcompare/files/patch-snap_gui_cloudcompare.desktop (contents, props changed)
head/graphics/cloudcompare/pkg-descr (contents, props changed)
head/graphics/cloudcompare/pkg-plist (contents, props changed)
Modified:
head/graphics/Makefile
Modified: head/graphics/Makefile
==============================================================================
--- head/graphics/Makefile Sat Apr 14 14:02:49 2018 (r467319)
+++ head/graphics/Makefile Sat Apr 14 14:52:04 2018 (r467320)
@@ -98,6 +98,7 @@
SUBDIR += chbg
SUBDIR += cimg
SUBDIR += cinepaint
+ SUBDIR += cloudcompare
SUBDIR += clutter
SUBDIR += clutter-gtk
SUBDIR += clutter-gtk3
Added: head/graphics/cloudcompare/Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/Makefile Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,82 @@
+# $FreeBSD$
+
+PORTNAME= cloudcompare
+DISTVERSIONPREFIX= v
+DISTVERSION= 2.9.1-288
+DISTVERSIONSUFFIX= -gb4d51361
+CATEGORIES= graphics
+
+MAINTAINER= neel at neelc.org
+COMMENT= 3D point cloud processing software
+
+LICENSE= GPLv2+ LGPL20+
+LICENSE_COMB= multi
+
+BROKEN_FreeBSD_10= error: "SSE instruction set not enabled"
+
+USES= cmake:outsource localbase:ldflags
+USE_GITHUB= yes
+GH_ACCOUNT= CloudCompare
+GH_PROJECT= ${GH_ACCOUNT}
+GH_TAGNAME= 5d41227deb30c445ccbaa2d789a4363b57948a5d
+USE_QT5= concurrent core gui opengl printsupport widgets buildtools_build qmake_build
+USE_LDCONFIG= yes
+
+OPTIONS_DEFINE= DXFLIB GAMEPAD GDAL PDAL SHAPELIB PLUGINS
+OPTIONS_DEFAULT= DXFLIB GAMEPAD GDAL PDAL SHAPELIB PLUGINS
+OPTIONS_SUB= yes
+
+DXFLIB_DESC= Enable AutoCAD DXF file support
+GAMEPAD_DESC= Enable Qt gamepad support
+GDAL_DESC= Enable raster file support
+PDAL_DESC= Enable point cloud data support
+SHAPELIB_DESC= Enable shape file support
+
+DXFLIB_CMAKE_BOOL= OPTION_USE_DXF_LIB
+
+GAMEPAD_USE= QT5=gamepad
+GAMEPAD_CMAKE_BOOL= OPTION_SUPPORT_GAMEPADS
+
+GDAL_CMAKE_BOOL= OPTION_USE_GDAL
+GDAL_CMAKE_ON= -DGDAL_INCLUDE_DIR=${PREFIX}/include \
+ -DGDAL_LIBRARY=${PREFIX}/lib/libgdal.so
+GDAL_LIB_DEPENDS= libgdal.so:graphics/gdal
+
+PDAL_CMAKE_BOOL= OPTION_PDAL_LAS
+PDAL_CMAKE_ON= -DJSON_ROOT_DIR=${PREFIX}/include/jsoncpp
+PDAL_LIB_DEPENDS= libpdal_base.so:math/pdal
+
+SHAPELIB_CMAKE_BOOL= OPTION_USE_SHAPE_LIB
+SHAPELIB_LIB_DEPENDS= libshp.so:devel/shapelib
+
+PLUGINS_USES= eigen:3 jpeg python:2.7
+PLUGINS_CMAKE_BOOL= INSTALL_QANIMATION_PLUGIN INSTALL_QBLUR_PLUGIN INSTALL_QBROOM_PLUGIN INSTALL_QCOMPASS_PLUGIN \
+ INSTALL_QCSF_PLUGIN INSTALL_QCSV_MATRIX_IO_PLUGIN INSTALL_QDUMMY_PLUGIN INSTALL_QEDL_PLUGIN INSTALL_QFACETS_PLUGIN \
+ INSTALL_QHPR_PLUGIN INSTALL_QM3C2_PLUGIN \
+ INSTALL_QPCL_PLUGIN INSTALL_QPCV_PLUGIN INSTALL_QPHOTOSCAN_IO_PLUGIN INSTALL_QRANSAC_SD_PLUGIN \
+ INSTALL_QSRA_PLUGIN INSTALL_QSSAO_PLUGIN # plugins requiring rare external libs are left out, TODO maybe add some of them?
+PLUGINS_CMAKE_ON= -DEIGEN_ROOT_DIR:BOOL=${LOCALBASE}/include/eigen3
+PLUGINS_CXXFLAGS= -Wno-narrowing
+PLUGINS_CXXFLAGS+= -DEIGEN_DONT_PARALLELIZE # OpenMP is broken in cmake, see bug#223678
+PLUGINS_USE= XORG=ice,sm,x11,xext,xt GL=gl,glu
+PLUGINS_LIB_DEPENDS= libboost_system.so:devel/boost-libs \
+ libexpat.so:textproc/expat2 \
+ libflann_cpp_s.so:math/flann \
+ libfreetype.so:print/freetype2 \
+ libpcl_people.so:graphics/pcl-pointclouds \
+ libpng16.so:graphics/png \
+ libtiff.so:graphics/tiff \
+ libvtkDomainsChemistry-6.2.so:math/vtk6
+PLUGINS_IMPLIES= SHAPELIB
+
+post-patch:
+ @${REINPLACE_CMD} -e 's,%%PREFIX%%,${PREFIX},1' ${WRKSRC}/snap/gui/ccViewer.desktop ${WRKSRC}/snap/gui/cloudcompare.desktop
+
+post-install:
+ @${MKDIR} ${STAGEDIR}${PREFIX}/share/pixmaps
+ ${INSTALL_DATA} ${WRKSRC}/snap/gui/ccViewer.desktop ${STAGEDIR}${PREFIX}/share/applications
+ ${INSTALL_DATA} ${WRKSRC}/snap/gui/ccViewer.png ${STAGEDIR}${PREFIX}/share/pixmaps
+ ${INSTALL_DATA} ${WRKSRC}/snap/gui/cloudcompare.desktop ${STAGEDIR}${PREFIX}/share/applications
+ ${INSTALL_DATA} ${WRKSRC}/snap/gui/cloudcompare.png ${STAGEDIR}${PREFIX}/share/pixmaps
+
+.include <bsd.port.mk>
Added: head/graphics/cloudcompare/distinfo
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/distinfo Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1523597948
+SHA256 (CloudCompare-CloudCompare-v2.9.1-288-gb4d51361-5d41227deb30c445ccbaa2d789a4363b57948a5d_GH0.tar.gz) = 17a473be2706a0146b0652c59ed170c0496eea67e62d5555b5fec67828ef8f13
+SIZE (CloudCompare-CloudCompare-v2.9.1-288-gb4d51361-5d41227deb30c445ccbaa2d789a4363b57948a5d_GH0.tar.gz) = 35032942
Added: head/graphics/cloudcompare/files/patch-CMakeExternalLibs.cmake
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-CMakeExternalLibs.cmake Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,11 @@
+--- CMakeExternalLibs.cmake.orig 2018-03-16 21:26:02 UTC
++++ CMakeExternalLibs.cmake
+@@ -66,7 +66,7 @@ endif()
+ # ------------------------------------------------------------------------------
+ # OpenMP
+ # ------------------------------------------------------------------------------
+-find_package(OpenMP QUIET)
++#find_package(OpenMP QUIET) # Broken on FreeBSD: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=223678
+ if (OPENMP_FOUND)
+ message("OpenMP found")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
Added: head/graphics/cloudcompare/files/patch-contrib_ShapeLibSupport.cmake
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-contrib_ShapeLibSupport.cmake Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,20 @@
+--- contrib/ShapeLibSupport.cmake.orig 2018-03-16 21:26:02 UTC
++++ contrib/ShapeLibSupport.cmake
+@@ -4,14 +4,14 @@
+
+ OPTION( OPTION_USE_SHAPE_LIB "Build with ShapeLib (SHP files support)" OFF )
+ if( ${OPTION_USE_SHAPE_LIB} )
+- add_subdirectory(contrib/shapelib-1.3.0)
+- include_directories( ${SHAPELIB_SOURCE_DIR} )
++ #add_subdirectory(contrib/shapelib-1.3.0)
++ #include_directories( ${SHAPELIB_SOURCE_DIR} )
+ endif()
+
+ # Link project with shapelib library
+ function( target_link_SHAPE_LIB ) # 2 arguments: ARGV0 = project name
+ if( ${OPTION_USE_SHAPE_LIB} )
+- target_link_libraries( ${PROJECT_NAME} SHAPELIB )
++ target_link_libraries( ${PROJECT_NAME} shp )
+ set_property( TARGET ${PROJECT_NAME} APPEND PROPERTY COMPILE_DEFINITIONS CC_SHP_SUPPORT )
+ endif()
+ endfunction()
Added: head/graphics/cloudcompare/files/patch-plugins_qFacets_CMakeLists.txt
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-plugins_qFacets_CMakeLists.txt Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,21 @@
+--- plugins/qFacets/CMakeLists.txt.orig 2018-03-16 21:26:02 UTC
++++ plugins/qFacets/CMakeLists.txt
+@@ -4,7 +4,7 @@ option( INSTALL_QFACETS_PLUGIN "Check to
+
+ # CloudCompare 'FACETS' plugin
+ if (INSTALL_QFACETS_PLUGIN)
+- if (NOT SHAPELIB_SOURCE_DIR)
++ if (NOT OPTION_USE_SHAPE_LIB)
+ message( SEND_ERROR "ShapeLib is required to compile this plugin (enable OPTION_USE_SHAPE_LIB)" )
+ endif()
+
+@@ -27,7 +27,7 @@ if (INSTALL_QFACETS_PLUGIN)
+ target_link_libraries( ${PROJECT_NAME} QCC_IO_LIB )
+
+ #add shapelib support
+- target_link_libraries( ${PROJECT_NAME} SHAPELIB )
+- include_directories( ${SHAPELIB_SOURCE_DIR} )
++ target_link_libraries( ${PROJECT_NAME} shp )
++ #include_directories( ${SHAPELIB_SOURCE_DIR} )
+ set_property( TARGET ${PROJECT_NAME} APPEND PROPERTY COMPILE_DEFINITIONS CC_SHP_SUPPORT )
+ endif()
Added: head/graphics/cloudcompare/files/patch-plugins_qPCL_PclUtils_filters_MLSSmoothingUpsampling.cpp
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-plugins_qPCL_PclUtils_filters_MLSSmoothingUpsampling.cpp Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,11 @@
+--- plugins/qPCL/PclUtils/filters/MLSSmoothingUpsampling.cpp.orig 2018-04-14 06:09:41 UTC
++++ plugins/qPCL/PclUtils/filters/MLSSmoothingUpsampling.cpp
+@@ -51,7 +51,7 @@ int smooth_mls(const typename pcl::Point
+ {
+ typename pcl::search::KdTree<PointInT>::Ptr tree (new pcl::search::KdTree<PointInT>);
+
+-#ifdef _OPENMP
++#if 0 && defined(_OPENMP) // disabled: the only place where omp_xx is used directly
+ //create the smoothing object
+ pcl::MovingLeastSquaresOMP< PointInT, PointOutT > smoother;
+ int n_threads = omp_get_max_threads();
Added: head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_GfxTL_FlatCopyVector.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_GfxTL_FlatCopyVector.h Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,10 @@
+--- plugins/qRANSAC_SD/RANSAC_SD_orig/GfxTL/FlatCopyVector.h.orig 2018-04-14 01:45:59 UTC
++++ plugins/qRANSAC_SD/RANSAC_SD_orig/GfxTL/FlatCopyVector.h
+@@ -1,6 +1,6 @@
+ #ifndef GfxTL__FLATCOPYVECTOR_HEADER__
+ #define GfxTL__FLATCOPYVECTOR_HEADER__
+-#ifndef __APPLE__
++#if !defined(__APPLE__) && !defined(__FreeBSD__)
+ #include <malloc.h>
+ #else
+ #include <stdlib.h>
Added: head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_GfxTL_KdTree.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_GfxTL_KdTree.h Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,11 @@
+--- plugins/qRANSAC_SD/RANSAC_SD_orig/GfxTL/KdTree.h.orig 2018-04-14 01:47:30 UTC
++++ plugins/qRANSAC_SD/RANSAC_SD_orig/GfxTL/KdTree.h
+@@ -14,7 +14,7 @@
+ #include <algorithm>
+ #include <memory>
+ #include <deque>
+-#ifndef __APPLE__
++#if !defined(__APPLE__) && !defined(__FreeBSD__)
+ #include <malloc.h>
+ #else
+ #include <stdlib.h>
Added: head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_MiscLib_AlignedAllocator.h
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-plugins_qRANSAC__SD_RANSAC__SD__orig_MiscLib_AlignedAllocator.h Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,11 @@
+--- plugins/qRANSAC_SD/RANSAC_SD_orig/MiscLib/AlignedAllocator.h.orig 2018-04-14 01:44:24 UTC
++++ plugins/qRANSAC_SD/RANSAC_SD_orig/MiscLib/AlignedAllocator.h
+@@ -1,7 +1,7 @@
+ #ifndef MiscLib__ALIGNEDALLOCATOR_HEADER__
+ #define MiscLib__ALIGNEDALLOCATOR_HEADER__
+ #include <memory>
+-#ifndef __APPLE__
++#if !defined(__APPLE__) && !defined(__FreeBSD__)
+ #include <malloc.h>
+ #else
+ #include <stdlib.h>
Added: head/graphics/cloudcompare/files/patch-snap_gui_ccViewer.desktop
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-snap_gui_ccViewer.desktop Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,13 @@
+--- snap/gui/ccViewer.desktop.orig 2018-03-16 21:26:02 UTC
++++ snap/gui/ccViewer.desktop
+@@ -2,8 +2,8 @@
+ Type=Application
+ Name=CloudCompare Viewer
+ Comment=3D point cloud and mesh processing software
+-Exec=cloudcompare.ccViewer
++Exec=ccViewer
+ Terminal=false
+ Categories=Graphics;
+-Icon=${SNAP}/meta/gui/ccViewer.png
++Icon=/usr/local/share/pixmaps/ccViewer.png
+
Added: head/graphics/cloudcompare/files/patch-snap_gui_cloudcompare.desktop
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/files/patch-snap_gui_cloudcompare.desktop Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,13 @@
+--- snap/gui/cloudcompare.desktop.orig 2018-03-16 21:26:02 UTC
++++ snap/gui/cloudcompare.desktop
+@@ -2,8 +2,8 @@
+ Type=Application
+ Name=CloudCompare
+ Comment=3D point cloud and mesh processing software
+-Exec=cloudcompare.CloudCompare
++Exec=CloudCompare
+ Terminal=false
+ Categories=Graphics;
+-Icon=${SNAP}/meta/gui/cloudcompare.png
++Icon=/usr/local/share/pixmaps/cloudcompare.png
+
Added: head/graphics/cloudcompare/pkg-descr
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/pkg-descr Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,9 @@
+CloudCompare is a 3D point cloud (and triangular mesh) processing software. It
+was originally designed to perform comparison between two 3D points clouds
+(such as the ones obtained with a laser scanner) or between a point cloud and a
+triangular mesh. It relies on an octree structure that is highly optimized for
+this particular use-case. It was also meant to deal with huge point clouds
+(typically more than 10 millions points, and up to 120 millions with 2 Gb of
+memory).
+
+WWW: http://www.cloudcompare.org/
Added: head/graphics/cloudcompare/pkg-plist
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/cloudcompare/pkg-plist Sat Apr 14 14:52:04 2018 (r467320)
@@ -0,0 +1,39 @@
+bin/CloudCompare
+bin/ccViewer
+lib/cloudcompare/libCC_CORE_LIB.so
+lib/cloudcompare/libQCC_DB_LIB.so
+lib/cloudcompare/libQCC_IO_LIB.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQANIMATION_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQBLUR_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQBROOM_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQCOMPASS_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQCSF_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQCSV_MATRIX_IO_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQDUMMY_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQEDL_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQFACETS_PLUGIN_DLL.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQHPR_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQM3C2_PLUGIN_DLL.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQPCL_IO_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQPCL_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQPCV_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQPHOTOSCAN_IO_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQRANSAC_SD_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQSRA_PLUGIN.so
+%%PLUGINS%%lib/cloudcompare/plugins/libQSSAO_PLUGIN.so
+share/applications/ccViewer.desktop
+share/applications/cloudcompare.desktop
+%%DATADIR%%/CHANGELOG.md
+%%DATADIR%%/global_shift_list_template.txt
+%%DATADIR%%/license.txt
+%%PLUGINS%%%%DATADIR%%/shaders/Bilateral/bilateral.frag
+%%PLUGINS%%%%DATADIR%%/shaders/Bilateral/bilateral.vert
+%%PLUGINS%%%%DATADIR%%/shaders/ColorRamp/color_ramp.frag
+%%PLUGINS%%%%DATADIR%%/shaders/EDL/edl_mix.frag
+%%PLUGINS%%%%DATADIR%%/shaders/EDL/edl_mix.vert
+%%PLUGINS%%%%DATADIR%%/shaders/EDL/edl_shade.frag
+%%PLUGINS%%%%DATADIR%%/shaders/EDL/edl_shade.vert
+%%PLUGINS%%%%DATADIR%%/shaders/SSAO/ssao.frag
+%%PLUGINS%%%%DATADIR%%/shaders/SSAO/ssao.vert
+share/pixmaps/ccViewer.png
+share/pixmaps/cloudcompare.png
More information about the svn-ports-all
mailing list