]> git.pld-linux.org Git - packages/gegl-qt.git/blob - gegl-qt.spec
eee49ba5406d779e40a1d0b67efb2bc1a68539f8
[packages/gegl-qt.git] / gegl-qt.spec
1 # TODO: qml plugin for qt5
2 #
3 # Conditional build:
4 %bcond_without  python  # Python (PySide) binding for Qt4 library
5 %bcond_without  qt4     # Qt4 library
6 %bcond_without  qt5     # Qt5 library
7 #
8 Summary:        Qt utility library for GEGL
9 Summary(pl.UTF-8):      Biblioteka narzędziowa Qt dla biblioteki GEGL
10 Name:           gegl-qt
11 Version:        0.0.7
12 Release:        1
13 License:        LGPL v3+
14 Group:          Libraries
15 Source0:        https://download.gimp.org/pub/gegl-qt/0.0/%{name}-%{version}.tar.bz2
16 # Source0-md5:  fbb0692af354d404615980a68c8a88f4
17 # git diff 0.0.7 4f46898e7dfaade23553f167bb03caf95171c0e7 (before switch to gegl 0.3)
18 # (then adjusted to apply on dist tarball)
19 Patch0:         %{name}-git.patch
20 Patch1:         %{name}-shiboken.patch
21 Patch2:         %{name}-qmake.patch
22 Patch3:         %{name}-qt5.patch
23 # https://gitlab.gnome.org/Archive/gegl-qt/-/commit/0e48db1e2baac9dde31b1a0b9add2ccd28df012b.patch (last commit)
24 Patch4:         %{name}-gegl-0.3.patch
25 Patch5:         %{name}-gegl-0.4.patch
26 Patch6:         %{name}-python-dirs.patch
27 URL:            https://www.gegl.org/
28 %if %{with qt4}
29 BuildRequires:  QtCore-devel >= 4
30 BuildRequires:  QtDeclarative-devel >= 4
31 BuildRequires:  QtGui-devel >= 4
32 %endif
33 %if %{with qt5}
34 BuildRequires:  Qt5Core-devel >= 5
35 BuildRequires:  Qt5Declarative-devel >= 5
36 BuildRequires:  Qt5Gui-devel >= 5
37 BuildRequires:  Qt5Widgets-devel >= 5
38 %endif
39 BuildRequires:  doxygen
40 BuildRequires:  gegl-devel >= 0.2.0
41 BuildRequires:  pkgconfig
42 %{?with_qt4:BuildRequires:      qt4-qmake >= 4}
43 %{?with_qt5:BuildRequires:      qt5-qmake >= 5}
44 BuildRequires:  rpmbuild(macros) >= 1.219
45 BuildRequires:  texlive-format-pdflatex
46 BuildRequires:  texlive-latex-extend
47 %if %{with python}
48 BuildRequires:  python-PySide-devel >= 4.8_1.2.4-1
49 BuildRequires:  shiboken >= 1.2.4-3
50 %endif
51 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
52
53 %description
54 Qt utility library for GEGL.
55
56 %description -l pl.UTF-8
57 Biblioteka narzędziowa Qt dla biblioteki GEGL.
58
59 %package -n gegl-qt4
60 Summary:        Qt 4 utility library for GEGL
61 Summary(pl.UTF-8):      Biblioteka narzędziowa Qt 4 dla biblioteki GEGL
62 Group:          X11/Libraries
63 Requires:       gegl >= 0.2.0
64
65 %description -n gegl-qt4
66 Qt 4 utility library for GEGL.
67
68 %description -n gegl-qt4 -l pl.UTF-8
69 Biblioteka narzędziowa Qt 4 dla biblioteki GEGL.
70
71 %package -n gegl-qt4-devel
72 Summary:        Header files for gegl-qt4 library
73 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki gegl-qt4
74 Group:          Development/Libraries
75 Requires:       QtCore-devel >= 4
76 Requires:       QtDeclarative-devel >= 4
77 Requires:       QtGui-devel >= 4
78 Requires:       gegl-qt4 = %{version}-%{release}
79 Requires:       gegl-devel >= 0.2.0
80
81 %description -n gegl-qt4-devel
82 Header files for gegl-qt4 library.
83
84 %description -n gegl-qt4-devel -l pl.UTF-8
85 Pliki nagłówkowe biblioteki gegl-qt4.
86
87 %package -n python-gegl-qt4
88 Summary:        Python (PySide) binding for gegl-qt4 library
89 Summary(pl.UTF-8):      Wiązania Pythona (PySide) do biblioteki gegl-qt4
90 Group:          Libraries/Python
91 Requires:       gegl-qt4 = %{version}-%{release}
92 Requires:       python-PySide
93
94 %description -n python-gegl-qt4
95 Python (PySide) binding for gegl-qt4 library.
96
97 %description -n python-gegl-qt4 -l pl.UTF-8
98 Wiązania Pythona (PySide) do biblioteki gegl-qt4.
99
100 %package -n gegl-qt5
101 Summary:        Qt 5 utility library for GEGL
102 Summary(pl.UTF-8):      Biblioteka narzędziowa Qt 5 dla biblioteki GEGL
103 Group:          X11/Libraries
104 Requires:       gegl >= 0.2.0
105
106 %description -n gegl-qt5
107 Qt 5 utility library for GEGL.
108
109 %description -n gegl-qt5 -l pl.UTF-8
110 Biblioteka narzędziowa Qt 5 dla biblioteki GEGL.
111
112 %package -n gegl-qt5-devel
113 Summary:        Header files for gegl-qt5 library
114 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki gegl-qt5
115 Group:          Development/Libraries
116 Requires:       Qt5Core-devel >= 5
117 Requires:       Qt5Declarative-devel >= 5
118 Requires:       Qt5Gui-devel >= 5
119 Requires:       gegl-qt5 = %{version}-%{release}
120 Requires:       gegl-devel >= 0.2.0
121
122 %description -n gegl-qt5-devel
123 Header files for gegl-qt5 library.
124
125 %description -n gegl-qt5-devel -l pl.UTF-8
126 Pliki nagłówkowe biblioteki gegl-qt5.
127
128 %package apidocs
129 Summary:        gegl library API documentation
130 Summary(pl.UTF-8):      Dokumentacja API biblioteki gegl
131 Group:          Documentation
132 Requires:       gtk-doc-common
133
134 %description apidocs
135 gegl library API documentation.
136
137 %description apidocs -l pl.UTF-8
138 Dokumentacja API biblioteki gegl.
139
140 %prep
141 %setup -q
142 %patch0 -p1
143 %patch1 -p1
144 %patch2 -p1
145 %patch3 -p1
146 %patch4 -p1
147 %patch5 -p1
148 %patch6 -p1
149
150 %build
151 %if %{with qt4}
152 install -d build-qt4
153 cd build-qt4
154 qmake-qt4 ../gegl-qt.pro \
155         QMAKE_CXX="%{__cxx}" \
156         QMAKE_CXXFLAGS_RELEASE="%{rpmcxxflags}" \
157         QMAKE_LFLAGS_RELEASE="%{rpmldflags}" \
158         %{!?with_python:HAVE_PYSIDE=no}
159
160 %{__make}
161 cd ..
162 ln -snf build-qt4 build
163 %endif
164
165 %if %{with qt5}
166 install -d build-qt5
167 cd build-qt5
168 qmake-qt5 ../gegl-qt.pro \
169         QMAKE_CXX="%{__cxx}" \
170         QMAKE_CXXFLAGS_RELEASE="%{rpmcxxflags}" \
171         QMAKE_LFLAGS_RELEASE="%{rpmldflags}"
172
173 %{__make}
174 cd ..
175 test -L build || ln -snf build-qt5 build
176 %endif
177
178 %install
179 rm -rf $RPM_BUILD_ROOT
180
181 %if %{with qt4}
182 %{__make} -C build-qt4 install \
183         INSTALL_ROOT=$RPM_BUILD_ROOT
184
185 # extraneous symlink
186 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libgegl-qt4-0.1.so.0.0
187
188 %if %{with python}
189 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
190 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
191 %py_postclean
192 %endif
193 %endif
194
195 %if %{with qt5}
196 %{__make} -C build-qt5 install \
197         INSTALL_ROOT=$RPM_BUILD_ROOT
198
199 # extraneous symlink
200 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libgegl-qt5-0.1.so.0.0
201 %endif
202
203 %clean
204 rm -rf $RPM_BUILD_ROOT
205
206 %post   -p /sbin/ldconfig
207 %postun -p /sbin/ldconfig
208
209 %if %{with qt4}
210 %files -n gegl-qt4
211 %defattr(644,root,root,755)
212 %doc README.txt
213 %attr(755,root,root) %{_libdir}/libgegl-qt4-0.1.so.*.*.*
214 %attr(755,root,root) %ghost %{_libdir}/libgegl-qt4-0.1.so.0
215 # not ready for gegl-0.4
216 #%attr(755,root,root) %{_libdir}/gegl-0.3/libgegl-qt4-display.so
217 %dir %{_libdir}/qt4/imports/GeglQt4
218 %attr(755,root,root) %{_libdir}/qt4/imports/GeglQt4/libgegl-qt4-0.1.so
219 %{_libdir}/qt4/imports/GeglQt4/qmldir
220
221 %files -n gegl-qt4-devel
222 %defattr(644,root,root,755)
223 %attr(755,root,root) %{_libdir}/libgegl-qt4-0.1.so
224 %{_includedir}/gegl-qt4-0.1
225 %{_pkgconfigdir}/gegl-qt4-0.1.pc
226
227 %if %{with python}
228 %files -n python-gegl-qt4
229 %defattr(644,root,root,755)
230 %attr(755,root,root) %{py_sitedir}/gegl-qt4-0.1/geglqt.so
231 %{py_sitedir}/pygeglqt4.py[co]
232 %endif
233 %endif
234
235 %if %{with qt5}
236 %files -n gegl-qt5
237 %defattr(644,root,root,755)
238 %doc README.txt
239 %attr(755,root,root) %{_libdir}/libgegl-qt5-0.1.so.*.*.*
240 %attr(755,root,root) %ghost %{_libdir}/libgegl-qt5-0.1.so.0
241 # not ready for gegl-0.4
242 #%attr(755,root,root) %{_libdir}/gegl-0.3/libgegl-qt5-display.so
243 # not ready for qt5 plugin format (_disabled in qt5 patch)
244 #%dir %{_libdir}/qt4/imports/GeglQt4
245 #%attr(755,root,root) %{_libdir}/qt4/imports/GeglQt4/libgegl-qt4-0.1.so
246 #%{_libdir}/qt4/imports/GeglQt4/qmldir
247
248 %files -n gegl-qt5-devel
249 %defattr(644,root,root,755)
250 %attr(755,root,root) %{_libdir}/libgegl-qt5-0.1.so
251 %{_includedir}/gegl-qt5-0.1
252 %{_pkgconfigdir}/gegl-qt5-0.1.pc
253 %endif
254
255 %files apidocs
256 %defattr(644,root,root,755)
257 %doc build/doc/html/*
This page took 0.098806 seconds and 3 git commands to generate.