]> git.pld-linux.org Git - packages/inkscape.git/blob - inkscape.spec
135c5ad321f043caf71985dba7e359fac8fca5a9
[packages/inkscape.git] / inkscape.spec
1 #
2 # Conditional build
3 %bcond_with     dbus            # DBus interface
4 %bcond_with     relocation      # Enable binary relocation support
5 %bcond_with     imagick         # ImageMagick 6.x instead of GraphicsMagick
6 #
7
8 Summary:        Scalable vector graphics editor
9 Summary(pl.UTF-8):      Edytor skalowalnej grafiki wektorowej
10 Name:           inkscape
11 Version:        1.1.2
12 Release:        2
13 License:        GPL v2+, LGPL v2.1+
14 Group:          X11/Applications/Graphics
15 # download: follow https://inkscape.org/release/
16 Source0:        https://media.inkscape.org/dl/resources/file/%{name}-%{version}.tar.xz
17 # Source0-md5:  a486807ffdf89a1d7ce9425dd60555ec
18 Patch0:         %{name}-poppler.patch
19 URL:            https://inkscape.org/
20 %{!?with_imagick:BuildRequires: GraphicsMagick-c++-devel}
21 %{?with_imagick:BuildRequires:  ImageMagick6-c++-devel < 7}
22 BuildRequires:  aspell-devel
23 BuildRequires:  boost-devel >= 1.36
24 BuildRequires:  cairo-devel >= 1.10
25 BuildRequires:  cairomm-devel >= 1.9.8
26 BuildRequires:  cmake >= 3.1.0
27 %if %{with dbus}
28 BuildRequires:  dbus-devel
29 BuildRequires:  dbus-glib-devel
30 %endif
31 BuildRequires:  double-conversion-devel
32 BuildRequires:  fontconfig-devel
33 BuildRequires:  freetype-devel >= 2.0
34 BuildRequires:  gc-devel >= 7.2
35 BuildRequires:  gdl-devel >= 3.6
36 BuildRequires:  gettext-tools >= 0.17
37 BuildRequires:  glib2-devel >= 1:2.28
38 BuildRequires:  glibmm-devel >= 2.28
39 BuildRequires:  gsl-devel
40 BuildRequires:  gspell-devel >= 1.0
41 BuildRequires:  gtk+3-devel >= 3.22
42 BuildRequires:  gtkmm3-devel >= 3.22
43 BuildRequires:  harfbuzz-devel
44 BuildRequires:  lcms2-devel >= 2
45 BuildRequires:  lib2geom-devel >= 1.1
46 BuildRequires:  libcdr-devel >= 0.1
47 BuildRequires:  libexif-devel
48 BuildRequires:  libgomp-devel
49 BuildRequires:  libjpeg-devel
50 BuildRequires:  libpng-devel >= 1.2
51 BuildRequires:  librevenge-devel
52 BuildRequires:  libsigc++-devel >= 2.0.17
53 BuildRequires:  libsoup-devel >= 2.42
54 BuildRequires:  libstdc++-devel >= 6:4.7
55 BuildRequires:  libvisio-devel >= 0.1
56 BuildRequires:  libwpd-devel >= 0.9
57 BuildRequires:  libwpg-devel >= 0.3
58 BuildRequires:  libxml2-devel >= 1:2.6.26
59 BuildRequires:  libxslt-devel >= 1.1.17
60 BuildRequires:  pango-devel >= 1:1.24
61 BuildRequires:  pkgconfig
62 BuildRequires:  poppler-glib-devel >= 0.29.0
63 BuildRequires:  popt-devel
64 BuildRequires:  potrace-devel
65 BuildRequires:  rpm-pythonprov
66 BuildRequires:  rpmbuild(macros) >= 1.752
67 BuildRequires:  sed >= 4.0
68 BuildRequires:  xorg-lib-libX11-devel
69 BuildRequires:  zlib-devel
70 Requires(post,postun):  desktop-file-utils
71 Requires:       cairo >= 1.10
72 Requires:       cairomm >= 1.9.8
73 Requires:       gc >= 7.2
74 Requires:       gdl >= 3.6
75 Requires:       glib2 >= 1:2.28
76 Requires:       glibmm >= 2.28
77 Requires:       gtk+3 >= 3.22
78 Requires:       gtkmm3 >= 3.22
79 Requires:       libsigc++ >= 2.0.17
80 Requires:       libxml2 >= 1:2.6.26
81 Requires:       libxslt >= 1.1.17
82 Requires:       pango >= 1:1.24
83 Requires:       perl-XML-XQL
84 Requires:       poppler-glib >= 0.29.0
85 Suggests:       python-lxml
86 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
87
88 %description
89 Inkscape is a program for viewing, making, and editing two-dimensional
90 vector drawings.
91
92 %description -l pl.UTF-8
93 Inkscape jest programem do przeglądania, tworzenia i edycji
94 dwuwymiarowej grafiki wektorowej.
95
96 %package -n bash-completion-inkscape
97 Summary:        Bash completion for inkscape arguments
98 Summary(pl.UTF-8):      Bashowe dopełnianie argumentów programu inkscape
99 Group:          Applications/Shells
100 Requires:       %{name} = %{version}-%{release}
101 Requires:       bash-completion >= 2.0
102 BuildArch:      noarch
103
104 %description -n bash-completion-inkscape
105 Bash completion for inkscape arguments.
106
107 %description -n bash-completion-inkscape -l pl.UTF-8
108 Bashowe dopełnianie argumentów programu inkscape.
109
110 %prep
111 %setup -q -n %{name}-%{version}_2022-02-04_0a00cf5339
112 %patch0 -p1
113
114 %{__sed} -E -i -e '1s,#!\s*/usr/bin/env\s+python2(\s|$),#!%{__python}\1,' -e '1s,#!\s*/usr/bin/env\s+python(\s|$),#!%{__python}\1,' -e '1s,#!\s*/usr/bin/python(\s|$),#!%{__python}\1,' \
115       CMakeScripts/cmake_consistency_check.py \
116       buildtools/msys2checkdeps.py \
117       packaging/scripts/lp-mark-bugs-released \
118       share/extensions/*.py \
119       share/extensions/*/*.py \
120       share/*/i18n.py
121
122 %{__sed} -E -i -e '1s,#!\s*/usr/bin/env\s+perl(\s|$),#!%{__perl}\1,' \
123       share/attributes/genMapDataCSS.pl \
124       share/attributes/genMapDataSVG.pl
125
126 %build
127 mkdir -p build
128 cd build
129
130 %cmake .. \
131         -DBUILD_SHARED_LIBS:BOOL=OFF \
132         %{cmake_on_off relocation ENABLE_BINRELOC} \
133         %{cmake_on_off dbus WITH_DBUS} \
134         %{cmake_on_off imagick WITH_IMAGE_MAGICK}
135
136 %{__make}
137
138 %install
139 rm -rf $RPM_BUILD_ROOT
140
141 %{__make} -C build install \
142         DESTDIR=$RPM_BUILD_ROOT
143
144 # unify locale name, overwrite outdated bn
145 %{__mv} $RPM_BUILD_ROOT%{_localedir}/{bn_BD,bn}/LC_MESSAGES/inkscape.mo
146 # unify names
147 %{__mv} $RPM_BUILD_ROOT%{_localedir}/{ks@aran,ks}
148 %{__mv} $RPM_BUILD_ROOT%{_localedir}/{ks@deva,ks@devanagari}
149 %{__mv} $RPM_BUILD_ROOT%{_localedir}/{sd@deva,sd@devanagari}
150 # unsupported variants
151 %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/{kok@latin,mni@beng,sat@deva}
152
153 %{__rm} $RPM_BUILD_ROOT%{_datadir}/inkscape/extensions/{.pylintrc,LICENSE.txt,MANIFEST.in,README.md,TESTING.md,doxygen-main.dox,setup.cfg,setup.py,tox.ini}
154
155 %find_lang %{name}
156
157 %clean
158 rm -rf $RPM_BUILD_ROOT
159
160 %post
161 %update_desktop_database_post
162
163 %postun
164 %update_desktop_database_postun
165
166 %files -f %{name}.lang
167 %defattr(644,root,root,755)
168 %doc AUTHORS CONTRIBUTING.md NEWS.md README.md
169 %attr(755,root,root) %{_bindir}/inkscape
170 %attr(755,root,root) %{_bindir}/inkview
171 %dir %{_datadir}/inkscape
172 %{_datadir}/inkscape/[!e]*
173 %{_datadir}/inkscape/examples
174 %dir %{_datadir}/inkscape/extensions
175 %{_datadir}/inkscape/extensions/Poly3DObjects
176 %{_datadir}/inkscape/extensions/alphabet_soup
177 %{_datadir}/inkscape/extensions/barcode
178 %{_datadir}/inkscape/extensions/ink2canvas_lib
179 %{_datadir}/inkscape/extensions/inkex
180 %{_datadir}/inkscape/extensions/svg_fonts
181 %{_datadir}/inkscape/extensions/tools
182 %{_datadir}/inkscape/extensions/xaml2svg
183 %attr(755,root,root) %{_datadir}/inkscape/extensions/*.py
184 %attr(755,root,root) %{_datadir}/inkscape/extensions/*.sh
185 %{_datadir}/inkscape/extensions/dxf14_*.txt
186 %{_datadir}/inkscape/extensions/*.inx
187 %{_datadir}/inkscape/extensions/*.js
188 %{_datadir}/inkscape/extensions/*.svg
189 %{_datadir}/inkscape/extensions/*.xml
190 %{_datadir}/inkscape/extensions/*.xsl
191 %{_datadir}/inkscape/extensions/*.xslt
192 %{_datadir}/inkscape/extensions/fontfix.conf
193 %{_datadir}/inkscape/extensions/inkscape.extension.rng
194 %{_datadir}/metainfo/org.inkscape.Inkscape.appdata.xml
195 %{_iconsdir}/hicolor/*/apps/org.inkscape.Inkscape.png
196 %{_iconsdir}/hicolor/scalable/apps/org.inkscape.Inkscape.svg
197 %{_iconsdir}/hicolor/symbolic/apps/org.inkscape.Inkscape-symbolic.svg
198 %{_desktopdir}/org.inkscape.Inkscape.desktop
199 %{_mandir}/man1/inkscape.1*
200 %{_mandir}/man1/inkview.1*
201 %lang(de) %{_mandir}/de/man1/inkscape.1*
202 %lang(fr) %{_mandir}/fr/man1/inkscape.1*
203 %lang(hr) %{_mandir}/hr/man1/inkscape.1*
204 %lang(hu) %{_mandir}/hu/man1/inkscape.1*
205 %lang(zh_TW) %{_mandir}/zh_TW/man1/inkscape.1*
206 %lang(de) %{_mandir}/de/man1/inkview.1*
207 %lang(es) %{_mandir}/es/man1/inkview.1*
208 %lang(fr) %{_mandir}/fr/man1/inkview.1*
209 %lang(hr) %{_mandir}/hr/man1/inkview.1*
210 %lang(hu) %{_mandir}/hu/man1/inkview.1*
211 %lang(pt_BR) %{_mandir}/pt_BR/man1/inkview.1*
212 %lang(zh_TW) %{_mandir}/zh_TW/man1/inkview.1*
213
214 %files -n bash-completion-inkscape
215 %defattr(644,root,root,755)
216 %{bash_compdir}/inkscape
This page took 0.056828 seconds and 3 git commands to generate.