/[packages]/backports/8/kicad/current/SPECS/kicad.spec
ViewVC logotype

Contents of /backports/8/kicad/current/SPECS/kicad.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1583603 - (show annotations) (download)
Thu May 14 04:20:15 2020 UTC (3 years, 10 months ago) by daviddavid
Original Path: cauldron/kicad/current/SPECS/kicad.spec
File size: 6881 byte(s)
SILENT: fix build

1 # limit parallel builds on aarch64
2 %ifarch aarch64
3 %global _smp_ncpus_max 4
4 %endif
5
6 # Turn off the brp-python-bytecompile automagic
7 %global _python_bytecompile_extra 0
8
9 %define Werror_cflags %nil
10
11 %define docname kicad-doc
12 %define symname kicad-symbols
13 %define p3dname kicad-packages3D
14 %define templname kicad-templates
15 %define fpname kicad-footprints
16 %define i18nname kicad-i18n
17
18 Name: kicad
19 Summary: An open source program for the creation of electronic schematic diagrams
20 Epoch: 1
21 Version: 5.1.6
22 Release: %mkrel 1
23 License: GPLv3+
24 Group: Sciences/Computer science
25 Url: http://kicad-pcb.org/
26 Source0: https://gitlab.com/kicad/code/kicad/-/archive/%{version}/%{name}-%{version}.tar.bz2
27 Source1: https://gitlab.com/kicad/services/%{docname}/-/archive/%{version}/%{docname}-%{version}.tar.bz2
28 Source2: https://github.com/KiCad/%{symname}/archive/%{version}/%{symname}-%{version}.tar.gz
29 Source3: https://github.com/KiCad/%{p3dname}/archive/%{version}/%{p3dname}-%{version}.tar.gz
30 Source4: https://github.com/KiCad/%{templname}/archive/%{version}/%{templname}-%{version}.tar.gz
31 Source5: https://github.com/KiCad/%{fpname}/archive/%{version}/%{fpname}-%{version}.tar.gz
32 Source6: https://gitlab.com/kicad/code/%{i18nname}/-/archive/%{version}/%{i18nname}-%{version}.tar.bz2
33
34 # This needs to be aligned with kicad-library-*/template/fp-lib-table.for-pretty
35
36 Patch1: 0001-Do-not-strip-executables.patch
37 Patch2: 0002-Include-algorithm-header-in-lib_tree_model.patch
38
39 BuildRequires: wxgtk3.0-devel
40 BuildRequires: mesa-common-devel
41 BuildRequires: imagemagick
42 BuildRequires: boost-devel
43 BuildRequires: glm-devel
44 BuildRequires: opencascade-devel
45 BuildRequires: ngspice-devel
46 BuildRequires: pkgconfig(glew)
47 BuildRequires: pkgconfig(cairo)
48 BuildRequires: pkgconfig(openssl) >= 1.1
49 BuildRequires: libgomp-devel
50 BuildRequires: pkgconfig(libcurl)
51 BuildRequires: cmake
52 # doc
53 BuildRequires: dblatex
54 BuildRequires: po4a
55 BuildRequires: asciidoc
56 BuildRequires: git
57 BuildRequires: perl(Unicode::LineBreak)
58 BuildRequires: source-highlight
59 # python scripting
60 BuildRequires: pkgconfig(python3)
61 BuildRequires: python3-wxpython4
62 BuildRequires: swig
63
64 BuildRequires: desktop-file-utils
65 Requires: %{name}-library
66 Requires: %{docname}
67 Requires: %{i18nname}
68 Requires: python3-wxpython4
69
70 %description
71 Kicad is an open source (GPL) program for the creation of electronic
72 schematic diagrams and printed circuit board artwork.
73
74 Kicad is a set of four programs and a project manager:
75
76 * Eeschema: Schematic entry.
77 * Pcbnew: Board editor.
78 * Gerbview: GERBER viewer (photoplotter documents).
79 * Cvpcb: footprint selector for components used in the circuit design.
80 * Kicad: project manager.
81
82 %package doc
83 Summary: Documentation for kicad (creation of electronic schematic diagrams)
84 Requires: %{name}
85 BuildArch: noarch
86
87 %description doc
88 Kicad is an open source (GPL) program for the creation of electronic
89 schematic diagrams and printed circuit board artwork.
90
91 Kicad-doc is the documentation for kicad.
92
93 %package i18n
94 Summary: Kicad locales
95 Requires: %{name}
96 BuildArch: noarch
97
98 Obsoletes: kicad-locales-ca
99 Obsoletes: kicad-locales-cs
100 Obsoletes: kicad-locales-de
101 Obsoletes: kicad-locales-en
102 Obsoletes: kicad-locales-es
103 Obsoletes: kicad-locales-fi
104 Obsoletes: kicad-locales-fr
105 Obsoletes: kicad-locales-hu
106 Obsoletes: kicad-locales-it
107 Obsoletes: kicad-locales-ja
108 Obsoletes: kicad-locales-ko
109 Obsoletes: kicad-locales-lt
110 Obsoletes: kicad-locales-nl
111 Obsoletes: kicad-locales-pl
112 Obsoletes: kicad-locales-pt
113 Obsoletes: kicad-locales-ru
114 Obsoletes: kicad-locales-sl
115 Obsoletes: kicad-locales-sv
116 Obsoletes: kicad-locales-zh-cn
117
118 %description i18n
119 Kicad is an open source (GPL) program for the creation of electronic
120 schematic diagrams and printed circuit board artwork.
121
122 Kicad-i18n provides locales for kicad.
123
124
125 %package library
126 Summary: Library for kicad (creation of electronic schematic diagrams)
127 License: LGPLv2
128 Requires: %{name}
129 BuildArch: noarch
130
131 %description library
132 Kicad is an open source (GPL) program for the creation of electronic
133 schematic diagrams and printed circuit board artwork.
134
135 Kicad-library is a set of libraries needed by kicad.
136
137 %prep
138 %setup -q -a 1 -a 2 -a 3 -a 4 -a 5 -a 6
139 %autopatch -p1
140
141 %build
142 export LC_ALL=C
143
144 # Building kicad
145 # Set CMAKE_PREFIX_PATH because of a misconfiguration in opencascade
146 %cmake \
147 -DBUILD_SHARED_LIBS:BOOL=OFF \
148 -DCMAKE_BUILD_TYPE=Release \
149 -DKICAD_BUILD_VERSION=%{version} \
150 -DBUILD_GITHUB_PLUGIN=ON \
151 -DKICAD_SCRIPTING=ON \
152 -DKICAD_SCRIPTING_MODULES=ON \
153 -DKICAD_SCRIPTING_WXPYTHON=ON \
154 -DKICAD_SCRIPTING_WXPYTHON_PHOENIX=ON \
155 -DKICAD_SCRIPTING_PYTHON3=ON \
156 -DKICAD_SCRIPTING_ACTION_MENU=ON \
157 -DCPACK_DO_STRIP=OFF
158 %cmake_build
159 # for %%cmake:
160
161 # Building kicad-doc
162 pushd %{docname}-%{version}
163 %cmake \
164 -DCMAKE_BUILD_TYPE=Release \
165 -DBUILD_FORMATS=html
166 %cmake_build
167 popd
168
169 # Building kicad-symbols
170 pushd %{symname}-%{version}
171 %cmake \
172 -DCMAKE_BUILD_TYPE=Release
173 %cmake_build
174 popd
175
176 # Building kicad-packages3D
177 pushd %{p3dname}-%{version}
178 %cmake \
179 -DCMAKE_BUILD_TYPE=Release
180 %cmake_build
181 popd
182
183 # Building kicad-templates
184 pushd %{templname}-%{version}
185 %cmake \
186 -DCMAKE_BUILD_TYPE=Release
187 %cmake_build
188 popd
189
190 # Building kicad-footprints
191 pushd %{fpname}-%{version}
192 %cmake \
193 -DCMAKE_BUILD_TYPE=Release
194 %cmake_build
195 popd
196
197
198 # Building kicad-i18n
199 pushd %{i18nname}-%{version}
200 %cmake \
201 -DCMAKE_BUILD_TYPE=Release \
202 -DKICAD_I18N_UNIX_STRICT_PATH=ON
203 %cmake_build
204 popd
205
206 %install
207 pushd %{docname}-%{version}
208 # Installing kicad-doc
209 %cmake_install
210 popd
211
212 # Installing kicad-symbols
213 pushd %{symname}-%{version}
214 %cmake_install
215 popd
216
217 # Installing kicad-packages3D
218 pushd %{p3dname}-%{version}
219 %cmake_install
220 popd
221
222 # Installing kicad-templates
223 pushd %{templname}-%{version}
224 %cmake_install
225 popd
226
227 # Installing kicad-footprints
228 pushd %{fpname}-%{version}
229 %cmake_install
230 popd
231
232 # Installing kicad-i18n
233 pushd %{i18nname}-%{version}
234 %cmake_install
235 popd
236 %find_lang %{name}
237
238 # Installing kicad
239 %cmake_install
240
241 # create desktop file
242 desktop-file-install --vendor='' \
243 --remove-category='Scientific' \
244 --add-category='Science;Electronics;Education' \
245 --dir=%buildroot%{_datadir}/applications \
246 %buildroot%{_datadir}/applications/*.desktop
247
248 # remove unwanted devel files
249 rm -r %{buildroot}%{_libdir}/libkicad_3dsg.so
250
251 %files
252 %{_bindir}/*
253 %{_libdir}/libkicad_3dsg.so.*
254 %{_iconsdir}/*/*/*
255 %{python3_sitelib}/_pcbnew.so
256 %{python3_sitelib}/pcbnew.*
257 %{python3_sitelib}/__pycache__/*
258 %{_datadir}/%{name}/demos/
259 %{_datadir}/%{name}/template/
260 %{_datadir}/applications/*.desktop
261 %{_datadir}/mime/packages/kicad-*.xml
262 %{_datadir}/appdata/kicad.*.xml
263 %{_libdir}/%{name}/plugins/
264 %{_datadir}/%{name}/plugins/
265 %{_datadir}/%{name}/scripting/
266 %dir %{_libdir}/%{name}
267 %dir %{_datadir}/%{name}
268
269 %files doc
270 %doc %{_docdir}/%{name}/
271
272 %files i18n -f %{name}.lang
273
274 %files library
275 %{_datadir}/%{name}/library
276 %{_datadir}/%{name}/modules

  ViewVC Help
Powered by ViewVC 1.1.30