From d9fe21196804c9c17ebc84d695a619084aae986e Mon Sep 17 00:00:00 2001
From: marxin <>
Date: Jul 24 2023 16:31:04 +0000
Subject: Update meshlab to version 2022.02 / rev 1 via SR 1099563
https://build.opensuse.org/request/show/1099563
by user marxin + anag+factory
Re-add the package to Factory, please. If you want, I'm willing to maintain the package.
---
diff --git a/.files b/.files
new file mode 100644
index 0000000..be24655
Binary files /dev/null and b/.files differ
diff --git a/.meta b/.meta
new file mode 100644
index 0000000..448cd6e
--- /dev/null
+++ b/.meta
@@ -0,0 +1,6 @@
+
+ System for processing and editing unstructured 3D triangular meshes.
+ MeshLab is designed for the processing of typical large unstructured models arising in 3D scanning, providing a set of tools for editing, cleaning, healing, inspecting, rendering and converting this kind of meshes.
+
+
+
diff --git a/.rev b/.rev
new file mode 100644
index 0000000..46f8d2f
--- /dev/null
+++ b/.rev
@@ -0,0 +1,10 @@
+
+
+ ba27d76d6ca7755c76e193a54989fafd
+ 2022.02
+
+ anag+factory
+ Re-add the package to Factory, please. If you want, I'm willing to maintain the package.
+ 1099563
+
+
diff --git a/0001-Allow-usage-of-system-provided-levmar.patch b/0001-Allow-usage-of-system-provided-levmar.patch
new file mode 100644
index 0000000..67a7490
--- /dev/null
+++ b/0001-Allow-usage-of-system-provided-levmar.patch
@@ -0,0 +1,159 @@
+From d011885857365284874a14a9cb14a454eb72b157 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Stefan=20Br=C3=BCns?=
+Date: Sun, 22 Jan 2023 07:07:41 +0100
+Subject: [PATCH] Allow usage of system provided levmar
+
+---
+ src/external/levmar.cmake | 22 ++++++++++++++++++-
+ .../edit_mutualcorrs/levmarmethods.h | 2 +-
+ src/meshlabplugins/edit_mutualcorrs/solver.h | 2 +-
+ .../param_collapse.h | 2 +-
+ .../parametrizator.h | 1 -
+ .../filter_mutualglobal/levmarmethods.h | 2 +-
+ .../filter_mutualglobal/solver.h | 2 +-
+ .../filter_mutualinfo/levmarmethods.h | 2 +-
+ src/meshlabplugins/filter_mutualinfo/solver.h | 2 +-
+ 9 files changed, 28 insertions(+), 9 deletions(-)
+
+diff --git a/src/external/levmar.cmake b/src/external/levmar.cmake
+index 63ed77e..50e066a 100644
+--- a/src/external/levmar.cmake
++++ b/src/external/levmar.cmake
+@@ -3,10 +3,30 @@
+ # SPDX-License-Identifier: BSL-1.0
+
+ option(ALLOW_BUNDLED_LEVMAR "Allow use of bundled levmar source" ON)
++option(ALLOW_SYSTEM_LEVMAR "Allow use of system-provided levmar" ON)
+
+ set(LEVMAR_DIR ${CMAKE_CURRENT_LIST_DIR}/levmar-2.3)
+
+-if(ALLOW_BUNDLED_LEVMAR AND EXISTS "${LEVMAR_DIR}/lm.h")
++if (ALLOW_SYSTEM_LEVMAR)
++ find_library(LEVMAR_LIBRARY NAMES levmar)
++ find_path(LEVMAR_INCLUDE_DIR NAMES levmar.h PATH_SUFFIXES levmar)
++
++ if (LEVMAR_LIBRARY AND LEVMAR_INCLUDE_DIR)
++ message(STATUS "Found levmar: ${LEVMAR_LIBRARY} ${LEVMAR_INCLUDE_DIR}")
++ add_library(levmar::levmar UNKNOWN IMPORTED)
++ set_target_properties(levmar::levmar PROPERTIES
++ INTERFACE_INCLUDE_DIRECTORIES "${LEVMAR_INCLUDE_DIR}")
++ set_property(TARGET levmar::levmar APPEND PROPERTY
++ IMPORTED_LOCATION "${LEVMAR_LIBRARY}")
++ endif()
++endif()
++
++if (TARGET levmar::levmar)
++ message(STATUS "- levmar - using system-provided library")
++ add_library(external-levmar INTERFACE)
++ target_link_libraries(external-levmar INTERFACE levmar::levmar)
++
++elseif(ALLOW_BUNDLED_LEVMAR AND EXISTS "${LEVMAR_DIR}/lm.h")
+ message(STATUS "- levmar - using bundled source")
+ add_library(
+ external-levmar STATIC
+diff --git a/src/meshlabplugins/edit_mutualcorrs/levmarmethods.h b/src/meshlabplugins/edit_mutualcorrs/levmarmethods.h
+index 7801493..c1a15c8 100644
+--- a/src/meshlabplugins/edit_mutualcorrs/levmarmethods.h
++++ b/src/meshlabplugins/edit_mutualcorrs/levmarmethods.h
+@@ -12,7 +12,7 @@ sufficient to get a calibrated shot.
+
+ #include
+
+-#include "lm.h"
++#include
+
+
+ struct LevmarCorrelation {
+diff --git a/src/meshlabplugins/edit_mutualcorrs/solver.h b/src/meshlabplugins/edit_mutualcorrs/solver.h
+index 7ee965a..7d93079 100644
+--- a/src/meshlabplugins/edit_mutualcorrs/solver.h
++++ b/src/meshlabplugins/edit_mutualcorrs/solver.h
+@@ -5,7 +5,7 @@
+ #include "alignset.h"
+
+ #include "parameters.h"
+-#include "lm.h"
++#include
+
+ #include
+ #include
+diff --git a/src/meshlabplugins/filter_isoparametrization/param_collapse.h b/src/meshlabplugins/filter_isoparametrization/param_collapse.h
+index 98060e9..363b2ff 100644
+--- a/src/meshlabplugins/filter_isoparametrization/param_collapse.h
++++ b/src/meshlabplugins/filter_isoparametrization/param_collapse.h
+@@ -14,7 +14,7 @@
+
+ #include
+ #include
+-#include
++#include
+ #include
+
+ #include "opt_patch.h"
+diff --git a/src/meshlabplugins/filter_isoparametrization/parametrizator.h b/src/meshlabplugins/filter_isoparametrization/parametrizator.h
+index 74b03db..c548a31 100644
+--- a/src/meshlabplugins/filter_isoparametrization/parametrizator.h
++++ b/src/meshlabplugins/filter_isoparametrization/parametrizator.h
+@@ -32,7 +32,6 @@
+ #include
+ #include
+ #include
+-#include
+ #ifndef _MESHLAB
+ #include
+ #endif
+diff --git a/src/meshlabplugins/filter_mutualglobal/levmarmethods.h b/src/meshlabplugins/filter_mutualglobal/levmarmethods.h
+index decb063..a35d185 100644
+--- a/src/meshlabplugins/filter_mutualglobal/levmarmethods.h
++++ b/src/meshlabplugins/filter_mutualglobal/levmarmethods.h
+@@ -12,7 +12,7 @@ sufficient to get a calibrated shot.
+
+ #include
+
+-#include "lm.h"
++#include
+
+
+ struct LevmarCorrelation {
+diff --git a/src/meshlabplugins/filter_mutualglobal/solver.h b/src/meshlabplugins/filter_mutualglobal/solver.h
+index c7008ec..9e2e497 100644
+--- a/src/meshlabplugins/filter_mutualglobal/solver.h
++++ b/src/meshlabplugins/filter_mutualglobal/solver.h
+@@ -5,7 +5,7 @@
+ #include "alignset.h"
+
+ #include "parameters.h"
+-#include "lm.h"
++#include
+
+ #include
+ #include
+diff --git a/src/meshlabplugins/filter_mutualinfo/levmarmethods.h b/src/meshlabplugins/filter_mutualinfo/levmarmethods.h
+index decb063..a35d185 100644
+--- a/src/meshlabplugins/filter_mutualinfo/levmarmethods.h
++++ b/src/meshlabplugins/filter_mutualinfo/levmarmethods.h
+@@ -12,7 +12,7 @@ sufficient to get a calibrated shot.
+
+ #include
+
+-#include "lm.h"
++#include
+
+
+ struct LevmarCorrelation {
+diff --git a/src/meshlabplugins/filter_mutualinfo/solver.h b/src/meshlabplugins/filter_mutualinfo/solver.h
+index c7008ec..9e2e497 100644
+--- a/src/meshlabplugins/filter_mutualinfo/solver.h
++++ b/src/meshlabplugins/filter_mutualinfo/solver.h
+@@ -5,7 +5,7 @@
+ #include "alignset.h"
+
+ #include "parameters.h"
+-#include "lm.h"
++#include
+
+ #include
+ #include
+--
+2.39.0
+
diff --git a/0001-Remove-unused-return-value-in-unused-function.patch b/0001-Remove-unused-return-value-in-unused-function.patch
new file mode 100644
index 0000000..f7f1b7a
--- /dev/null
+++ b/0001-Remove-unused-return-value-in-unused-function.patch
@@ -0,0 +1,25 @@
+From c629b305180f58b9baa2d0e769dd814ee62a8f53 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Stefan=20Br=C3=BCns?=
+Date: Sun, 22 Jan 2023 02:53:03 +0100
+Subject: [PATCH] Remove unused return value in unused function
+
+---
+ vcg/complex/algorithms/isotropic_remeshing.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/vcg/complex/algorithms/isotropic_remeshing.h b/vcg/complex/algorithms/isotropic_remeshing.h
+index aa14288..f1fcdf7 100644
+--- a/src/vcglib/vcg/complex/algorithms/isotropic_remeshing.h
++++ b/src/vcglib/vcg/complex/algorithms/isotropic_remeshing.h
+@@ -1035,7 +1035,7 @@ private:
+ * \ | / \|/ +0 \ / -1
+ * v3 v3 v3
+ */
+- static bool chooseBestCrossCollapse(PosType &p, VertexPair& bp, std::vector &ff)
++ static void chooseBestCrossCollapse(PosType &p, VertexPair& bp, std::vector &ff)
+ {
+ std::vector vv0, vv1, vv2, vv3;
+ VertexType *v0, *v1, *v2, *v3;
+--
+2.39.0
+
diff --git a/0001-Set-correct-RPATH-for-libraries-and-executable.patch b/0001-Set-correct-RPATH-for-libraries-and-executable.patch
new file mode 100644
index 0000000..12b6794
--- /dev/null
+++ b/0001-Set-correct-RPATH-for-libraries-and-executable.patch
@@ -0,0 +1,51 @@
+From 0c013510d8a932b73a3b88b95688187edf26b6b0 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Stefan=20Br=C3=BCns?=
+Date: Sun, 22 Jan 2023 05:07:13 +0100
+Subject: [PATCH] Set correct RPATH for libraries and executable
+
+---
+ src/CMakeLists.txt | 2 +-
+ src/common/CMakeLists.txt | 2 +-
+ src/meshlab/CMakeLists.txt | 1 +
+ 3 files changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index 1e9a115..9f64bbd 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -72,7 +72,7 @@ if (USE_DEFAULT_BUILD_AND_INSTALL_DIRS) # otherwise, we assume that all these di
+
+ ### Install Settings
+ if (NOT APPLE)
+- set(CMAKE_INSTALL_RPATH $ORIGIN/../${MESHLAB_LIB_INSTALL_DIR};$ORIGIN/../${CMAKE_INSTALL_LIBDIR})
++ set(CMAKE_INSTALL_RPATH $ORIGIN/../${MESHLAB_LIB_INSTALL_DIR})
+ else()
+ SET(CMAKE_INSTALL_RPATH $ORIGIN/../Frameworks)
+ endif()
+diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt
+index ad1c62a..7b25e5e 100644
+--- a/src/common/CMakeLists.txt
++++ b/src/common/CMakeLists.txt
+@@ -170,6 +170,6 @@ if(ENABLE_MESHLAB_DEBUG_LOG_FILE)
+ endif()
+
+ set_target_properties(meshlab-common PROPERTIES
+- INSTALL_RPATH "${MESHLAB_LIB_INSTALL_DIR}:${INSTALL_RPATH}")
++ INSTALL_RPATH "")
+
+ install(TARGETS meshlab-common DESTINATION ${MESHLAB_LIB_INSTALL_DIR})
+diff --git a/src/meshlab/CMakeLists.txt b/src/meshlab/CMakeLists.txt
+index 996cba9..74eb411 100644
+--- a/src/meshlab/CMakeLists.txt
++++ b/src/meshlab/CMakeLists.txt
+@@ -90,6 +90,7 @@ target_link_libraries(
+ )
+
+ set_property(TARGET meshlab PROPERTY FOLDER Core)
++set_property(TARGET meshlab PROPERTY INSTALL_RPATH "$ORIGIN/../${MESHLAB_LIB_INSTALL_DIR}")
+ if (APPLE)
+ set_source_files_properties(${CMAKE_CURRENT_SOURCE_DIR}/images/meshlab.icns PROPERTIES MACOSX_PACKAGE_LOCATION "Resources")
+ file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/images/meshlab.icns DESTINATION "${MESHLAB_BUILD_DISTRIB_DIR}/meshlab.app/Contents/Resources/")
+--
+2.39.0
+
diff --git a/0001-Use-same-paths-for-shader-plugin-lookup-as-used-for-.patch b/0001-Use-same-paths-for-shader-plugin-lookup-as-used-for-.patch
new file mode 100644
index 0000000..47fb186
--- /dev/null
+++ b/0001-Use-same-paths-for-shader-plugin-lookup-as-used-for-.patch
@@ -0,0 +1,36 @@
+From 67cf33fcaec922669d025adbafcb7b46b53a91e5 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Stefan=20Br=C3=BCns?=
+Date: Fri, 24 Sep 2021 14:07:23 +0200
+Subject: [PATCH] Use same paths for shader/plugin lookup as used for
+ installation
+
+Install directories are fixed, absolute directories, set in
+src/CMakeLists.txt. As the plugin directory is relative to the architecture
+dependent libdir, substitute the paths from the spec file.
+---
+ src/common/globals.cpp | 27 ++------------------------
+ 1 file changed, 3 insertions(+), 24 deletions(-)
+
+diff --git a/src/common/globals.cpp b/src/common/globals.cpp
+index aeaa47f..8b18b74 100644
+--- a/src/common/globals.cpp
++++ b/src/common/globals.cpp
+@@ -57,6 +57,7 @@ QString basePath()
+
+ QString meshlab::defaultPluginPath()
+ {
++ return PLUGIN_DIR;
+ QDir pluginsDir(basePath());
+ #ifdef Q_OS_WIN
+ QString d = pluginsDir.dirName();
+@@ -104,6 +105,7 @@ QString meshlab::defaultPluginPath()
+
+ QString meshlab::defaultShadersPath()
+ {
++ return SHADER_DIR;
+ QDir dir(basePath());
+ #ifdef Q_OS_MAC // TODO: check that this works as expected
+ return dir.path() + "/shaders";
+--
+2.33.0
+
diff --git a/_constraints b/_constraints
new file mode 100644
index 0000000..ea2e8cd
--- /dev/null
+++ b/_constraints
@@ -0,0 +1,14 @@
+
+
+
+
+ 5
+
+
+ 4
+
+
+ 800
+
+
+
diff --git a/gcc13-fix.patch b/gcc13-fix.patch
new file mode 100644
index 0000000..8794f25
--- /dev/null
+++ b/gcc13-fix.patch
@@ -0,0 +1,12 @@
+diff --git a/src/external/e57/include/E57Format.h b/src/external/e57/include/E57Format.h
+index 5c3195e..1aa849b 100644
+--- a/src/external/e57/include/E57Format.h
++++ b/src/external/e57/include/E57Format.h
+@@ -32,6 +32,7 @@
+ //! @file E57Format.h header file for the E57 API
+
+ #include
++#include
+ #include
+ #include
+
diff --git a/meshlab-2022.02.tar.gz b/meshlab-2022.02.tar.gz
new file mode 120000
index 0000000..e952ccc
--- /dev/null
+++ b/meshlab-2022.02.tar.gz
@@ -0,0 +1 @@
+/ipfs/bafybeib7nsjroxovohj5h5ydrsyzwdxofjidbvilkfr45vx2kxjg5f3zaa
\ No newline at end of file
diff --git a/meshlab.changes b/meshlab.changes
new file mode 100644
index 0000000..2cf2f68
--- /dev/null
+++ b/meshlab.changes
@@ -0,0 +1,133 @@
+-------------------------------------------------------------------
+Wed Jul 19 06:51:16 UTC 2023 - Martin Liška
+
+- Add gcc13-fix.patch in order to fix compilation with GCC 13.
+
+-------------------------------------------------------------------
+Sun Jan 22 00:08:33 UTC 2023 - Stefan Brüns
+
+- Update to version 2022.02
+ * new plugin for computing parametrizations (Harmonic and LSCM)
+ * various bugfixes and improvements
+ * possibility to select number of threads in filter screened
+ poisson
+ * proper support of multitextured gltf files
+ * new revisited and deterministic filter searcher
+ * some minor new features on set texture and vertex displacement
+ filters
+- Add patches:
+ * 0001-Remove-unused-return-value-in-unused-function.patch
+ * 0001-Set-correct-RPATH-for-libraries-and-executable.patch
+ * 0001-Allow-usage-of-system-provided-levmar.patch
+
+-------------------------------------------------------------------
+Wed Feb 16 18:13:52 UTC 2022 - Stefan Brüns
+
+- Update to version 2021.10
+- For details, see
+ https://github.com/cnr-isti-vclab/meshlab/discussions/1135
+- Drop upstream patches:
+ * 0001-Fix-scope-of-CMake-Policy-variables.patch
+ * 0001-Port-filter_qhull-to-reentrant-libqhull-version.patch
+ * 0001-Override-BUILD_SHARED_LIBS-setting-for-bundled-e57.patch
+
+-------------------------------------------------------------------
+Thu Sep 23 10:29:27 UTC 2021 - Stefan Brüns
+
+- Update to version 2021.07
+ * New Texture Map Defragmentation plugin
+ * Possibility to load files with more than one layer
+ * Reintroduction of far clipping plane
+ * Possibility to load custom shaders
+ * Runtime loading of MeshLab Plugins
+ * Lot of bugfixes
+- See https://github.com/cnr-isti-vclab/meshlab/discussions/992
+ for details
+- Drop upstream patches:
+ * Added-easyexif-minimal-lib-for-exif-loading.patch
+ * Substituted-the-notorious-jhead-with-a-smaller-minimal-lib.patch
+ * libjhead-removed.patch
+ * fixed-cmake-removed-any-other-reference-to-jhead.patch
+- Drop obsolete meshlab-2016.12-shader-path.patch,
+ meshlab-2016.12-remove-double-slash.patch
+- Replace meshlab-2016.12-shader-path.patch with
+ 0001-Use-same-paths-for-shader-plugin-lookup-as-used-for-.patch
+- Add 0001-Fix-scope-of-CMake-Policy-variables.patch
+- Add 0001-Port-filter_qhull-to-reentrant-libqhull-version.patch
+- Add 0001-Override-BUILD_SHARED_LIBS-setting-for-bundled-e57.patch
+- Force XWayland when running under Wayland
+- Do not package license files of unused experimental plugins.
+
+-------------------------------------------------------------------
+Sun Oct 25 22:34:15 UTC 2020 - Stefan Brüns
+
+- Update to version 2020.09
+- Removed upstream patches:
+ * 0001-Fix-qhull-cmake-lookup.patch
+ * 0001-Fix-missing-return-value.patch
+ * 0001-Set-correct-RPATH-when-CMAKE_INSTALL_LIBDIR-is-absol.patch
+ * 0001-Force-STATIC-linking-to-internal-library.patch
+- Add patch to fix building with vcglib release:
+ * Added-easyexif-minimal-lib-for-exif-loading.patch
+ * Substituted-the-notorious-jhead-with-a-smaller-minimal-lib.patch
+ * libjhead-removed.patch
+ * fixed-cmake-removed-any-other-reference-to-jhead.patch
+
+-------------------------------------------------------------------
+Thu Jul 9 12:19:42 UTC 2020 - Stefan Brüns
+
+- Update to version 2020.07
+ * new plugin "Global Registration" based on OpenGR library
+ * option to reverse wheel direction
+ * snap package allows to associate file extensions and to open
+ files on external disks
+ * u3d exporter is now more stable and works on every platform
+ * removed support for XML plugins and QtScript dependecy
+ * VisualSFM (and some other formats) output *.nvm, *.rd.out
+ projects supported by meshlabserver
+ * various bugfixes
+ * For a full changelog, see
+ https://github.com/cnr-isti-vclab/meshlab/releases
+- Drop obsolete patches:
+ * meshlab-2016.12-sharedlib.patch
+ * meshlab-2016.12-novoid-return.patch
+ * meshlab-2016.12-filter-move-xml.patch
+ * meshlab-2016.12-noctm.patch
+ * meshlab-2016.12-fix-qt.patch
+ * meshlab-2016.12-ply-numeric.patch
+ * meshlab-2016.12-readheader.patch
+- Rebased patches:
+ * meshlab-2016.12-plugin-path.patch
+ * meshlab-2016.12-shader-path.patch
+ * meshlab-2016.12-remove-double-slash.patch
+- Added patches:
+ * 0001-Fix-qhull-cmake-lookup.patch
+ * 0001-Fix-missing-return-value.patch
+ * 0001-Set-correct-RPATH-when-CMAKE_INSTALL_LIBDIR-is-absol.patch
+ * 0001-Force-STATIC-linking-to-internal-library.patch
+
+-------------------------------------------------------------------
+Fri Jun 8 13:47:01 UTC 2018 - dliw@posteo.net
+
+- Update to version 2016.12
+ * Total rewriting of the internal rendering system. Huge rendering speed ahead!
+ * Screened Poisson Surface Reconstruction updated to the very latest version.
+ * New Transformation filters.
+ * New ways of getting metric information out of your models.
+ * Transformation matrices are now used more uniformly among filters.
+ * Alpha value is now used properly by all color-related filters.
+ * Improvement and typos removal on various help/description texts.
+ * Direct upload of models on SketchFab
+ * Raster registration on 3D model based also on 2D/3D correspondences
+ * Bug-fixing on almost all filters.
+
+- Revisited all patches
+- Cleaned up spec file
+
+-------------------------------------------------------------------
+Tue Mar 25 18:21:39 UTC 2014 - tchvatal@suse.com
+
+- Initial package at version 1.3.2
+ * inspired and based on fedora spec
+ * Added patch to fix no return in nonvoid functions
+ + meshlab-1.3.2-novoid-return.patch
diff --git a/meshlab.spec b/meshlab.spec
new file mode 100644
index 0000000..63ee1a5
--- /dev/null
+++ b/meshlab.spec
@@ -0,0 +1,147 @@
+#
+# spec file for package meshlab
+#
+# Copyright (c) 2023 SUSE LLC
+#
+# All modifications and additions to the file contributed by third parties
+# remain the property of their copyright owners, unless otherwise agreed
+# upon. The license for this file, and modifications and additions to the
+# file, is the same license as for the pristine package itself (unless the
+# license for the pristine package is not an Open Source License, in which
+# case the license is the MIT License). An "Open Source License" is a
+# license that conforms to the Open Source Definition (Version 1.9)
+# published by the Open Source Initiative.
+
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
+#
+
+
+%if 0%{?suse_version} >= 1550
+%bcond_without gmp
+%else
+%bcond_with gmp
+%endif
+
+Name: meshlab
+Version: 2022.02
+Release: 0
+Summary: System for the processing and editing of unstructured 3D triangular meshes
+License: GPL-2.0-or-later AND BSD-3-Clause
+Group: Productivity/Graphics/3D Editors
+URL: https://www.meshlab.net/
+Source0: https://github.com/cnr-isti-vclab/meshlab/archive/refs/tags/MeshLab-%{version}.tar.gz#/meshlab-%{version}.tar.gz
+# Probably belongs in its own package, but nothing else depends on it
+Source1: https://github.com/cnr-isti-vclab/vcglib/archive/refs/tags/%{version}.tar.gz#/vcglib-%{version}.tar.gz
+# PATCH-FIX-OPENSUSE -- adjust plugin and shader search path
+Patch1: 0001-Use-same-paths-for-shader-plugin-lookup-as-used-for-.patch
+# PATCH-FIX-OPENSUSE -- https://github.com/cnr-isti-vclab/vcglib/issues/210
+Patch2: 0001-Remove-unused-return-value-in-unused-function.patch
+# PATCH-FIX-OPENSUSE
+Patch3: 0001-Set-correct-RPATH-for-libraries-and-executable.patch
+# PATCH-FIX-OPENSUSE
+Patch4: 0001-Allow-usage-of-system-provided-levmar.patch
+Patch5: gcc13-fix.patch
+
+BuildRequires: libboost_headers-devel
+BuildRequires: libboost_thread-devel
+BuildRequires: cmake
+BuildRequires: desktop-file-utils
+BuildRequires: fdupes
+BuildRequires: gcc-c++
+BuildRequires: hicolor-icon-theme
+BuildRequires: levmar-devel
+BuildRequires: libbz2-devel
+BuildRequires: muparser-devel
+BuildRequires: qhull-devel
+BuildRequires: cmake(CGAL)
+BuildRequires: cmake(Qt5OpenGL)
+BuildRequires: cmake(Qt5Qml)
+BuildRequires: cmake(Qt5Xml)
+BuildRequires: cmake(Qt5XmlPatterns)
+BuildRequires: pkgconfig(eigen3)
+BuildRequires: pkgconfig(gl)
+BuildRequires: pkgconfig(glew)
+BuildRequires: pkgconfig(glu)
+BuildRequires: pkgconfig(xerces-c)
+%if %{with gmp}
+BuildRequires: pkgconfig(gmp)
+%endif
+BuildRequires: pkgconfig(lib3ds)
+# Optional, missing:
+#BuildRequires: pkgconfig(OpenCTM)
+# Incompatibility between GLEW and Qt GLES builds
+ExcludeArch: %{arm} aarch64
+
+# Do not add plugins to provides
+%global __provides_exclude_from ^%{_libdir}/meshlab/plugins/.*\\.so
+
+%description
+MeshLab is an open source, portable, and extensible system for the processing
+and editing of unstructured large 3D triangular meshes. The source is
+released under the GPL license. The system is aimed to help the processing
+of the typical not-so-small unstructured models arising in 3D scanning,
+providing a set of tools for editing, cleaning, healing, inspecting,
+rendering and converting this kind of meshes.
+
+%prep
+%setup -a1 -n %{name}-MeshLab-%{version}
+
+# rename vcglib folder
+rmdir src/vcglib
+mv vcglib-%{version} src/vcglib
+
+%autopatch -p1
+
+# Remove bundled library sources, since we use the packaged libraries
+rm -r src/external/{glew*,levmar*,lib3ds*,muparser*,qhull*,xerces*}/*
+
+# set plugin and shader search path
+sed -i 's|PLUGIN_DIR|QString("%{_libdir}/meshlab/plugins")|g' src/common/globals.cpp
+sed -i 's|SHADER_DIR|QString("%{_datadir}/meshlab/shaders")|g' src/common/globals.cpp
+
+%build
+pushd src
+%cmake
+%cmake_build
+popd
+
+
+%install
+pushd src
+%cmake_install
+popd
+
+for i in 16 48 64 128 512 ; do
+ install -D -m 644 src/meshlab/images/eye${i}.png \
+ %{buildroot}%{_datadir}/icons/hicolor/${i}x${i}/apps/meshlab.png
+done
+
+# Make sure Xorg or XWayland is used, native Wayland is not working
+sed -i -e 's/Exec=.*/Exec=env QT_QPA_PLATFORM=xcb meshlab/' %{buildroot}%{_datadir}/applications/meshlab.desktop
+desktop-file-validate %{buildroot}%{_datadir}/applications/meshlab.desktop
+
+# Remove leftover libIFX*.so -- https://github.com/cnr-isti-vclab/meshlab/issues/1353
+rm %{buildroot}%{_libdir}/meshlab/libIFX*.so
+
+install -D -m 0644 -t %{buildroot}%{_mandir}/man1/ docs/man/*.1
+
+%fdupes %{buildroot}%{_datadir}
+
+%post -p /sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+%files
+%{_bindir}/meshlab
+%{_libdir}/meshlab/
+%{_datadir}/meshlab/
+%{_mandir}/man1/*.1%{?ext_man}
+%doc README.md
+%doc docs/privacy.txt
+%license LICENSE.txt
+%license distrib/shaders/3Dlabs-license.txt
+%license distrib/shaders/LightworkDesign-license.txt
+%{_datadir}/icons/hicolor/*/apps/meshlab.*
+%{_datadir}/applications/meshlab.desktop
+
+%changelog
diff --git a/vcglib-2022.02.tar.gz b/vcglib-2022.02.tar.gz
new file mode 120000
index 0000000..213c450
--- /dev/null
+++ b/vcglib-2022.02.tar.gz
@@ -0,0 +1 @@
+/ipfs/bafybeigvhztoc3aowifdutxltnf755xwhx5s3wczvcc3hg6suuwkjouwna
\ No newline at end of file