]> git.pld-linux.org Git - packages/openscad.git/blob - openscad.spec
9d6415baec2a1de8a8a277f9a399ba98d0928d96
[packages/openscad.git] / openscad.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # build with tests
4
5 %ifarch x32
6 %undefine       with_tests
7 %endif
8 Summary:        The Programmers Solid 3D CAD Modeller
9 Name:           openscad
10 Version:        2021.01
11 Release:        2
12 # COPYING contains a linking exception for CGAL
13 # Appdata file is CC0
14 # Examples are CC0
15 License:        GPLv2 with exceptions and CC0
16 Group:          Applications/Engineering
17 Source0:        http://files.openscad.org/%{name}-%{version}.src.tar.gz
18 # Source0-md5:  79f8e3a42bcfeeb3ddde9e5bc2311f76
19 Patch0:         %{name}-polyclipping.patch
20 Patch1:         localedir.patch
21 Patch2:         tests.patch
22 URL:            http://www.openscad.org/
23 BuildRequires:  CGAL-devel >= 4.9
24 BuildRequires:  ImageMagick
25 BuildRequires:  Mesa-dri-driver-swrast
26 BuildRequires:  Qt5Concurrent-devel
27 BuildRequires:  Qt5DBus-devel
28 BuildRequires:  Qt5Multimedia-devel
29 BuildRequires:  Qt5Network-devel
30 BuildRequires:  Qt5PrintSupport-devel
31 BuildRequires:  bison >= 2.4
32 BuildRequires:  boost-devel >= 1.35
33 BuildRequires:  cmake >= 3.3
34 BuildRequires:  desktop-file-utils
35 BuildRequires:  double-conversion-devel
36 BuildRequires:  eigen3
37 BuildRequires:  flex >= 2.5.35
38 BuildRequires:  fontconfig-devel >= 2.10
39 BuildRequires:  freetype-devel >= 2.4
40 BuildRequires:  gettext
41 BuildRequires:  glew-devel >= 1.6
42 BuildRequires:  glib2-devel
43 BuildRequires:  gmp-devel >= 5.0.0
44 BuildRequires:  harfbuzz-devel >= 0.9.19
45 BuildRequires:  lib3mf-devel >= 1.8.1
46 BuildRequires:  libxml2-devel
47 BuildRequires:  libzip-devel
48 BuildRequires:  mpfr-devel >= 3.0.0
49 BuildRequires:  opencsg-devel >= 1.3.2
50 BuildRequires:  pkgconfig
51 BuildRequires:  polyclipping-devel >= 6.1.3
52 BuildRequires:  procps
53 BuildRequires:  python
54 BuildRequires:  qscintilla2-qt5-devel >= 2.11.2
55 BuildRequires:  qt5-build
56 BuildRequires:  rpm-build >= 4.6
57 BuildRequires:  rpmbuild(macros) >= 2.016
58 BuildRequires:  xorg-xserver-Xvfb
59 Requires:       font(liberationmono)
60 Requires:       font(liberationsans)
61 Requires:       font(liberationserif)
62 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
63
64 ### LICENSES:
65
66 ##  LGPLv2+:
67 #   2Dshapes.scad
68 #   3d_triangle.scad
69 #   fonts.scad
70 #   gridbeam.scad
71 #   hardware.scad
72 #   libtriangles.scad
73 #   multiply.scad
74 #   shapes.scad
75 #   screw.scad
76
77 ##  LGPLv2:
78 #   gears.scad
79 #   involute_gears.scad
80 #   servos.scad
81 #   transformations.scad
82 #   triangles.scad
83 #   unregular_shapes.scad
84 #   bitmap/letter_necklace.scad
85
86 ##  LGPLv3+:
87 #   teardrop.scad
88
89 ##  GPLv3 or LGPLv2:
90 #   motors.scad
91 #   nuts_and_bolts.scad
92
93
94 ##  GPLv3+ or LGPLv2:
95 #   metric_fastners.scad
96 #   regular_shapes.scad
97
98 ##  CC-BY-SA or LGPLv2+:
99 #   bearing.scad
100 #   materials.scad
101 #   stepper.scad
102 #   utilities.scad
103
104 ##  CC-BY-SA or LGPLv2:
105 #   units.scad
106
107 ##  CC-BY:
108 #   polyholes.scad
109 #   bitmap/alphabet_block.scad
110 #   bitmap/bitmap.scad
111 #   bitmap/height_map.scad
112 #   bitmap/name_tag.scad
113
114 ## BSD
115 #   boxes.scad
116
117 ## MIT
118 #   constants.scad
119 #   curves.scad
120 #   math.scad
121
122 ## Public Domain
123 #   lego_compatibility.scad
124 #   trochoids.scad
125
126 ###############################################
127
128 %description
129 OpenSCAD is a software for creating solid 3D CAD objects. Unlike most
130 free software for creating 3D models (such as the famous application
131 Blender) it does not focus on the artistic aspects of 3D modeling but
132 instead on the CAD aspects. Thus it might be the application you are
133 looking for when you are planning to create 3D models of machine parts
134 but pretty sure is not what you are looking for when you are more
135 interested in creating computer-animated movies.
136
137 %package MCAD
138 Summary:        OpenSCAD Parametric CAD Library
139 License:        LGPLv2+ and LGPLv2 and LGPLv3+ and (GPLv3 or LGPLv2) and (GPLv3+ or LGPLv2) and (CC-BY-SA or LGPLv2+) and (CC-BY-SA or LGPLv2) and CC-BY and BSD and MIT and Public Domain
140 URL:            https://www.github.com/openscad/MCAD
141 Requires:       %{name} = %{version}-%{release}
142 BuildArch:      noarch
143
144 %description    MCAD
145 This library contains components commonly used in designing and
146 moching up mechanical designs. It is currently unfinished and you can
147 expect some API changes, however many things are already working.
148
149 %prep
150 %setup -q
151 %patch0 -p1
152 %patch1 -p1
153 %patch2 -p1
154
155 # use system package
156 %{__rm} -r src/ext/polyclipping
157
158 %build
159 %{qmake_qt5} \
160         PREFIX=%{_prefix} \
161         CONFIG+=experimental
162 %{__make}
163
164 %if %{with tests}
165 export OPENSCAD_BINARY=$(pwd)/openscad
166 cd tests
167 %cmake .
168 %{__make}
169 %{__make} -j1 test
170 %endif
171
172 %install
173 rm -rf $RPM_BUILD_ROOT
174 %{__make} install \
175         INSTALL_ROOT=$RPM_BUILD_ROOT
176
177 %{__rm} $RPM_BUILD_ROOT%{_datadir}/%{name}/libraries/MCAD/lgpl-2.1.txt
178 %{__rm} $RPM_BUILD_ROOT%{_datadir}/%{name}/libraries/MCAD/README.markdown
179 %{__rm} $RPM_BUILD_ROOT%{_datadir}/%{name}/libraries/MCAD/TODO
180 %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/%{name}/fonts
181
182 %{__mv} $RPM_BUILD_ROOT%{_datadir}/{%{name},}/locale
183
184 %find_lang %{name}
185
186 %clean
187 rm -rf $RPM_BUILD_ROOT
188
189 %files -f %{name}.lang
190 %defattr(644,root,root,755)
191 %doc README.md RELEASE_NOTES.md
192 %attr(755,root,root) %{_bindir}/%{name}
193 %{_datadir}/metainfo/*.xml
194 %{_desktopdir}/%{name}.desktop
195 %{_iconsdir}/hicolor/*x*/apps/openscad.png
196 %{_datadir}/mime/packages/%{name}.xml
197 %dir %{_datadir}/%{name}
198 %{_datadir}/%{name}/examples
199 %{_datadir}/%{name}/color-schemes
200 %dir %{_datadir}/%{name}/libraries
201 %{_datadir}/%{name}/templates
202 %{_mandir}/man1/*
203
204 %files MCAD
205 %defattr(644,root,root,755)
206 %doc libraries/MCAD/README.markdown libraries/MCAD/TODO
207 %{_datadir}/%{name}/libraries/MCAD
This page took 0.083403 seconds and 3 git commands to generate.