source: packaging/qt4.spec@ 1080

Last change on this file since 1080 was 1080, checked in by Dmitry A. Kuminov, 14 years ago

packaging: More WPS objects and various fixes.

File size: 20.8 KB
Line 
1#
2# http://svn.netlabs.org/qt4
3#
4# If you are a packager, please read HowToDistribute.txt for general
5# instructions.
6#
7
8Name: qt4
9Vendor: netlabs.org
10License: LGPLv2 with exceptions or GPLv3 with exceptions
11Url: http://www.qtsoftware.com/
12
13%define ver_major 4
14%define ver_minor 7
15%define ver_patch 3
16
17%define os2_release 0
18
19%define rpm_release 1
20
21%define svn_revision 1070
22
23%define descr_brief Qt is a software toolkit for developing applications.
24
25%define pkg_wps_base QT4
26%define pkg_wps_folder_id <%{pkg_wps_base}_FOLDER>
27%define pkg_wps_folder_create %{pkg_wps_base}_FOLDER:WPFolder|Qt 4|<WP_DESKTOP>
28%define pkg_wps_view_txt() EXENAME=e.exe;PROGTYPE=PROG_PM;PARAMETERS=((%*))
29
30%define pkg_docdir %{_docdir}/%{name}
31
32%if 0%{?os2_release}
33Version: %{ver_major}.%{ver_minor}.%{ver_patch}.%{os2_release}
34%else
35Version: %{ver_major}.%{ver_minor}.%{ver_patch}
36%endif
37Release: %{rpm_release}
38
39Source: %{name}-%{version}.zip
40
41#BuildRequires: gnumake (when available)
42BuildRequires: libc-devel
43BuildRequires: gcc
44BuildRequires: gcc-wlink
45BuildRequires: gcc-wrc
46#BuildRequires: cups-devel (when available)
47BuildRequires: openssl-devel
48BuildRequires: pthread-devel
49#BuildRequires: mysql-devel (when available)
50#BuildRequires: psql-devel (when available)
51
52# @todo add wrc support to Qt!
53
54#------------------------------------------------------------------------------
55# commons
56#------------------------------------------------------------------------------
57
58# process command line arguments
59%if "%{?QT_SOURCE_TREE}" == ""
60%define QT_SOURCE_TREE .
61%endif
62
63# @todo temporary
64%define skip_prep_export 1
65
66# installation paths
67%define qt_prefix %{_libdir}/%{name}
68%define qt_libdir %{_libdir}
69%define qt_headerdir %{_includedir}/%{name}
70%define qt_bindir %{qt_prefix}/bin
71%define qt_plugindir %{qt_prefix}/plugins
72%define qt_importdir %{qt_prefix}/imports
73%define qt_demosdir %{qt_prefix}/demos
74%define qt_examplesdir %{qt_prefix}/examples
75%define qt_datadir %{_datadir}/%{name}
76%define qt_docdir %{qt_datadir}/doc
77%define qt_translationdir %{qt_datadir}/translations
78%define qt_sysconfdir %{_sysconfdir}/xdg
79
80# disable lxlite compression (Qt EXEs and DLLs are already compressed)
81%define __os_install_post %{nil}
82
83#------------------------------------------------------------------------------
84# main package
85#------------------------------------------------------------------------------
86
87Summary: Qt 4 runtime
88Group: System Environment/Libraries
89
90%description
91%{descr_brief}
92
93This package contains runtime Qt libraries for console applications, including
94core, network and XML modules.
95
96%files
97%defattr(-,root,root,-)
98%doc %{pkg_docdir}/
99%docdir %{pkg_docdir}/
100%{pkg_docdir}/*
101%if "%{qt_prefix}" != "%{_prefix}"
102%dir %{qt_prefix}/
103%endif
104%if "%{qt_libdir}" != "%{_libdir}"
105%dir %{qt_libdir}/
106%endif
107%if "%{qt_bindir}" != "%{_bindir}"
108%dir %{qt_bindir}/
109%endif
110%dir %{qt_plugindir}
111%{qt_plugindir}/bearer/
112%{qt_plugindir}/codecs/
113%dir %{qt_plugindir}/sqldrivers/
114%{qt_plugindir}/sqldrivers/*
115%dir %{qt_datadir}/
116%dir %{qt_docdir}/
117%dir %{qt_docdir}/qch/
118%dir %{qt_translationdir}/
119%{qt_translationdir}/qt_??.qm
120%{qt_translationdir}/qt_??_??.qm
121%if "%{qt_sysconfdir}" != "%{_sysconfdir}" && "%{qt_sysconfdir}" != "%{_sysconfdir}/xdg"
122%dir %{qt_sysconfdir}/
123%endif
124%{qt_libdir}/QtCore%{ver_major}.dll
125%{qt_libdir}/QtNet%{ver_major}.dll
126%{qt_libdir}/QtScri%{ver_major}.dll
127%{qt_libdir}/QtSql%{ver_major}.dll
128%{qt_libdir}/QtTest%{ver_major}.dll
129%{qt_libdir}/QtXml%{ver_major}.dll
130%{qt_libdir}/QtXmlP%{ver_major}.dll
131
132%pre
133%warpin_conflicts_begin
134netlabs.org\Qt4\Runtime
135%warpin_conflicts_end
136
137%post
138# clean up the plugin/font cache to remove old entries (@todo other users?)
139rm -f "$HOME/.config/Trolltech.ini"
140
141#------------------------------------------------------------------------------
142%package pm
143#------------------------------------------------------------------------------
144
145Summary: Qt 4 GUI runtime
146Group: System Environment/Libraries
147
148Requires: %{name} = %{version}-%{release}
149
150%description pm
151%{descr_brief}
152
153This package contains runtime Qt libraries for Presentation Manager GUI
154applications.
155
156%files pm
157%defattr(-,root,root,-)
158%dir %{qt_plugindir}/designer
159%{qt_plugindir}/designer/qdeclv.dll
160%{qt_plugindir}/accessible/
161%{qt_plugindir}/graphicssystems/
162%{qt_plugindir}/iconengines/
163%{qt_plugindir}/imageformats/
164%{qt_plugindir}/qmltooling/
165%{qt_translationdir}/qt_help_??.qm
166%{qt_translationdir}/qt_help_??_??.qm
167%dir %{qt_importdir}/
168%{qt_importdir}/Qt/
169%{qt_libdir}/QtCLuc%{ver_major}.dll
170%{qt_libdir}/QtDecl%{ver_major}.dll
171%{qt_libdir}/QtGui%{ver_major}.dll
172%{qt_libdir}/QtHelp%{ver_major}.dll
173%{qt_libdir}/QtScTl%{ver_major}.dll
174%{qt_libdir}/QtSvg%{ver_major}.dll
175
176#------------------------------------------------------------------------------
177%package webkit
178#------------------------------------------------------------------------------
179
180Summary: Qt 4 WebKit runtime
181Group: System Environment/Libraries
182
183Requires: %{name}-pm = %{version}-%{release}
184
185%description webkit
186%{descr_brief}
187
188This package contains runtime Qt libraries for applications based on the WebKit
189technology.
190
191%files webkit
192%defattr(-,root,root,-)
193%{qt_plugindir}/designer/qwebv.dll
194%{qt_importdir}/QtWebKit/
195%{qt_libdir}/QtWebK%{ver_major}.dll
196
197#------------------------------------------------------------------------------
198%package demos
199#------------------------------------------------------------------------------
200Summary: Qt 4 demos and examples
201Group: Documentation
202
203Requires: %{name}-pm = %{version}-%{release}
204Requires: %{name}-designer = %{version}-%{release}
205Requires: %{name}-webkit = %{version}-%{release}
206Requires: %{name}-doc = %{version}-%{release}
207
208%description demos
209%{descr_brief}
210
211This package contains the demo and example Qt applications and their
212source code. These applications demonstrate the possibilities of the
213Qt toolkit.
214
215%files demos
216%defattr(-,root,root,-)
217%{qt_plugindir}/designer/
218%exclude %{qt_plugindir}/designer/qdeclv.dll
219%exclude %{qt_plugindir}/designer/qwebv.dll
220%{qt_bindir}/qtdemo.exe
221%{qt_examplesdir}
222%{qt_demosdir}
223
224%post demos
225%wps_object_create_begin -n %{name}-demos
226%{pkg_wps_folder_create}
227%{pkg_wps_base}_DEMO:WPProgram|Examples and Demos|%{pkg_wps_folder_id}|EXENAME=((%{qt_bindir}/qtdemo.exe))
228%wps_object_create_end
229
230# clean up the qtdemo doc cache, otherwise the demo descriptions may not show up
231# if the old cache contains links to non-existent doc files (@todo other users?)
232rm -f "$HOME/.local/share/data/Trolltech/Assistant/qtdemo_%{ver_major}.%{ver_minor}.%{ver_patch}.qhc"
233
234%postun demos
235%wps_object_delete_all -n %{name}-demos
236
237#------------------------------------------------------------------------------
238%package qmlviewer
239#------------------------------------------------------------------------------
240Summary: Qt 4 QML Viewer tool
241Group: Development/Tools
242
243Requires: %{name}-pm = %{version}-%{release}
244
245%description qmlviewer
246%{descr_brief}
247
248This package contains the Qt QML Viewer tool that allows to view QML files.
249
250%files qmlviewer
251%defattr(-,root,root,-)
252%{qt_bindir}/qmlviewer.exe
253
254%post qmlviewer
255%wps_object_create_begin -n %{name}-qmlviewer
256%{pkg_wps_folder_create}
257%{pkg_wps_base}_QMLVIEWER:WPProgram|QML Viewer|%{pkg_wps_folder_id}|EXENAME=((%{qt_bindir}/qmlview.exe))
258%wps_object_create_end
259
260%postun qmlviewer
261%wps_object_delete_all -n %{name}-qmlviewer
262
263#------------------------------------------------------------------------------
264%package linguist
265#------------------------------------------------------------------------------
266Summary: Qt 4 Linguist tool
267Group: Development/Tools
268
269Requires: %{name}-pm = %{version}-%{release}
270
271%description linguist
272%{descr_brief}
273
274This package contains the Qt Linguist tool used to edit the translation files
275for Qt applications.
276
277%files linguist
278%defattr(-,root,root,-)
279%{qt_translationdir}/linguist_??.qm
280%{qt_translationdir}/linguist_??_??.qm
281%dir %{qt_datadir}/phrasebooks/
282%{qt_datadir}/phrasebooks/*
283%{qt_bindir}/linguist.exe
284
285%post linguist
286%wps_object_create_begin -n %{name}-linguist
287%{pkg_wps_folder_create}
288%{pkg_wps_base}_LINGUIST:WPProgram|Linguist|%{pkg_wps_folder_id}|EXENAME=((%{qt_bindir}/linguist.exe))
289%wps_object_create_end
290
291%postun linguist
292%wps_object_delete_all -n %{name}-linguist
293
294#------------------------------------------------------------------------------
295%package assistant
296#------------------------------------------------------------------------------
297Summary: Qt 4 Assistant tool
298Group: Development/Tools
299
300Requires: %{name}-pm = %{version}-%{release}
301
302%description assistant
303%{descr_brief}
304
305This package contains the Qt Assistant tool used to read and search the Qt
306Toolkit reference documentation.
307
308%files assistant
309%defattr(-,root,root,-)
310%{qt_translationdir}/assistant_??.qm
311%{qt_translationdir}/assistant_??_??.qm
312%{qt_bindir}/assistant.exe
313
314%post assistant
315%wps_object_create_begin -n %{name}-assistant
316%{pkg_wps_folder_create}
317%{pkg_wps_base}_ASSISTANT:WPProgram|Assistant|%{pkg_wps_folder_id}|EXENAME=((%{qt_bindir}/assistant.exe))
318%wps_object_create_end
319
320# clean up the assistant cache & search index (@todo other users?)
321rm -f "$HOME/.local/share/data/Trolltech/Assistant/assistant.qch.%{ver_major}.%{ver_minor}"
322rm -f "$HOME/.local/share/data/Trolltech/Assistant/qthelpcollection_%{ver_major}.%{ver_minor}.%{ver_patch}.qhc"
323rm -rf "$HOME/.local/share/data/Trolltech/Assistant/.qthelpcollection_%{ver_major}.%{ver_minor}.%{ver_patch}"
324
325%postun assistant
326%wps_object_delete_all -n %{name}-assistant
327
328#------------------------------------------------------------------------------
329%package designer
330#------------------------------------------------------------------------------
331Summary: Qt 4 Designer tool
332Group: Development/Tools
333
334Requires: %{name}-pm = %{version}-%{release}
335
336%description designer
337%{descr_brief}
338
339This package contains the Qt Designer tool used to for designing and building
340graphical user interfaces from Qt components.
341
342%files designer
343%defattr(-,root,root,-)
344%{qt_translationdir}/designer_??.qm
345%{qt_translationdir}/designer_??_??.qm
346%{qt_libdir}/QtDsgC%{ver_major}.dll
347%{qt_libdir}/QtDsgn%{ver_major}.dll
348%{qt_bindir}/designer.exe
349
350%post designer
351%wps_object_create_begin -n %{name}-designer
352%{pkg_wps_folder_create}
353%{pkg_wps_base}_DESIGNER:WPProgram|Designer|%{pkg_wps_folder_id}|EXENAME=((%{qt_bindir}/designer.exe))
354%wps_object_create_end
355
356%postun designer
357%wps_object_delete_all -n %{name}-designer
358
359#------------------------------------------------------------------------------
360%package devel-tools
361#------------------------------------------------------------------------------
362Summary: Qt 4 development tools
363Group: Development/Tools
364
365Requires: %{name}-pm = %{version}-%{release}
366
367%description devel-tools
368%{descr_brief}
369
370This package contains tools used to assist in Qt development, including
371PixelTool, Help Converter and other applications.
372
373%files devel-tools
374%defattr(-,root,root,-)
375%{qt_bindir}/lconvert.exe
376%{qt_bindir}/pixeltool.exe
377%{qt_bindir}/qcollectiongenerator.exe
378%{qt_bindir}/qdoc3.exe
379%{qt_bindir}/qhelpconverter.exe
380%{qt_bindir}/qhelpgenerator.exe
381%{qt_bindir}/qt3to4.exe
382%{qt_bindir}/qttracereplay.exe
383%{qt_bindir}/xmlpatterns.exe
384%{qt_bindir}/xmlpatternsvalidator.exe
385
386%post devel-tools
387%wps_object_create_begin -n %{name}-devel-tools
388%{pkg_wps_folder_create}
389%{pkg_wps_base}_PIXELTOOL:WPProgram|Pixel Tool|%{pkg_wps_folder_id}|EXENAME=((%{qt_bindir}/pixeltool.exe))
390%{pkg_wps_base}_HELPCONVERTER:WPProgram|Help Converter|%{pkg_wps_folder_id}|EXENAME=((%{qt_bindir}/qhelpconverter.exe))
391%wps_object_create_end
392
393%postun devel-tools
394%wps_object_delete_all -n %{name}-devel-tools
395
396#------------------------------------------------------------------------------
397%package doc
398#------------------------------------------------------------------------------
399Summary: Qt 4 API documentation
400Group: Documentation
401BuildArch: noarch
402
403Requires: %{name}-assistant = %{version}-%{release}
404
405%description doc
406%{descr_brief}
407
408This package contains the Qt Toolkit reference documentation that provides the
409detailed description of all Qt classes and tools.
410
411%files doc
412%defattr(-,root,root,-)
413%{qt_docdir}/qch/*.qch
414
415%post doc
416%wps_object_create_begin -n %{name}-doc
417%{pkg_wps_folder_create}
418%{pkg_wps_base}_README_FOLDER:WPFolder|Readme Files|%{pkg_wps_folder_id}
419%{pkg_wps_base}_README:WPShadow|README|<%{pkg_wps_base}_README_FOLDER>|SHADOWID=((%{pkg_docdir}/README))
420%{pkg_wps_base}_CHANGES:WPShadow|CHANGES|<%{pkg_wps_base}_README_FOLDER>|SHADOWID=((%{pkg_docdir}/changes-4.7.3))
421%{pkg_wps_base}_README_OS2:WPShadow|README.OS2|<%{pkg_wps_base}_README_FOLDER>|SHADOWID=((%{pkg_docdir}/README.OS2))
422%{pkg_wps_base}_CHANGES_OS2:WPShadow|CHANGES.OS2|<%{pkg_wps_base}_README_FOLDER>|SHADOWID=((%{pkg_docdir}/CHANGES.OS2))
423%wps_object_create_end
424
425%postun doc
426%wps_object_delete_all -n %{name}-doc
427
428#------------------------------------------------------------------------------
429%package devel
430#------------------------------------------------------------------------------
431Summary: Qt 4 development files
432Group: Development/Libraries
433
434Requires: %{name}-pm = %{version}-%{release}
435
436%description devel
437%{descr_brief}
438
439This package contains the headers, libraries and tools necessary to develop
440applications using the Qt toolkit.
441
442%files devel
443%defattr(-,root,root,-)
444%if "%{qt_headerdir}" != "%{_includedir}"
445%dir %{qt_headerdir}/
446%endif
447%{qt_headerdir}/*
448%exclude %{qt_headerdir}/Qt/QtWebKit
449%exclude %{qt_headerdir}/Qt/qgraphicswebview.h
450%exclude %{qt_headerdir}/Qt/qweb*.h
451%exclude %{qt_headerdir}/QtWebKit/
452%{qt_libdir}/*.lib
453%{qt_libdir}/*.prl
454%exclude %{qt_libdir}/QtWebKit%{ver_major}.lib
455%exclude %{qt_libdir}/QtWebKit.prl
456%dir %{qt_datadir}/mkspecs/
457%{qt_datadir}/mkspecs/*
458%exclude %{qt_datadir}/mkspecs/modules/qt_webkit_version.pri
459%{qt_datadir}/q3porting.xml
460%{qt_bindir}/lrelease.exe
461%{qt_bindir}/lupdate.exe
462%{qt_bindir}/moc.exe
463%if "%{qt_bindir}" != "%{_bindir}"
464%{_bindir}/qmake.exe
465%endif
466%{qt_bindir}/qmake.exe
467%{qt_bindir}/rcc.exe
468%{qt_bindir}/uic.exe
469
470#------------------------------------------------------------------------------
471%package webkit-devel
472#------------------------------------------------------------------------------
473Summary: Qt 4 WebKit development files
474Group: Development/Libraries
475
476Requires: %{name}-webkit = %{version}-%{release}
477Requires: %{name}-devel = %{version}-%{release}
478
479%description webkit-devel
480%{descr_brief}
481
482This package contains the headers, libraries and tools necessary to
483develop applications using the Qt WebKit technology.
484
485%files webkit-devel
486%defattr(-,root,root,-)
487%{qt_headerdir}/Qt/QtWebKit
488%{qt_headerdir}/Qt/qgraphicswebview.h
489%{qt_headerdir}/Qt/qweb*.h
490%{qt_headerdir}/QtWebKit/
491%{qt_libdir}/QtWebKit%{ver_major}.lib
492%{qt_libdir}/QtWebKit.prl
493%{qt_datadir}/mkspecs/modules/qt_webkit_version.pri
494
495#------------------------------------------------------------------------------
496%package devel-all
497#------------------------------------------------------------------------------
498Summary: Qt 4 development kit
499Group: Development/Libraries
500
501Requires: %{name}-demos = %{version}-%{release}
502Requires: %{name}-qmlviewer = %{version}-%{release}
503Requires: %{name}-linguist = %{version}-%{release}
504Requires: %{name}-assistant = %{version}-%{release}
505Requires: %{name}-designer = %{version}-%{release}
506Requires: %{name}-devel-tools = %{version}-%{release}
507Requires: %{name}-doc = %{version}-%{release}
508Requires: %{name}-devel = %{version}-%{release}
509Requires: %{name}-webkit-devel = %{version}-%{release}
510
511%description devel-all
512%{descr_brief}
513
514This meta package installs all individual packages containing various Qt
515development components, including the Qt headers and libraries, the Linguist,
516Assistant and Designer applications, development tools, example
517Qt applications and the API documentation.
518
519%files devel-all
520
521#------------------------------------------------------------------------------
522%prep
523#------------------------------------------------------------------------------
524
525%if !0%{?skip_prep}
526
527%if "%{?QT_SOURCE_TREE}" != ""
528%if !0%{?skip_prep_export}
529# get clean source tree from SVN
530%setup -n "%{name}-%{version}" -Tc
531svn export -r %{svn_revision} %{QT_SOURCE_TREE} .
532%else
533# use passed source tree as is (shadow build)
534%setup -n "%{name}-%{version}" -Tc%{?skip_prep_clean:D}
535%endif
536%else
537# use source zip
538%setup -q
539%endif
540
541%endif # if !0%{?skip_prep}
542
543#------------------------------------------------------------------------------
544%build
545#------------------------------------------------------------------------------
546
547%if !0%{?skip_build}
548
549die() { echo "ERROR: $@"; exit 1; }
550check_var() { eval "[ -n \"\$$1\" ] || die \"$1 variable is not set.\""; }
551
552# Qt source tree (DOS format)
553QT_SOURCE_TREE_D=$(echo "%{QT_SOURCE_TREE}" | tr '/' '\\')
554
555# Sanity checks (laking these would turn off features that must be ON)
556check_var "CUPS_INCLUDEPATH"
557check_var "MYSQL_INCLUDEPATH"
558check_var "MYSQL_LIBS"
559check_var "PSQL_INCLUDEPATH"
560check_var "PSQL_LIBS"
561
562[ -z "$MAKE_JOBS" ] && MAKE_JOBS=1
563
564# Qt links to some OS/2 DLLs directly (w/o import libs)
565export LIBRARY_PATH=%{os2_boot_drive}/OS2/DLL\;%{os2_boot_drive}/MPTN/DLL\;$LIBRARY_PATH
566
567# CMD.EXE is required by the build process for now
568export MAKESHELL=%{os2_boot_drive}\\OS2\\CMD.EXE
569
570# Qt doesn't understand /@unixroot in library paths, replace it with $(UNIXROOT)
571library_paths=$(echo \
572 --official-build-quiet %{svn_revision} \
573 -prefix "%{qt_prefix}" \
574 -datadir "%{qt_datadir}" \
575 -libdir "%{qt_libdir}" \
576 -headerdir "%{qt_headerdir}" \
577 -bindir "%{qt_bindir}" \
578 -plugindir "%{qt_plugindir}" \
579 -importdir "%{qt_importdir}" \
580 -demosdir "%{qt_demosdir}" \
581 -examplesdir "%{qt_examplesdir}" \
582 -docdir "%{qt_docdir}" \
583 -translationdir "%{qt_translationdir}" \
584 -sysconfdir "%{qt_sysconfdir}" \
585| sed -re 's,/@unixroot,$(UNIXROOT),g')
586
587BUILDDIR_D=$(echo "%{_builddir}/%{buildsubdir}" | sed -re 's,/,\\,g')
588
589# make sure the right DLLs are used by the build (and in particular by qdoc
590# in make docs) in case if there is another Qt version installed
591export PATH="$BUILDDIR_D\\bin\;$PATH"
592export BEGINLIBPATH="$BUILDDIR_D\\bin\;$BEGINLIBPATH"
593
594# temporarily reset UNIXROOT so that install targets will get only Qt prefixes
595# w/o the UNIXROOT directory chain (if it's not at root)
596UNIXROOT_OLD="$UNIXROOT"
597export UNIXROOT=/.
598
599cmd /c $QT_SOURCE_TREE_D\\configure.cmd $library_paths
600
601make -j$MAKE_JOBS
602
603# resture UNIXROOT
604export UNIXROOT="$UNIXROOT_OLD"
605
606%if !0%{?skip_build_docs}
607# qdoc needs the qsqlite plugin but nothing is installed to target locations
608# yet, so generate qt.conf to override paths
609echo \
610"[Paths]
611Prefix = ..
612Settings = \$(ETC)/xdg
613Examples = examples
614Demos = demos" \
615> "%{_builddir}/%{buildsubdir}/bin/qt.conf"
616make docs -j$MAKE_JOBS
617rm -f "%{_builddir}/%{buildsubdir}/bin/qt.conf"
618%endif
619
620%endif # if !0%{?skip_build}
621
622#------------------------------------------------------------------------------
623%install
624#------------------------------------------------------------------------------
625
626%if !0%{?skip_install}
627
628rm -rf %{buildroot}
629
630# Qt links to some OS/2 DLLs directly (w/o import libs)
631export LIBRARY_PATH=%{os2_boot_drive}/OS2/DLL\;%{os2_boot_drive}/MPTN/DLL\;$LIBRARY_PATH
632
633# CMD.EXE is required by the build process for now
634export MAKESHELL=%{os2_boot_drive}\\OS2\\CMD.EXE
635
636# exclude install_htmldocs from install targets
637make install_subtargets install_qchdocs install_qmake install_mkspecs \
638 INSTALL_ROOT=$(echo "%{buildroot}/@unixroot" | sed -re 's,/,\\,g')
639
640# copy READMEs (make install doesn't do that)
641mkdir -p "%{buildroot}/%{pkg_docdir}/"
642cp -dp \
643 "%{QT_SOURCE_TREE}/LICENSE.*" \
644 "%{QT_SOURCE_TREE}/LGPL_EXCEPTION.txt" \
645 "%{QT_SOURCE_TREE}/README" \
646 "%{QT_SOURCE_TREE}/changes-%{ver_major}.%{ver_minor}.%{ver_patch}" \
647 "%{QT_SOURCE_TREE}/README.OS2" \
648 "%{QT_SOURCE_TREE}/CHANGES.OS2" \
649 "%{buildroot}/%{pkg_docdir}/"
650
651# remove *.dll from bin (they will live in %{qt_libdir})
652rm -f "%{buildroot}/%{qt_bindir}/*.dll" "%{buildroot}/%{qt_bindir}/*.sym"
653
654# remove translations we don't need
655rm -f "%{buildroot}/%{qt_translationdir}/qtconfig_??.qm" \
656 "%{buildroot}/%{qt_translationdir}/qtconfig_??_??.qm"
657rm -f "%{buildroot}/%{qt_translationdir}/qvfb_??.qm" \
658 "%{buildroot}/%{qt_translationdir}/qvfb_??_??.qm"
659
660# move qmake.exe to %{_bindir} (to have it in PATH) and symlink back to qt4/bin
661%if "%{qt_bindir}" != "%{_bindir}"
662mkdir -p "%{buildroot}/%{_bindir}/"
663mv "%{buildroot}/%{qt_bindir}/qmake.exe" "%{buildroot}/%{_bindir}/"
664ln -s "%{_bindir}/qmake.exe" "%{buildroot}/%{qt_bindir}/qmake.exe"
665%endif
666
667# @todo temporarily delete .sym files (until we generate -debuginfo packages)
668find "%{buildroot}/" -type f -name "*.sym" -exec rm -f "{}" \;
669
670%endif # if !0%{?skip_install}
671
672#------------------------------------------------------------------------------
673%clean
674#------------------------------------------------------------------------------
675
676#rm -rf %{buildroot}
677
678#------------------------------------------------------------------------------
679%changelog
Note: See TracBrowser for help on using the repository browser.