1 |
commit: 6499c130f97644defd3b71d86c4af3b3b5c96c2a |
2 |
Author: Bernd Waibel <waebbl-gentoo <AT> posteo <DOT> net> |
3 |
AuthorDate: Sun Oct 17 19:55:29 2021 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Nov 2 10:04:37 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6499c130 |
7 |
|
8 |
media-gfx/freecad: install freecad-thumbnailer |
9 |
|
10 |
Can be used by file-managers to show previews for FreeCAD's .fcstd |
11 |
files. |
12 |
|
13 |
Additional changes: |
14 |
- bump to EAPI 8 |
15 |
- cleanup inherit statement |
16 |
- patch to build with boost-1.77.0 |
17 |
- soften sci-libs/pcl dependency. pcl-1.12 supports vtk-9, so there's |
18 |
no longer any need to use live ebuild |
19 |
- clean optfeature statments from packages which are installed anyway |
20 |
or controlled by USE flags |
21 |
- use C++17 |
22 |
|
23 |
Suggested-by: Michael Perlov <perlovka <AT> gmail.com> |
24 |
Bug: https://github.com/waebbl/waebbl-gentoo/issues/341 |
25 |
Closes: https://bugs.gentoo.org/821160 |
26 |
Package-Manager: Portage-3.0.28, Repoman-3.0.3 |
27 |
Signed-off-by: Bernd Waibel <waebbl-gentoo <AT> posteo.net> |
28 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
29 |
|
30 |
...9999-Add-memory-header-for-std-shared_ptr.patch | 31 ++++++++++++++++++++++ |
31 |
media-gfx/freecad/freecad-9999.ebuild | 24 ++++++++--------- |
32 |
2 files changed, 43 insertions(+), 12 deletions(-) |
33 |
|
34 |
diff --git a/media-gfx/freecad/files/freecad-9999-Add-memory-header-for-std-shared_ptr.patch b/media-gfx/freecad/files/freecad-9999-Add-memory-header-for-std-shared_ptr.patch |
35 |
new file mode 100644 |
36 |
index 00000000000..81a8f22d893 |
37 |
--- /dev/null |
38 |
+++ b/media-gfx/freecad/files/freecad-9999-Add-memory-header-for-std-shared_ptr.patch |
39 |
@@ -0,0 +1,31 @@ |
40 |
+From: Bernd Waibel <waebbl-gentoo@××××××.net> |
41 |
+Date: Sat, 16 Oct 2021 17:02:19 +0200 |
42 |
+Subject: [PATCH] Add memory header for std::shared_ptr |
43 |
+ |
44 |
+Signed-off-by: Bernd Waibel <waebbl-gentoo@××××××.net> |
45 |
+--- |
46 |
+ src/App/Metadata.h | 3 ++- |
47 |
+ 1 file changed, 2 insertions(+), 1 deletion(-) |
48 |
+ |
49 |
+diff --git a/src/App/Metadata.h b/src/App/Metadata.h |
50 |
+index de8be3ea8e..2c5fd8f417 100644 |
51 |
+--- a/src/App/Metadata.h |
52 |
++++ b/src/App/Metadata.h |
53 |
+@@ -30,6 +30,7 @@ |
54 |
+ #include <string> |
55 |
+ #include <vector> |
56 |
+ #include <map> |
57 |
++#include <memory> |
58 |
+ |
59 |
+ #include <xercesc/dom/DOM.hpp> |
60 |
+ #include <xercesc/parsers/XercesDOMParser.hpp> |
61 |
+@@ -296,4 +297,4 @@ namespace App { |
62 |
+ |
63 |
+ } |
64 |
+ |
65 |
+-#endif |
66 |
+\ No newline at end of file |
67 |
++#endif |
68 |
+-- |
69 |
+2.33.1 |
70 |
+ |
71 |
|
72 |
diff --git a/media-gfx/freecad/freecad-9999.ebuild b/media-gfx/freecad/freecad-9999.ebuild |
73 |
index 8c0caca6adc..cef63f28477 100644 |
74 |
--- a/media-gfx/freecad/freecad-9999.ebuild |
75 |
+++ b/media-gfx/freecad/freecad-9999.ebuild |
76 |
@@ -1,11 +1,11 @@ |
77 |
# Copyright 1999-2021 Gentoo Authors |
78 |
# Distributed under the terms of the GNU General Public License v2 |
79 |
|
80 |
-EAPI=7 |
81 |
+EAPI=8 |
82 |
|
83 |
PYTHON_COMPAT=( python3_{8,9} ) |
84 |
|
85 |
-inherit check-reqs cmake desktop eapi8-dosym optfeature python-single-r1 xdg |
86 |
+inherit check-reqs cmake optfeature python-single-r1 xdg |
87 |
|
88 |
DESCRIPTION="QT based Computer Aided Design application" |
89 |
HOMEPAGE="https://www.freecadweb.org/ https://github.com/FreeCAD/FreeCAD" |
90 |
@@ -81,7 +81,7 @@ RDEPEND=" |
91 |
) |
92 |
fem? ( sci-libs/vtk:=[boost,python,qt5,rendering,${PYTHON_SINGLE_USEDEP}] ) |
93 |
openscad? ( media-gfx/openscad ) |
94 |
- pcl? ( ~sci-libs/pcl-${PV}:=[opengl,openni2(+),qt5(+),vtk(+)] ) |
95 |
+ pcl? ( sci-libs/pcl:=[opengl,openni2(+),qt5(+),vtk(+)] ) |
96 |
$(python_gen_cond_dep ' |
97 |
dev-libs/boost:=[python,threads(+),${PYTHON_USEDEP}] |
98 |
dev-python/matplotlib[${PYTHON_USEDEP}] |
99 |
@@ -120,6 +120,7 @@ REQUIRED_USE=" |
100 |
PATCHES=( |
101 |
"${FILESDIR}"/${PN}-0.19_pre20201231-0003-Gentoo-specific-don-t-check-vcs.patch |
102 |
"${FILESDIR}"/${PN}-0.19.1-0001-Gentoo-specific-Remove-ccache-usage.patch |
103 |
+ "${FILESDIR}"/${P}-Add-memory-header-for-std-shared_ptr.patch |
104 |
) |
105 |
|
106 |
DOCS=( CODE_OF_CONDUCT.md ChangeLog.txt README.md ) |
107 |
@@ -168,7 +169,7 @@ src_configure() { |
108 |
-DBUILD_COMPLETE=OFF # deprecated |
109 |
-DBUILD_DRAFT=ON |
110 |
-DBUILD_DRAWING=ON |
111 |
- -DBUILD_ENABLE_CXX_STD:STRING="C++14" # needed for >=boost-1.75.0 |
112 |
+ -DBUILD_ENABLE_CXX_STD:STRING="C++17" # needed for current git master |
113 |
-DBUILD_FEM=$(usex fem) |
114 |
-DBUILD_FEM_NETGEN=OFF |
115 |
-DBUILD_FLAT_MESH=ON |
116 |
@@ -224,14 +225,14 @@ src_configure() { |
117 |
-DFREECAD_USE_QT_FILEDIALOG=ON |
118 |
-DFREECAD_USE_QTWEBMODULE:STRING="Qt WebEngine" |
119 |
|
120 |
- # Use the version of shiboken2 that matches the selected python version |
121 |
- -DPYTHON_CONFIG_SUFFIX="-${EPYTHON}" |
122 |
- |
123 |
# install python modules to site-packages' dir. True only for the main package, |
124 |
# sub-packages will still be installed inside /usr/lib64/freecad |
125 |
-DINSTALL_TO_SITEPACKAGES=ON |
126 |
|
127 |
+ # Use the version of shiboken2 that matches the selected python version |
128 |
+ -DPYTHON_CONFIG_SUFFIX="-${EPYTHON}" |
129 |
-DPython3_EXECUTABLE=${PYTHON} |
130 |
+ |
131 |
-DOCCT_CMAKE_FALLBACK=ON # don't use occt-config which isn't included in opencascade for Gentoo |
132 |
) |
133 |
|
134 |
@@ -289,11 +290,13 @@ src_test() { |
135 |
src_install() { |
136 |
cmake_src_install |
137 |
|
138 |
+ dobin src/Tools/freecad-thumbnailer |
139 |
+ |
140 |
if ! use headless; then |
141 |
- dosym8 -r /usr/$(get_libdir)/${PN}/bin/FreeCAD /usr/bin/freecad |
142 |
+ dosym -r /usr/$(get_libdir)/${PN}/bin/FreeCAD /usr/bin/freecad |
143 |
mv "${ED}"/usr/$(get_libdir)/freecad/share/* "${ED}"/usr/share || die "failed to move shared ressources" |
144 |
fi |
145 |
- dosym8 -r /usr/$(get_libdir)/${PN}/bin/FreeCADCmd /usr/bin/freecadcmd |
146 |
+ dosym -r /usr/$(get_libdir)/${PN}/bin/FreeCADCmd /usr/bin/freecadcmd |
147 |
|
148 |
python_optimize "${ED}"/usr/share/${PN}/data/Mod/Start/StartPage "${ED}"/usr/$(get_libdir)/${PN}{/Ext,/Mod}/ |
149 |
# compile main package in python site-packages as well |
150 |
@@ -326,14 +329,11 @@ pkg_postinst() { |
151 |
einfo "support. Some of them are available in Gentoo. Take a look at" |
152 |
einfo "https://wiki.freecadweb.org/Installing#External_software_supported_by_FreeCAD" |
153 |
optfeature_header "Computational utilities" |
154 |
- optfeature "numerical computations with Python" dev-python/numpy |
155 |
optfeature "BLAS library" sci-libs/openblas |
156 |
optfeature "statistical computation with Python" dev-python/pandas |
157 |
- optfeature "usage of Point Clouds" sci-libs/pcl |
158 |
optfeature "scientific computation with Python" dev-python/scipy |
159 |
optfeature "symbolic math with Python" dev-python/sympy |
160 |
optfeature_header "Imaging, Plotting and Rendering utilities" |
161 |
- optfeature "function plotting with Python" dev-python/matplotlib |
162 |
optfeature "dependency graphs" media-gfx/graphviz |
163 |
optfeature "PBR Rendering" media-gfx/povray |
164 |
optfeature_header "Import / Export" |