3 # - better descriptions
5 # - check if translations are avilable
8 %bcond_with nas # enable NAS audio support
9 # static libs disabled for now
10 %bcond_with static_libs # don't build static libraries
11 %bcond_without cups # disable CUPS support
12 %bcond_without mysql # don't build MySQL plugin
13 %bcond_without odbc # don't build unixODBC plugin
14 %bcond_without pgsql # don't build PostgreSQL plugin
15 %bcond_without designer # don't build designer (it takes long)
16 %bcond_without sqlite3 # don't build SQLite3 plugin
17 %bcond_without sqlite # don't build SQLite2 plugin
18 %bcond_without ibase # build ibase (InterBase/Firebird) plugin
19 %bcond_without pch # enable pch in qmake
20 %bcond_with dont_enable # blocks translations, they are not yet available
22 %undefine with_dont_enable
24 %ifnarch %{ix86} %{x8664} sparc sparcv9 alpha ppc
28 %{!?with_sqlite3:%{!?with_sqlite:%{!?with_ibase:%{!?with_mysql:%{!?with_pgsql:%{!?with_odbc:%undefine _withsql}}}}}}
30 Summary: The Qt GUI application framework
31 Summary(es): Biblioteca para ejecutar aplicaciones GUI Qt
32 Summary(pl): Biblioteka Qt do tworzenia GUI
33 Summary(pt_BR): Estrutura para rodar aplicações GUI Qt
36 #Release: 1.%{_snap}.0.1
40 Source0: ftp://ftp.trolltech.com/qt/source/qt-x11-opensource-src-%{version}.tar.gz
41 # Source0-md5: 2db4a4d797d37d0605b776420327503a
42 Source2: qtconfig.desktop
43 Source3: designer.desktop
44 Source4: assistant.desktop
45 Source5: linguist.desktop
46 Patch0: %{name}-tools.patch
47 %if %{with dont_enable}
50 Patch3: qt-disable_tutorials.patch
52 Patch2: %{name}-buildsystem.patch
53 Patch4: %{name}-locale.patch
54 Patch8: %{name}-antialias.patch
55 Patch9: %{name}rc1-build.patch
56 Patch10: %{name}-support-cflags-with-commas.patch
57 URL: http://www.trolltech.com/products/qt/
59 %{?with_ibase:BuildRequires: Firebird-devel}
60 %{?with_sqlite3:BuildRequires: sqlite3-devel}
61 BuildRequires: OpenGL-devel
62 # incompatible with bison
64 %{?with_cups:BuildRequires: cups-devel}
66 BuildRequires: freetype-devel >= 2.0.0
67 %{?with_pch:BuildRequires: gcc >= 5:3.4.0}
68 BuildRequires: libjpeg-devel
69 BuildRequires: libmng-devel >= 1.0.0
70 BuildRequires: libpng-devel >= 1.0.8
71 BuildRequires: libstdc++-devel
72 BuildRequires: libungif-devel
73 %{?with_mysql:BuildRequires: mysql-devel}
74 %{?with_nas:BuildRequires: nas-devel}
75 BuildRequires: perl-base
76 %{?with_pgsql:BuildRequires: postgresql-backend-devel}
77 %{?with_pgsql:BuildRequires: postgresql-devel}
78 # uncomment this in rel. 1 - no time to upgrade rpm
79 #BuildRequires: rpmbuild(macros) >= 1.213
80 BuildRequires: sed >= 4.0
81 %{?with_odbc:BuildRequires: unixODBC-devel}
82 %{?with_sqlite:BuildRequires: sqlite-devel}
83 BuildRequires: xcursor-devel
84 BuildRequires: xft-devel
85 BuildRequires: xrender-devel
86 BuildRequires: zlib-devel
88 Conflicts: kdelibs <= 8:3.2-0.030602.1
89 Obsoletes: qt-extensions
91 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
93 %define _noautoreqdep libGL.so.1 libGLU.so.1
94 %define _noautostrip '.*_debug\\.so*'
97 Qt is a complete C++ application development framework, which includes
98 a class library and tools for multiplatform development and
99 internationalization. Using Qt, a single source code tree can build
100 applications that run natively on different platforms (Windows,
101 Unix/Linux, Mac OS X, embedded Linux).
103 Qt has a rich set of standard widgets, and lets you write custom
104 controls. It encapsulates four different platform-specific APIs, and
105 the APIs for file-handling, networking, process-handling, threading,
106 database access, etc. Qt now also has Motif migration oraz Netscape
110 Contiene las bibliotecas compartidas necesarias para ejecutar
111 aplicaciones Qt, bien como los archivos README.
114 Qt oferuje kompletny system do tworzenia i rozwijania aplikacji w
115 jêzyku C++, w którego sk³ad wchodzi biblioteka z klasami oraz
116 wieloplatformowymi narzêdziami do rozwijania i t³umaczenia aplikacji.
117 Z pomoc± Qt jeden kod ¼ród³owy mo¿e byæ natywnie uruchamiany na
118 ró¿nych platformach (Windows, Unix/Linux, Mac OS X).
120 Qt ma bogaty zbiór standardowych elementów interfejsu graficznego, ale
121 pozwala równie¿ na pisanie w³asnych elementów. £±czy w sposób
122 niewidoczny dla programisty interfejsy programowania ró¿nych systemów,
123 tworz±c w ten sposób jeden interfejs dla obs³ugi plików, sieci,
124 procesów, w±tków, baz danych itp. Umo¿liwia tak¿e ³atwe przenoszenie
125 na Qt aplikacji korzystaj±cych z Motif oraz pisanie wtyczek z
126 wykorzystaniem Netscape LiveConnect.
129 Summary: Core classes used by other modules
130 Summary(pl): Podstawowe klasy u¿ywane przez inne modu³y
133 %description -n QtCore
134 Core classes used by other modules.
136 %description -n QtCore -l pl
137 Podstawowe klasy u¿ywane przez inne modu³y.
139 %package -n QtCore-devel
140 Summary: Core classes used by other modules - development files
141 Summary(pl): Podstawowe klasy u¿ywane przez inne modu³y - pliki programistyczne
142 Group: X11/Development/Libraries
143 Requires: QtCore = %{epoch}:%{version}-%{release}
145 %description -n QtCore-devel
146 Core classes used by other modules - development files.
148 %description -n QtCore-devel -l pl
149 Podstawowe klasy u¿ywane przez inne modu³y - pliki programistyczne.
152 Summary: Graphical User Interface components
153 Summary(pl): Komponenty graficznego interfejsu u¿ytkownika
155 Requires: QtCore = %{epoch}:%{version}-%{release}
157 %description -n QtGui
158 Graphical User Interface components.
160 %description -n QtGui -l pl
161 Komponenty graficznego interfejsu u¿ytkownika.
163 %package -n QtGui-devel
164 Summary: Graphical User Interface components - development files
165 Summary(pl): Komponenty graficznego interfejsu u¿ytkownika - pliki programistyczne
166 Group: X11/Development/Libraries
167 Requires: QtCore-devel = %{epoch}:%{version}-%{release}
168 Requires: QtGui = %{epoch}:%{version}-%{release}
170 %description -n QtGui-devel
171 Graphical User Interface components - development files.
173 %description -n QtGui-devel -l pl
174 Komponenty graficznego interfejsu u¿ytkownika - pliki programistyczne.
176 %package -n QtNetwork
177 Summary: Classes for network programming
178 Summary(pl): Klasy do programowania sieciowego
180 Requires: QtCore = %{epoch}:%{version}-%{release}
182 %description -n QtNetwork
183 Classes for network programming.
185 %description -n QtNetwork -l pl
186 Klasy do programowania sieciowego.
188 %package -n QtNetwork-devel
189 Summary: Classes for network programming - development files
190 Summary(pl): Klasy do programowania sieciowego - pliki programistyczne
191 Group: X11/Development/Libraries
192 Requires: QtCore-devel = %{epoch}:%{version}-%{release}
193 Requires: QtNetwork = %{epoch}:%{version}-%{release}
195 %description -n QtNetwork-devel
196 Classes for network programming - development files.
198 %description -n QtNetwork-devel -l pl
199 Klasy do programowania sieciowego - pliki programistyczne.
202 Summary: OpenGL support classes
203 Summary(pl): Klasy wspomagaj±ce OpenGL
205 Requires: QtCore = %{epoch}:%{version}-%{release}
207 %description -n QtOpenGL
208 OpenGL support classes.
210 %description -n QtOpenGL -l pl
211 Klasy wspomagaj±ce OpenGL.
213 %package -n QtOpenGL-devel
214 Summary: OpenGL support classes - development files
215 Summary(pl): Klasy wspomagaj±ce OpenGL - pliki programistyczne
216 Group: X11/Development/Libraries
217 Requires: QtCore-devel = %{epoch}:%{version}-%{release}
218 Requires: QtOpenGL = %{epoch}:%{version}-%{release}
220 %description -n QtOpenGL-devel
221 OpenGL support classes - development files.
223 %description -n QtOpenGL-devel -l pl
224 Klasy wspomagaj±ce OpenGL - pliki programistyczne.
227 Summary: Classes for database integration using SQL
228 Summary(pl): Klasy do integracji z bazami danych przy u¿yciu SQL
230 Requires: QtCore = %{epoch}:%{version}-%{release}
232 %description -n QtSql
233 Classes for database integration using SQL.
235 %description -n QtSql -l pl
236 Klasy do integracji z bazami danych przy u¿yciu SQL.
238 %package -n QtSql-devel
239 Summary: Classes for database integration using SQL - development files
240 Summary(pl): Klasy do integracji z bazami danych przy u¿yciu SQL - pliki programistyczne
241 Group: X11/Development/Libraries
242 Requires: QtCore-devel = %{epoch}:%{version}-%{release}
243 Requires: QtSql = %{epoch}:%{version}-%{release}
245 %description -n QtSql-devel
246 Classes for database integration using SQL - development files.
248 %description -n QtSql-devel -l pl
249 Klasy do integracji z bazami danych przy u¿yciu SQL - pliki
252 %package -n QtSql-ibase
253 Summary: Database plugin for InterBase/Firebird Qt support
254 Summary(pl): Wtyczka InterBase/Firebird do Qt
255 Summary(pt_BR): Plugin de suporte a InterBase/Firebird para Qt
257 Requires: QtSql = %{epoch}:%{version}-%{release}
258 Provides: QtSql-backend = %{epoch}:%{version}-%{release}
260 %description -n QtSql-ibase
261 This package contains a plugin for accessing Interbase/Firebird
262 database via the QSql classes.
264 %description -n QtSql-ibase -l pl
265 Ten pakiet zawiera wtyczki do Qt umo¿liwiaj±ce korzystanie z baz
266 danych Interbase/Firebird poprzez klasy QSql.
268 %description -n QtSql-ibase -l pt_BR
269 Plugin de suporte a InterBase/Firebird para Qt.
271 %package -n QtSql-mysql
272 Summary: Database plugin for MySQL Qt support
273 Summary(pl): Wtyczka MySQL do Qt
274 Summary(pt_BR): Plugin de suporte a MySQL para Qt
276 Requires: QtSql = %{epoch}:%{version}-%{release}
277 Provides: QtSql-backend = %{epoch}:%{version}-%{release}
279 %description -n QtSql-mysql
280 This package contains a plugin for accessing MySQL database via the
283 %description -n QtSql-mysql -l pl
284 Ten pakiet zawiera wtyczki do Qt umo¿liwiaj±ce korzystanie z baz
285 danych MySQL poprzez klasy QSql.
287 %description -n QtSql-mysql -l pt_BR
288 Plugin de suporte a MySQL para Qt.
290 %package -n QtSql-odbc
291 Summary: Database plugin for ODBC Qt support
292 Summary(pl): Wtyczka ODBC do Qt
293 Summary(pt_BR): Plugin de suporte a ODBC para Qt
295 Requires: QtSql = %{epoch}:%{version}-%{release}
296 Provides: QtSql-backend = %{epoch}:%{version}-%{release}
298 %description -n QtSql-odbc
299 This package contains a plugin for accessing unixODBC services via the
302 %description -n QtSql-odbc -l pl
303 Ten pakiet zawiera wtyczki do Qt umo¿liwiaj±ce korzystanie z us³ug
304 unixODBC poprzez klasy QSql.
306 %description -n QtSql-odbc -l pt_BR
307 Plugin de suporte a ODBC para Qt.
309 %package -n QtSql-pgsql
310 Summary: Database plugin for PostgreSQL Qt support
311 Summary(pl): Wtyczka PostgreSQL do Qt
312 Summary(pt_BR): Plugin de suporte a PostgreSQL para Qt
314 Requires: QtSql = %{epoch}:%{version}-%{release}
315 Provides: QtSql-backend = %{epoch}:%{version}-%{release}
317 %description -n QtSql-pgsql
318 This package contains a plugin for accessing PostgreSQL database via
321 %description -n QtSql-pgsql -l pl
322 Ten pakiet zawiera wtyczki do Qt umo¿liwiaj±ce korzystanie z baz
323 danych PostgreSQL poprzez klasy QSql.
325 %description -n QtSql-pgsql -l es
326 Plugin de suporte a PostgreSQL para Qt.
328 %package -n QtSql-sqlite
329 Summary: Database plugin for SQLite 2.x Qt support
330 Summary(pl): Wtyczka SQLite 2.x do Qt
331 Summary(pt_BR): Plugin de suporte a SQLite 2.x para Qt
333 Requires: QtSql = %{epoch}:%{version}-%{release}
334 Provides: QtSql-backend = %{epoch}:%{version}-%{release}
336 %description -n QtSql-sqlite
337 This package contains a plugin for using the SQLite 2.x library (which
338 allows to acces virtually any SQL database) via the QSql classes.
340 %description -n QtSql-sqlite -l pl
341 Ten pakiet zawiera wtyczki do Qt umo¿liwiaj±ce korzystanie z baz
342 danych SQLite 2.x poprzez klasy QSql.
344 %description -n QtSql-sqlite -l pt_BR
345 Plugin de suporte a SQLite 2.x para Qt.
347 %package -n QtSql-sqlite3
348 Summary: Database plugin for SQLite3 Qt support
349 Summary(pl): Wtyczka SQLite3 do Qt
350 Summary(pt_BR): Plugin de suporte a SQLite3 para Qt
352 Provides: QtSql-backend = %{epoch}:%{version}-%{release}
353 Requires: QtSql = %{epoch}:%{version}-%{release}
355 %description -n QtSql-sqlite3
356 This package contains a plugin for using the SQLite3 library (which
357 allows to acces virtually any SQL database) via the QSql classes.
359 %description -n QtSql-sqlite3 -l pl
360 Ten pakiet zawiera wtyczki do Qt umo¿liwiaj±ce korzystanie z baz
361 danych SQLite3 poprzez klasy QSql.
363 %description -n QtSql-sqlite3 -l pt_BR
364 Plugin de suporte a SQLite3 para Qt.
367 Summary: Classes for handling XML
368 Summary(pl): Klasy do obs³ugi XML-a
370 Requires: QtCore = %{epoch}:%{version}-%{release}
372 %description -n QtXml
373 Classes for handling XML.
375 %description -n QtXml -l pl
376 Klasy do obs³ugi XML-a.
378 %package -n QtXml-devel
379 Summary: Classes for handling XML - development files
380 Summary(pl): Klasy do obs³ugi XML-a - pliki programistyczne
381 Group: X11/Development/Libraries
382 Requires: QtCore-devel = %{epoch}:%{version}-%{release}
383 Requires: QtXml = %{epoch}:%{version}-%{release}
385 %description -n QtXml-devel
386 Classes for handling XML - development files.
388 %description -n QtXml-devel -l pl
389 Klasy do obs³ugi XML-a - pliki programistyczne.
391 %package -n Qt3Support
392 Summary: Qt3 compatibility library
393 Summary(pl): Biblioteka kompatybilno¶ci z Qt3
395 Requires: QtCore = %{epoch}:%{version}-%{release}
397 %description -n Qt3Support
398 Qt3 compatibility library.
400 %description -n Qt3Support -l pl
401 Biblioteka kompatybilno¶ci z Qt3.
403 %package -n Qt3Support-devel
404 Summary: Qt3 compatibility library - development files
405 Summary(pl): Biblioteka kompatybilno¶ci z Qt3 - pliki programistyczne
406 Group: X11/Development/Libraries
407 Requires: QtCore-devel = %{epoch}:%{version}-%{release}
408 Requires: Qt3Support = %{epoch}:%{version}-%{release}
410 %description -n Qt3Support-devel
411 Qt3 compatibility library - development files.
413 %description -n Qt3Support-devel -l pl
414 Biblioteka kompatybilno¶ci z Qt3 - pliki programistyczne.
417 Summary: Qt documentation browser
418 Summary(pl): Przegl±darka dokumentacji Qt
419 Group: X11/Development/Tools
420 Requires: %{name}-doc
422 %description assistant
423 Qt Assistant is a tool for browsing on-line documentation with
424 indexing, bookmarks and full-text search.
426 %description assistant -l pl
427 Qt Assistant to narzêdzie do przegl±dania dokumentacji z mo¿liwo¶ci±
428 indeksowania, dodawania zak³adek i pe³notekstowego wyszukiwania.
431 Summary: Build tools for Qt4
432 Summary(pl): Narzêdzia do budowania dla Qt4
433 Group: X11/Development/Tools
434 Requires: QtCore = %{epoch}:%{version}-%{release}
435 Requires: QtXml = %{epoch}:%{version}-%{release}
438 This package includes the Qt resource compiler (rcc), meta objects
439 compiler (moc), user interface compiler (uic) and qt3to4 include names
442 %description build -l pl
443 Ten pakiet zawiera komilator zasobów Qt (rcc), kompilator metaobiektów
444 (moc), kompilator interfejsów u¿ytkownika (uic) oraz konwerter nazw
445 plików nag³ówkowych qt3to4.
448 Summary: IDE used for GUI designing with Qt library
449 Summary(pl): IDE s³u¿±ce do projektowania GUI za pomoc± biblioteki Qt
450 Group: X11/Applications
451 Requires: %{name}-designer-libs = %{epoch}:%{version}-%{release}
453 %description designer
454 An advanced tool used for GUI designing with Qt library.
456 %description designer -l pl
457 Zaawansowane narzêdzie s³u¿±ce do projektowania interfejsu graficznego
458 za pomoc± biblioteki Qt.
460 %package -n QtDesigner-devel
461 Summary: IDE used for GUI designing with Qt library - development files
462 Summary(pl): IDE s³u¿±ce do projektowania GUI za pomoc± biblioteki Qt - pliki programistyczne
463 Group: X11/Development/Libraries
464 Requires: QtCore-devel = %{epoch}:%{version}-%{release}
465 Requires: %{name}-designer-libs = %{epoch}:%{version}-%{release}
467 %description -n QtDesigner-devel
468 IDE used for GUI designing with Qt library - development files.
470 %description -n QtDesigner-devel -l pl
471 IDE s³u¿±ce do projektowania GUI za pomoc± biblioteki Qt - pliki
474 %package designer-libs
475 Summary: Libraries IDE used for GUI designing with Qt library
476 Summary(pl): Biblioteki do IDE s³u¿±cego do projektowania GUI za pomoc± biblioteki Qt
477 Group: X11/Applications
479 %description designer-libs
480 Libraries used by the Qt GUI Designer.
482 %description designer-libs -l pl
483 Biblioteki wykorzystywane przez narzêdzie projektowania interfejsu
484 graficznego - Qt Designer.
487 Summary: Translation helper for Qt
488 Summary(pl): Aplikacja u³atwiaj±ca t³umaczenie aplikacji oparty o Qt
489 Group: X11/Development/Tools
491 %description linguist
492 This program provides an interface that shortens and helps systematize
493 the process of translating GUIs. Qt Linguist takes all of the text of
494 a UI that will be shown to the user, and presents it to a human
495 translator in a simple window. When one UI text is translated, the
496 program automatically progresses to the next, until they are all
499 %description linguist -l pl
500 Ten program oferuje interfejs znacznie przy¶pieszaj±cy proces
501 t³umaczenia interfejsu u¿ytkownika. Zbiera wszystkie teksty
502 przeznaczone do t³umaczenia i przedstawia w ³atwym w obs³udze oknie.
503 Gdy jeden z nich jest ju¿ przet³umaczony, automatycznie przechodzi do
504 nastêpnego, a¿ wszystkie bêd± przet³umaczone.
507 Summary: Qt makefile generator
508 Summary(pl): Generator plików makefile dla aplikacji Qt
509 Group: X11/Development/Tools
511 %description -n qmake
512 A powerful makefile generator. It can create makefiles on any platform
513 from a simple .pro definitions file.
515 %description -n qmake -l pl
516 Rozbudowany generator plików makefile. Potrafi tworzyæ pliki makefile
517 na ka¿dej platformi na podstawie ³atwego w przygotowaniu pliku .pro.
520 Summary: Qt widgets configuration tool
521 Summary(pl): Narzêdzie do konfigurowania widgetów Qt
522 Group: X11/Applications
524 %description -n qtconfig
525 A tool for configuring look and behavior of Qt widgets.
527 %description -n qtconfig -l pl
528 Narzêdie do konfiguracji wygl±du i zachowania widgetów Qt.
531 Summary: Qt Virtual framebuffer
532 Summary(pl): Wirtualny framebuffer dla Qt
533 Group: X11/Development/Libraries
536 Qt Virtual framebuffer allows you to run Qt/Embedded applications in
539 %description -n qvfb -l pl
540 Qt Virtual framebuffer pozwala na uruchamianie aplikacji Qt/Embedded
544 Summary: Demos of new Qt4 features
545 Summary(pl): Programy demonstruj±ce nowe mo¿liwo¶ci Qt4
546 Group: X11/Development/Libraries
547 Requires: QtCore = %{epoch}:%{version}-%{release}
548 Requires: QtXml = %{epoch}:%{version}-%{release}
551 Demos are spiders that fly.
553 %description demos -l pl
554 Dema to lataj±ce paj±ki.
557 Summary: Qt Documentation in HTML format
558 Summary(pl): Dokumentacja Qt w formacie HTML
559 Group: X11/Development/Libraries
562 Qt documentation in HTML format.
564 %description doc -l pl
565 Dokumentacja qt w formacie HTML.
568 Summary: Qt man pages
569 Summary(pl): Qt - strony man
570 Group: X11/Development/Libraries
573 Qt documentation in man pages format.
575 %description man -l pl
576 Dokumentacja Qt w formacie stron man.
579 Summary: Example programs bundled with Qt
580 Summary(pl): Æwiczenia i przyk³ady do Qt
581 Summary(pt_BR): Programas exemplo desenvolvidos com o Qt
582 Group: X11/Development/Libraries
583 # no it does not , we cant be sure the user wants to compile them right?
584 # he might just want to take a look, anwyay no single devel package now
585 #Requires: %{name}-devel = %{epoch}:%{version}-%{release}
587 %description examples
588 Example programs bundled with Qt version.
590 %description examples -l pl
591 Æwiczenia/przyk³ady do³±czone do Qt.
593 %description examples -l pt_BR
594 Programas exemplo para o Qt versão.
597 #setup -q -n %{_name}-copy-%{_snap}
598 %setup -q -n qt-x11-opensource-src-%{version}
600 %if %{with dont_enable}
610 #cat >> patches/DISABLED <<EOF
619 # change QMAKE_CFLAGS_RELEASE to build
620 # properly optimized libs
621 plik="mkspecs/linux-g++/qmake.conf"
624 s|/usr/X11R6/lib|/usr/X11R6/%{_lib}|;
625 s|/usr/lib|%{_libdir}|;
626 s|\\(QTDIR\\)/lib|\\(QTDIR\\)/%{_lib}|;
630 |grep -v QMAKE_CFLAGS_RELEASE \
631 |grep -v QMAKE_CXXFLAGS_RELEASE \
632 |grep -v QMAKE_CFLAGS_DEBUG \
633 |grep -v QMAKE_CXXFLAGS_DEBUG \
638 echo -e "QMAKE_CFLAGS_RELEASE\t=\t%{rpmcflags}" >> $plik
639 echo -e "QMAKE_CXXFLAGS_RELEASE\t=\t%{rpmcxxflags}" >> $plik
640 echo -e "QMAKE_CFLAGS_DEBUG\t=\t%{debugcflags}" >> $plik
641 echo -e "QMAKE_CXXFLAGS_DEBUG\t=\t%{debugcflags}" >> $plik
646 if test -n "$LD_LIBRARY_PATH"; then
647 LD_LIBRARY_PATH=$QTDIR/%{_lib}:$LD_LIBRARY_PATH
649 LD_LIBRARY_PATH=$QTDIR/lib
652 if [ "%{_lib}" != "lib" ] ; then
656 # pass OPTFLAGS to build qmake itself with optimization
657 OPTFLAGS="%{rpmcflags}"
658 PATH=$QTDIR/bin:$PATH
659 QMAKESPEC=$QTDIR/mkspecs/linux-g++
662 export QTDIR YACC PATH LD_LIBRARY_PATH QMAKESPEC OPTFLAGS
665 # $1 - aditional params
667 ##################################
668 # DEFAULT OPTIONS FOR ALL BUILDS #
669 ##################################
672 -DQT_CLEAN_NAMESPACE \
676 -docdir %{_docdir}/%{name}-doc \
677 -headerdir %{_includedir}/qt4 \
680 -plugindir %{_libdir}/qt4/plugins \
681 -datadir %{_datadir}/qt4 \
682 -translationdir %{_datadir}/locale/ \
683 -sysconfdir %{_sysconfdir}/qt4 \
684 -examplesdir %{_examplesdir}/qt4 \
685 -demosdir %{_examplesdir}/qt4-demos \
687 -%{!?with_pch:no-}pch \
693 -I%{_includedir}/postgresql/server \
694 -I%{_includedir}/mysql \
695 %{!?with_cups:-no-cups} \
696 %{?with_nas:-system-nas-sound} \
697 %{?with_nvidia:-dlopen-opengl} \
715 %{__make} sub-src-all-ordered
719 ##################################
720 # STATIC MULTI-THREAD #
721 ##################################
723 %if %{with static_libs}
725 %{?with_mysql:-qt-sql-mysql} \
726 %{?with_odbc:-qt-sql-odbc} \
727 %{?with_pgsql:-qt-sql-psql} \
728 %{?with_sqlite3:-qt-sql-sqlite} \
729 %{?with_sqlite:-qt-sql-sqlite2} \
730 %{?with_ibase:-qt-sql-ibase} \
736 ##################################
737 # SHARED MULTI-THREAD #
738 ##################################
741 %{?with_mysql:-plugin-sql-mysql} \
742 %{?with_odbc:-plugin-sql-odbc} \
743 %{?with_pgsql:-plugin-sql-psql} \
744 %{?with_sqlite3:-plugin-sql-sqlite} \
745 %{?with_sqlite:-plugin-sql-sqlite2} \
746 %{?with_ibase:-plugin-sql-ibase}"
750 sub-tools-all-ordered \
751 sub-demos-all-ordered \
752 sub-examples-all-ordered
756 # Check for "with" conditions befor build
758 # Find out why and fix the reason of building only mysql sqldriver
759 # (it is not installed either)
761 for dir in src/plugins/sqldrivers/{ibase,odbc,psql,sqlite,sqlite2}
768 %if %{with dont_enable}
770 cd tools/designer/designer
771 lrelease designer_de.ts
772 lrelease designer_fr.ts
774 cd $QTDIR/tools/assistant
775 lrelease assistant_de.ts
776 lrelease assistant_fr.ts
777 cd $QTDIR/tools/linguist/linguist
778 lrelease linguist_de.ts
779 lrelease linguist_fr.ts
784 rm -rf $RPM_BUILD_ROOT
790 INSTALL_ROOT=$RPM_BUILD_ROOT
793 $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}} \
794 $RPM_BUILD_ROOT%{_libdir}/qt4/plugins/{crypto,network}
796 install plugins/sqldrivers/* $RPM_BUILD_ROOT%{_libdir}/qt4/plugins/sqldrivers
797 install bin/findtr tools/qvfb/qvfb $RPM_BUILD_ROOT%{_bindir}
799 install %{SOURCE2} $RPM_BUILD_ROOT%{_desktopdir}
800 install %{SOURCE4} $RPM_BUILD_ROOT%{_desktopdir}
802 install tools/qtconfig/images/appicon.png \
803 $RPM_BUILD_ROOT%{_pixmapsdir}/qtconfig.png
805 install tools/linguist/linguist/images/appicon.png \
806 $RPM_BUILD_ROOT%{_pixmapsdir}/linguist.png
808 install tools/assistant/images/assistant.png \
809 $RPM_BUILD_ROOT%{_pixmapsdir}/assistant.png
812 install tools/designer/src/designer/images/designer.png \
813 $RPM_BUILD_ROOT%{_pixmapsdir}/designer.png
816 %if %{with static_libs}
817 install %{_lib}/*Qt*.a $RPM_BUILD_ROOT%{_libdir}
821 install %{SOURCE3} $RPM_BUILD_ROOT%{_desktopdir}/designer.desktop
822 install %{SOURCE5} $RPM_BUILD_ROOT%{_desktopdir}
825 %if %{with dont_enable}
826 install -d $RPM_BUILD_ROOT%{_datadir}/locale/{ar,de,fr,ru,he,cs,sk}/LC_MESSAGES
827 install translations/qt_ar.qm $RPM_BUILD_ROOT%{_datadir}/locale/ar/LC_MESSAGES/qt.qm
828 install translations/qt_de.qm $RPM_BUILD_ROOT%{_datadir}/locale/de/LC_MESSAGES/qt.qm
829 install translations/qt_fr.qm $RPM_BUILD_ROOT%{_datadir}/locale/fr/LC_MESSAGES/qt.qm
830 install translations/qt_ru.qm $RPM_BUILD_ROOT%{_datadir}/locale/ru/LC_MESSAGES/qt.qm
831 install translations/qt_iw.qm $RPM_BUILD_ROOT%{_datadir}/locale/he/LC_MESSAGES/qt.qm
832 install translations/qt_cs.qm $RPM_BUILD_ROOT%{_datadir}/locale/cs/LC_MESSAGES/qt.qm
833 install translations/qt_sk.qm $RPM_BUILD_ROOT%{_datadir}/locale/sk/LC_MESSAGES/qt.qm
836 install tools/designer/designer/designer_de.qm $RPM_BUILD_ROOT%{_datadir}/locale/de/LC_MESSAGES/designer.qm
837 install tools/designer/designer/designer_fr.qm $RPM_BUILD_ROOT%{_datadir}/locale/fr/LC_MESSAGES/designer.qm
840 install tools/assistant/assistant_de.qm $RPM_BUILD_ROOT%{_datadir}/locale/de/LC_MESSAGES/assistant.qm
841 install tools/assistant/assistant_fr.qm $RPM_BUILD_ROOT%{_datadir}/locale/fr/LC_MESSAGES/assistant.qm
843 install tools/linguist/linguist/linguist_de.qm $RPM_BUILD_ROOT%{_datadir}/locale/de/LC_MESSAGES/linguist.qm
844 install tools/linguist/linguist/linguist_fr.qm $RPM_BUILD_ROOT%{_datadir}/locale/fr/LC_MESSAGES/linguist.qm
847 cd $RPM_BUILD_ROOT%{_includedir}/qt4/Qt
848 for f in ../Qt{3Support,Core,Gui,Network,OpenGL,Sql,Xml,Designer}/*
851 ln -sf $f `basename $f`
854 ln -sf ../../QtCore/arch/qatomic.h arch/qatomic.h
857 for f in $RPM_BUILD_ROOT%{_pkgconfigdir}/*.pc; do
858 HAVEDEBUG=`echo $f | grep _debug | wc -l`
859 MODULE=`echo $f | basename $f | cut -d. -f1 | cut -d_ -f1`
860 MODULE2=`echo $MODULE | tr a-z A-Z | sed s:QT::`
863 if [ "$MODULE2" == "3SUPPORT" ]; then
864 DEFS="$DEFS -DQT3_SUPPORT -DQT_QT3SUPPORT_LIB"
866 DEFS="$DEFS -DQT_"$MODULE2"_LIB"
868 [ "$HAVEDEBUG" -eq 0 ] && DEFS="$DEFS -DQT_NO_DEBUG"
870 sed -i -e s:-L`pwd`/lib::g $f
871 sed -i -e "s:-I\${includedir}:-I\${includedir}\ -I\${includedir}/$MODULE -I%{_datadir}/qt4/mkspec/default:" $f
872 sed -i -e "s:-DQT_SHARED:-DQT_SHARED $DEFS:" $f
875 # Prepare some files list
877 RESULT=`echo $RPM_BUILD_ROOT$2 2>/dev/null`
878 [ "$RESULT" == "" ] && return
879 r=`echo $RESULT | awk '{ print $1 }'`
882 echo "%%dir $2" >> $1.files
883 elif [ -x "$r" ] ; then
884 echo "%%attr(755,root,root) $2" >> $1.files
885 elif [ -f "$r" ]; then
886 echo "$2" >> $1.files
888 echo "Error generation devel files list!"
889 echo "$r: no such file or direcotry!"
896 echo "%%defattr(644,root,root,755)" > $MODULE-devel.files
897 ifecho $MODULE-devel "%{_libdir}/lib$MODULE*.so"
898 ifecho $MODULE-devel "%{_libdir}/lib$MODULE*.la"
899 ifecho $MODULE-devel "%{_libdir}/lib$MODULE*.prl"
900 ifecho $MODULE-devel "%{_pkgconfigdir}/$MODULE*.pc"
901 for f in `find $RPM_BUILD_ROOT%{_includedir}/qt4/$MODULE -printf "%%P "`
903 ifecho $MODULE-devel %{_includedir}/qt4/$MODULE/$f
904 ifecho $MODULE-devel %{_includedir}/qt4/Qt/$f
906 for f in $@; do ifecho $MODULE-devel $f; done
909 mkdevfl QtCore %{_includedir}/qt4 %{_includedir}/qt4/Qt \
910 %{_libdir}/libQtAssistantClient{.prl,_debug.prl}
917 mkdevfl QtDesigner || /bin/true # there is no libQtDesigner.la file :/
919 echo "%defattr(644,root,root,755)" > examples.files
920 ifecho examples %{_examplesdir}/qt4
921 for f in `find $RPM_BUILD_ROOT%{_examplesdir}/qt4 -printf "%%P "`
923 ifecho examples %{_examplesdir}/qt4/$f
926 echo "%defattr(644,root,root,755)" > demos.files
927 ifecho demos "%{_examplesdir}/qt4-demos"
928 ifecho demos "%{_bindir}/qtdemo" >> demos.files
929 for f in `find $RPM_BUILD_ROOT%{_examplesdir}/qt4-demos -printf "%%P "`
931 ifecho demos %{_examplesdir}/qt4-demos/$f
935 rm -rf $RPM_BUILD_ROOT
940 *******************************************************
943 * With qt 4.0.0 the single threaded version was *
944 * removed. Also the library is modular now so be *
945 * sure to check that you have every module you need. *
947 *******************************************************
949 %postun -n QtCore -p /sbin/ldconfig
951 %post -n QtGui -p /sbin/ldconfig
952 %postun -n QtGui -p /sbin/ldconfig
954 %post -n QtNetwork -p /sbin/ldconfig
955 %postun -n QtNetwork -p /sbin/ldconfig
957 %post -n QtOpenGL -p /sbin/ldconfig
958 %postun -n QtOpenGL -p /sbin/ldconfig
960 %post -n QtSql -p /sbin/ldconfig
961 %postun -n QtSql -p /sbin/ldconfig
963 %post -n QtXml -p /sbin/ldconfig
964 %postun -n QtXml -p /sbin/ldconfig
966 %post -n Qt3Support -p /sbin/ldconfig
967 %postun -n Qt3Support -p /sbin/ldconfig
969 %post assistant -p /sbin/ldconfig
970 %postun assistant -p /sbin/ldconfig
972 %post designer-libs -p /sbin/ldconfig
973 %postun designer-libs -p /sbin/ldconfig
976 %defattr(644,root,root,755)
977 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size)
978 %attr(755,root,root) %{_libdir}/libQtCore*.so.*
979 %dir %{_libdir}/qt4/plugins
980 %dir %{_libdir}/qt4/plugins/codecs
981 %dir %{_libdir}/qt4/plugins/crypto
982 %dir %{_libdir}/qt4/plugins/imageformats
983 %dir %{_libdir}/qt4/plugins/network
984 %dir %{_libdir}/qt4/plugins/sqldrivers
988 %defattr(644,root,root,755)
989 %attr(755,root,root) %{_libdir}/libQtGui*.so.*
990 %{_libdir}/qt4/plugins/codecs/*
991 %{_libdir}/qt4/plugins/imageformats/*
994 %defattr(644,root,root,755)
995 %attr(755,root,root) %{_libdir}/libQtNetwork*.so.*
998 %defattr(644,root,root,755)
999 %attr(755,root,root) %{_libdir}/libQtOpenGL*.so.*
1002 %defattr(644,root,root,755)
1003 %attr(755,root,root) %{_libdir}/libQtSql*.so.*
1006 %files -n QtSql-mysql
1007 %defattr(644,root,root,755)
1008 %attr(755,root,root) %{_libdir}/qt4/plugins/sqldrivers/libqsqlmysql*.so
1012 %files -n QtSql-pgsql
1013 %defattr(644,root,root,755)
1014 %attr(755,root,root) %{_libdir}/qt4/plugins/sqldrivers/libqsqlpsql*.so
1018 %files -n QtSql-sqlite
1019 %defattr(644,root,root,755)
1020 %attr(755,root,root) %{_libdir}/qt4/plugins/sqldrivers/libqsqlite2*.so
1024 %files -n QtSql-sqlite3
1025 %defattr(644,root,root,755)
1026 %attr(755,root,root) %{_libdir}/qt4/plugins/sqldrivers/libqsqlite*.so
1030 %files -n QtSql-ibase
1031 %defattr(644,root,root,755)
1032 %attr(755,root,root) %{_libdir}/qt4/plugins/sqldrivers/libqsqlibase*.so
1036 %files -n QtSql-odbc
1037 %defattr(644,root,root,755)
1038 %attr(755,root,root) %{_libdir}/qt4/plugins/sqldrivers/libqsqlodbc*.so
1042 %defattr(644,root,root,755)
1043 %attr(755,root,root) %{_libdir}/libQtXml*.so.*
1046 %files -n Qt3Support
1047 %defattr(644,root,root,755)
1048 %attr(755,root,root) %{_bindir}/uic3
1049 %attr(755,root,root) %{_libdir}/libQt3Support*.so.*
1052 %defattr(644,root,root,755)
1053 %attr(755,root,root) %{_bindir}/assistant
1054 %attr(755,root,root) %{_libdir}/libQtAssistantClient*.so*
1055 #%lang(de) %{_datadir}/locale/de/LC_MESSAGES/assistant.qm
1056 #%lang(fr) %{_datadir}/locale/fr/LC_MESSAGES/assistant.qm
1057 %{_desktopdir}/assistant.desktop
1058 %{_pixmapsdir}/assistant.png
1061 %defattr(644,root,root,755)
1062 %attr(755,root,root) %{_bindir}/rcc
1063 %attr(755,root,root) %{_bindir}/moc
1064 %attr(755,root,root) %{_bindir}/qt3to4
1065 %attr(755,root,root) %{_bindir}/uic
1066 %{_datadir}/qt4/q3porting.xml
1068 %if %{with designer}
1069 %files designer-libs
1070 %defattr(644,root,root,755)
1071 %attr(755,root,root) %{_libdir}/libQtDesigner*.so.*.*.*
1072 %attr(755,root,root) %{_libdir}/qt4/plugins/designer/*.so
1075 %defattr(644,root,root,755)
1076 %attr(755,root,root) %{_bindir}/designer
1077 #%dir %{_libdir}/%{name}/plugins-?t/designer
1078 #%lang(de) %{_datadir}/locale/de/LC_MESSAGES/designer.qm
1079 #%lang(fr) %{_datadir}/locale/fr/LC_MESSAGES/designer.qm
1080 %{_desktopdir}/designer.desktop
1081 %{_pixmapsdir}/designer.png
1085 %defattr(644,root,root,755)
1086 %attr(755,root,root) %{_bindir}/linguist
1087 %attr(755,root,root) %{_bindir}/findtr
1088 %attr(755,root,root) %{_bindir}/lrelease
1089 %attr(755,root,root) %{_bindir}/lupdate
1090 %attr(755,root,root) %{_bindir}/qm2ts
1091 #%lang(de) %{_datadir}/locale/de/LC_MESSAGES/linguist.qm
1092 #%lang(fr) %{_datadir}/locale/fr/LC_MESSAGES/linguist.qm
1093 #%{_mandir}/man1/qm2ts.1*
1094 #%{_mandir}/man1/lupdate*.1*
1095 #%{_mandir}/man1/lrelease*.1*
1096 %{_datadir}/qt4/phrasebooks
1097 %{_desktopdir}/linguist.desktop
1098 %{_pixmapsdir}/linguist.png
1101 %defattr(644,root,root,755)
1102 %attr(755,root,root) %{_bindir}/qmake
1103 %{_datadir}/qt4/mkspecs
1106 %defattr(644,root,root,755)
1107 %attr(755,root,root) %{_bindir}/qtconfig
1108 %{_desktopdir}/qtconfig.desktop
1109 %{_pixmapsdir}/qtconfig.png
1112 %defattr(644,root,root,755)
1113 %attr(755,root,root) %{_bindir}/qvfb
1116 %defattr(644,root,root,755)
1117 %{_docdir}/%{name}-doc
1119 %files -n QtCore-devel -f QtCore-devel.files
1120 %files -n QtDesigner-devel -f QtDesigner-devel.files
1121 %files -n QtGui-devel -f QtGui-devel.files
1122 %files -n QtNetwork-devel -f QtNetwork-devel.files
1123 %files -n QtOpenGL-devel -f QtOpenGL-devel.files
1124 %files -n QtSql-devel -f QtSql-devel.files
1125 %files -n QtXml-devel -f QtXml-devel.files
1126 %files -n Qt3Support-devel -f Qt3Support-devel.files
1128 %files demos -f demos.files
1129 %files examples -f examples.files