qt/qt.spec

Sun, 29 May 2011 12:16:43 +0200

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Sun, 29 May 2011 12:16:43 +0200
changeset 341
24888fe4de94
parent 340
870131689a5c
child 342
90f1326e8f73
permissions
-rw-r--r--

Make a second cut at needed corrections for upgrade to version 4.7.3.

michael@1 1 ##
michael@1 2 ## qt.spec -- OpenPKG RPM Specification
michael@257 3 ## Copyright (c) 2010 Michael Schloh von Bennewitz <michael@schloh.com>
michael@1 4 ##
michael@1 5 ## Permission to use, copy, modify, and distribute this software for
michael@1 6 ## any purpose with or without fee is hereby granted, provided that
michael@1 7 ## the above copyright notice and this permission notice appear in all
michael@1 8 ## copies.
michael@1 9 ##
michael@1 10 ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
michael@1 11 ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
michael@1 12 ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
michael@1 13 ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
michael@1 14 ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
michael@1 15 ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
michael@1 16 ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
michael@1 17 ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
michael@1 18 ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
michael@1 19 ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
michael@1 20 ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
michael@1 21 ## SUCH DAMAGE.
michael@1 22 ##
michael@1 23
michael@86 24 # FIXME: MSvB: It appears that bugs in current versions of binutils
michael@86 25 # FIXME: MSvB: fail to properly link Qt object code, resulting in
michael@86 26 # FIXME: MSvB: 'ld: libQt*.so: pthread_mutex...: invalid version 6
michael@86 27 # FIXME: MSvB: libQt*.so: could not read symbols: Bad value'
michael@86 28 # FIXME: MSvB: The effects of these bugs are platform dependent.
michael@86 29 # FIXME: MSvB: Solaris 11 IA-32 builds fail while Linux 2.6.25.18
michael@86 30 # FIXME: MSvB: AMD64 builds succeed.
michael@1 31
michael@1 32 # package information
michael@1 33 Name: qt
michael@213 34 Summary: Cross Platform Application Framework
michael@1 35 URL: http://www.trolltech.com/products/qt/
michael@1 36 Vendor: Nokia Corporation
michael@1 37 Packager: Michael Schloh von Bennewitz
michael@1 38 Distribution: MSvB Recherche Production
michael@1 39 Class: EVAL
michael@1 40 Group: Development
michael@1 41 License: GPL
michael@340 42 Version: 4.7.3
michael@340 43 Release: 20110514
michael@1 44
michael@1 45 # build options
michael@1 46 %option with_tools yes
michael@288 47 %option with_glib no
michael@65 48 %option with_mysql no
michael@65 49 %option with_pgsql no
michael@1 50 %option with_shared no
michael@1 51 %option with_examples no
michael@1 52
michael@1 53 # list of sources
michael@257 54 Source0: ftp://ftp.qt.nokia.com/qt/source/qt-everywhere-opensource-src-%{version}.tar.gz
michael@1 55
michael@1 56 # build information
michael@1 57 Prefix: %{l_prefix}
michael@1 58 BuildRoot: %{l_buildroot}
michael@4 59 BuildPreReq: OpenPKG, openpkg >= 20050726, make, gcc, pkgconfig
michael@1 60 PreReq: OpenPKG, openpkg >= 20050726
michael@1 61 BuildPreReq: X11, png, mng, jpeg, tiff, mesa, xrender
michael@1 62 PreReq: X11, png, mng, jpeg, tiff, mesa, xrender
michael@3 63 BuildPreReq: openssl, zlib, libiconv, sqlite, dbus
michael@3 64 PreReq: openssl, zlib, libiconv, sqlite, dbus
michael@1 65 BuildPreReq: fontconfig, freetype
michael@1 66 PreReq: fontconfig, freetype
michael@288 67 %if "%{with_glib}" == "yes"
michael@288 68 BuildPreReq: glib2
michael@288 69 PreReq: glib2
michael@288 70 %endif
michael@65 71 %if "%{with_mysql}" == "yes"
michael@65 72 BuildPreReq: mysql
michael@65 73 PreReq: mysql
michael@65 74 %endif
michael@65 75 %if "%{with_pgsql}" == "yes"
michael@65 76 BuildPreReq: postgresql
michael@65 77 PreReq: postgresql
michael@65 78 %endif
michael@1 79 AutoReq: no
michael@1 80 AutoReqProv: no
michael@1 81 Provides: QTSDK
michael@1 82
michael@1 83 %description
michael@3 84 Qt is a comprehensive C++ framework for cross-platform application
michael@341 85 development. It plays the role of a widget toolkit in facilitating
michael@341 86 the development of software with a graphical user interface, however
michael@341 87 Qt is useful for developing command line tools and consoles for
michael@341 88 servers as well.
michael@1 89
michael@1 90 %track
michael@1 91 prog qt = {
michael@1 92 version = %{version}
michael@263 93 url = ftp://ftp.qt.nokia.com/qt/source/
michael@257 94 regex = qt-everywhere-opensource-src-(__VER__)\.tar\.gz
michael@1 95 }
michael@1 96
michael@1 97 %prep
michael@1 98 # announce exceptional build requirements
michael@257 99 ( echo "This package has exceptional build requirements:"
michael@341 100 echo " qt-%{version}-root (5 Go)"
michael@341 101 echo " qt-everywhere-opensource-src-%{version} (6 Go)"
michael@263 102 echo " qt-%{version}-<date>.<arch>-<os>-<tag>.rpm (2 Go)"
michael@341 103 echo "Building with no options takes 3,0 hours on a dual core"
michael@341 104 echo "2 GHz CPU, or 7 hours with all build options enabled."
michael@1 105 ) | %{l_rpmtool} msg -b -t notice
michael@1 106
michael@257 107 %setup -q -n qt-everywhere-opensource-src-%{version}
michael@1 108 x11_incdir=`%{l_rc} --query x11_incdir`
michael@1 109 x11_libdir=`%{l_rc} --query x11_libdir`
michael@92 110 fontconflibs=`%{l_prefix}/bin/pkg-config --libs-only-l --static fontconfig`
michael@257 111 lcmslibs=`%{l_prefix}/bin/pkg-config --libs-only-l --static lcms`
michael@92 112 openssllibs=`%{l_prefix}/bin/pkg-config --libs --static openssl`
michael@288 113 mysqllibs=`%{l_prefix}/bin/mysql_config --libs`
michael@92 114
michael@340 115 # MSvB In R/D: loclibs=''
michael@340 116 # MSvB In R/D: case "%{l_platform -t}" in
michael@340 117 # MSvB In R/D: *-sunos* )
michael@340 118 # MSvB In R/D: loclibs='-lsocket -lnsl'
michael@340 119 # MSvB In R/D: ;;
michael@340 120 # MSvB In R/D: esac
michael@1 121 ( cd mkspecs/qws
michael@1 122 for plat in freebsd-generic-g++ macx-generic-g++ solaris-generic-g++;
michael@266 123 do
michael@1 124 ln -s $plat `echo $plat | %{l_shtool} subst -e 's;\(.*\)-generic-\(.*\);\1-x86-\2;'`
michael@1 125 done
michael@1 126 ) || exit $?
michael@1 127 %{l_shtool} subst \
michael@92 128 -e 's;\(-z[\t ][\t ]*\)\([^\t \"][^\t \"]*\);\1"\2";g' \
michael@1 129 configure
michael@1 130 %{l_shtool} subst \
michael@263 131 -e 's;\(RPATH_FLAGS\)=.*\$QT_INSTALL_LIBS.*\(\$RPATH_FLAGS\)";\1="%{l_prefix}/lib/qt/dynamic \2";' \
michael@264 132 -e 's;\(QMAKE_RPATHDIR +=\) \\"\$QT_INSTALL_LIBS\\";\1 %{l_prefix}/lib/qt/dynamic;' \
michael@263 133 configure
michael@263 134 %{l_shtool} subst \
michael@288 135 -e "s;\(OPENSSL_LIBS *=\) *-lssl -lcrypto;\1 $openssllibs;" \
michael@92 136 configure
michael@92 137 %{l_shtool} subst \
michael@288 138 -e 's; *QMakeVar set QMAKE_CFLAGS_X11.*QT_CFLAGS_FONTCONFIG.*;;' \
michael@288 139 configure
michael@288 140 # yes this is needed several times to catch nested occurences of '--libs'
michael@288 141 %{l_shtool} subst \
michael@288 142 -e 's;\(QT_LIBS_FONTCONFIG *=.*PKG_CONFIG.*\) --libs ;\1 --libs-only-L ;g' \
michael@288 143 -e 's;\(QT_LIBS_FONTCONFIG *=.*PKG_CONFIG.*\) --libs ;\1 --libs-only-L ;g' \
michael@1 144 configure
michael@257 145 # yes this is needed several times to catch nested occurences of '--cflags'
michael@257 146 %{l_shtool} subst \
michael@257 147 -e 's;\(QT_CFLAGS_[^=][^=]*=.*PKG_CONFIG.*\) --cflags ;\1 --cflags-only-other ;g' \
michael@257 148 -e 's;\(QT_CFLAGS_[^=][^=]*=.*PKG_CONFIG.*\) --cflags ;\1 --cflags-only-other ;g' \
michael@257 149 configure
michael@340 150 # Trolltech Bug:
michael@340 151 # Glib support cannot be enabled due to functionality tests!
michael@340 152 # Turn on verbose messaging (-v) to ./configure to see the final report.
michael@340 153 # Trolltech Bug:
michael@340 154 # In file included from ../../include/QtGui/private/qgtkstyle_p.h:1,
michael@340 155 # from kernel/qguiplatformplugin.cpp:63:
michael@340 156 # ....../qgtkstyle_p.h:69:21: error: gtk/gtk.h: No such file or directory
michael@340 157 # Workaround resolution:
michael@288 158 # hack to get back the standard '--cflags' of just Qt_CFLAGS_GLIB
michael@340 159 # Question: Is this needed? QT_LIBS_QGTKSTYLE=`$PKG_CONFIG --libs gobject-2.0 2>/dev/null`
michael@288 160 %{l_shtool} subst \
michael@288 161 -e 's;\(QT_CFLAGS_GLIB *=.*PKG_CONFIG.*\) --cflags-only-other ;\1 --cflags ;g' \
michael@340 162 -e 's;\(QT_CFLAGS_QGTKSTYLE *=.*PKG_CONFIG.*\) --cflags-only-other ;\1 --cflags ;g' \
michael@288 163 configure
michael@340 164 # MSvB In R/D: %{l_shtool} subst \
michael@340 165 # MSvB In R/D: -e 's;\(TRY_INCLUDEPATHS = \).*\(\$\$INCLUDEPATH\);\1\2;' \
michael@340 166 # MSvB In R/D: -e 's;/freetype2;/freetype;' \
michael@340 167 # MSvB In R/D: config.tests/unix/freetype/freetype.pri
michael@340 168 # Trolltech Bug:
michael@340 169 # /opdv/lib/libmng.a(libmng_cms.o): In function `mnglcms_initlibrary':
michael@340 170 # libmng_cms.c:(.text+0xa): undefined reference to `cmsErrorAction'
michael@1 171 %{l_shtool} subst \
michael@257 172 -e "s;\(LIBS.*=.*-lmng\);\1 $lcmslibs;" \
michael@257 173 src/gui/image/qmnghandler.pri
michael@340 174 # Trolltech Bug:
michael@340 175 # lib/libQtGui.a(qapplication_x11.o): In function
michael@340 176 # `qt_init(QApplicationPrivate*, int, _XDisplay*, unsigned long, unsigned long)':
michael@340 177 # qapplication_x11.cpp:(.text+0xec8d): undefined reference to `FcInit'
michael@257 178 %{l_shtool} subst \
michael@92 179 -e "s;^\(LIBS += \)-lfreetype -lfontconfig;\1$fontconflibs;" \
michael@1 180 config.tests/x11/fontconfig/fontconfig.pro
michael@340 181 echo "LIBS += `%{l_prefix}/bin/pkg-config --libs-only-L fontconfig`" \
michael@340 182 >>tools/linguist/linguist/linguist.pro
michael@213 183 echo 'INCLUDEPATH += /usr/include/wacomcfg' \
michael@213 184 >>src/gui/kernel/x11.pri
michael@257 185 echo "contains(QT_CONFIG, fontconfig) { LIBS += $fontconflibs }" \
michael@257 186 >>src/gui/kernel/x11.pri
michael@257 187 echo "contains(QT_CONFIG, fontconfig) { LIBS += $fontconflibs }" \
michael@257 188 >>src/gui/text/text.pri
michael@340 189 # Trolltech Bug:
michael@340 190 # The QtDBus module cannot be enabled because libdbus-1 version 0.93 was not found.
michael@340 191 # Turn on verbose messaging (-v) to ./configure to see the final report.
michael@257 192 echo "INCLUDEPATH = `%{l_prefix}/bin/pkg-config --cflags-only-I dbus-1 | %{l_shtool} subst -e 's;\-I;;g'`" \
michael@257 193 >>config.tests/unix/dbus/dbus.pro
michael@257 194 echo "LIBS = `%{l_prefix}/bin/pkg-config --libs-only-l --static dbus-1`" \
michael@257 195 >>config.tests/unix/dbus/dbus.pro
michael@340 196 # Trolltech Bug:
michael@340 197 # PostgreSQL support cannot be enabled due to functionality tests!
michael@340 198 # Turn on verbose messaging (-v) to ./configure to see the final report.
michael@1 199 %{l_shtool} subst \
michael@257 200 -e "s;\(LIBS.*= -lpq\);\1 `%{l_prefix}/bin/pg_config --libs` $loclibs;" \
michael@1 201 config.tests/unix/psql/psql.pro
michael@340 202 # Trolltech Bug:
michael@340 203 # Iconv support cannot be enabled due to functionality tests!
michael@340 204 # Turn on verbose messaging (-v) to ./configure to see the final report.
michael@1 205 %{l_shtool} subst \
michael@257 206 -e 's;^mac[^:][^:]*:\(LIBS\);\1;' \
michael@1 207 config.tests/unix/iconv/iconv.pro
michael@341 208 # Trolltech Bug:
michael@341 209 # Missing libmng test! Parts (src/gui/image/qmnghandler.cpp) use
michael@341 210 # such libmng methods as mng_create(3), mng_putchunk_term(3)...
michael@341 211 # These are only optional parts of typical MNG implementations.
michael@341 212 # Questions surround whether the MNG standard [1] requires these
michael@341 213 # API methods in their expected form, or if this alone is excuse
michael@341 214 # enough for neglecting such build time configuration.
michael@341 215 # [1] http://www.libpng.org/pub/mng/spec/
michael@341 216 # A work around is to force integration of Qt 3rdparty embedded
michael@341 217 # MNG logic, thus weakening the loosely coupled nature of Qt
michael@341 218 # components and potentially affecting security.
michael@340 219 # MSvB In R/D: uiclibs=`%{l_prefix}/bin/pkg-config --libs-only-l --static fontconfig lcms`
michael@340 220 # MSvB In R/D: %{l_shtool} subst \
michael@340 221 # MSvB In R/D: -e 's;LIBS .*= -lpq$;LIBS += -lpq -lssl -lcrypto;' \
michael@340 222 # MSvB In R/D: -e "s;LIBS .*= \$\$QT_LFLAGS_MYSQL;LIBS += $mysqllibs;" \
michael@340 223 # MSvB In R/D: src/sql/drivers/drivers.pri
michael@340 224 # MSvB In R/D: %{l_shtool} subst \
michael@340 225 # MSvB In R/D: -e "s;QMAKE_CXXFLAGS += \$\$QT_CFLAGS_GLIB;INCPATH += `pkg-config --cflags-only-I glib-2.0 gthread-2.0 2>/dev/null | %{l_shtool} subst -e 's;-I;;g'`;g" \
michael@340 226 # MSvB In R/D: src/corelib/kernel/kernel.pri \
michael@340 227 # MSvB In R/D: src/gui/kernel/kernel.pri
michael@340 228 # MSvB In R/D: %{l_shtool} subst \
michael@340 229 # MSvB In R/D: -e "s;QMAKE_CXXFLAGS \*= \$\$QT_CFLAGS_PSQL;INCPATH += `pg_config --includedir 2>/dev/null | %{l_shtool} subst -e 's;-I;;g'`;g" \
michael@340 230 # MSvB In R/D: -e "s;QMAKE_CXXFLAGS \*= \$\$QT_CFLAGS_MYSQL;INCPATH += `mysql_config --include 2>/dev/null | %{l_shtool} subst -e 's;-I;;g'`;g" \
michael@340 231 # MSvB In R/D: -e "s;QMAKE_CXXFLAGS \*= \$\$QT_CFLAGS_SQLITE;INCPATH += `pkg-config --cflags-only-I sqlite3 2>/dev/null | %{l_shtool} subst -e 's;-I;;g'`;g" \
michael@340 232 # MSvB In R/D: -e 's;!static:\(!isEmpty(QT_LFLAGS_PSQL)\);\1;' \
michael@340 233 # MSvB In R/D: -e 's;!static:\(LIBS \*= \$\$QT_LFLAGS_PSQL\);\1;' \
michael@340 234 # MSvB In R/D: src/plugins/sqldrivers/mysql/mysql.pro \
michael@340 235 # MSvB In R/D: src/plugins/sqldrivers/psql/psql.pro \
michael@340 236 # MSvB In R/D: src/plugins/sqldrivers/sqlite/sqlite.pro \
michael@340 237 # MSvB In R/D: src/sql/drivers/drivers.pri
michael@340 238 # Trolltech Bug:
michael@340 239 # In file included from qdbusconnectioninterface.cpp:52:0:
michael@340 240 # qdbus_symbols_p.h:58:23: fatal error: dbus/dbus.h: No such file or directoryIn
michael@340 241 # file included from qdbusconnection_p.h:70:0, from qdbusconnection.cpp:51:
michael@86 242 %{l_shtool} subst \
michael@86 243 -e "s;QMAKE_CXXFLAGS += \$\$QT_CFLAGS_DBUS;INCPATH += `pkg-config --cflags-only-I dbus-1 2>/dev/null | %{l_shtool} subst -e 's;-I;;g'`;g" \
michael@86 244 src/dbus/dbus.pro
michael@340 245 # Trolltech Bug:
michael@340 246 # All the OpenGL functionality tests failed!
michael@340 247 # You might need to modify the include and library search paths by
michael@340 248 # editing QMAKE_INCDIR_OPENGL, QMAKE_LIBDIR_OPENGL and QMAKE_LIBS_OPENGL in
michael@340 249 # /home/mschloh/opwrk/tmp/qt-everywhere-opensource-src-4.7.3/mkspecs/linux-g++-64.
michael@86 250 %{l_shtool} subst \
michael@1 251 -e 's;^\(QMAKE_INCDIR[^a-zA-Z0-9=]*=\).*;\1 %{l_prefix}/include;' \
michael@263 252 -e 's;^\(QMAKE_LIBDIR[^a-zA-Z0-9=]*=\).*;\1;' \
michael@340 253 -e 's;^\(QMAKE_INCDIR_OPENGL[^=]*=\) *\(.*\);\1 %{l_prefix}/include \2;' \
michael@340 254 -e 's;^\(QMAKE_LIBDIR_OPENGL[^=]*=\) *\(.*\);\1 %{l_prefix}/lib \2;' \
michael@1 255 -e 's;^\(QMAKE_LFLAGS_RELEASE.*\);\1 -s;' \
michael@1 256 mkspecs/qws/*/qmake.conf \
michael@1 257 mkspecs/*/*.conf
michael@340 258 # MSvB In R/D: %{l_shtool} subst \
michael@340 259 # MSvB In R/D: -e 's;^\(QMAKE_LIBS +=.*\);\1 -liconv;' \
michael@340 260 # MSvB In R/D: src/corelib/corelib.pro
michael@340 261 # Trolltech Bug:
michael@340 262 # In file included from ../JavaScriptCore/runtime/RegExp.h:29:0,
michael@340 263 # ../JavaScriptCore/yarr/RegexJIT.h: In destructor 'JSC::Yarr::RegexCodeBlock::~RegexCodeBlock()':
michael@340 264 # ../JavaScriptCore/yarr/RegexJIT.h:63:36: error: 'jsRegExpFree' was not declared in this scope
michael@3 265 %{l_shtool} subst \
michael@266 266 -e 's;\(DESTDIR *=\) *\$\$JAVASCRIPTCORE_DESTDIR;\1 $$QMAKE_LIBDIR_QT;' \
michael@266 267 src/3rdparty/webkit/JavaScriptCore/JavaScriptCore.pro
michael@340 268 # Trolltech Bug:
michael@340 269 # In file included from ../JavaScriptCore/runtime/RegExp.h:29:0,
michael@340 270 # ../JavaScriptCore/yarr/RegexJIT.h: In destructor 'JSC::Yarr::RegexCodeBlock::~RegexCodeBlock()':
michael@340 271 # ../JavaScriptCore/yarr/RegexJIT.h:63:36: error: 'jsRegExpFree' was not declared in this scope
michael@266 272 %{l_shtool} subst \
michael@266 273 -e 's;\(pathToJavaScriptCoreOutput *=\) *\$\$ARGS/\$\$JAVASCRIPTCORE_DESTDIR;\1 $$QMAKE_LIBDIR_QT;g' \
michael@266 274 src/3rdparty/webkit/JavaScriptCore/JavaScriptCore.pri
michael@340 275 # MSvB In R/D: %{l_shtool} subst \
michael@340 276 # MSvB In R/D: -e "s;^\(QMAKE_INCDIR_X11[^=]*=\).*;\1 %{l_prefix}/include $x11_incdir;" \
michael@340 277 # MSvB In R/D: -e "s;^\(QMAKE_LIBDIR_X11[^=]*=\).*;\1 %{l_prefix}/lib $x11_libdir;" \
michael@340 278 # MSvB In R/D: mkspecs/qws/solaris*/qmake.conf \
michael@340 279 # MSvB In R/D: mkspecs/solaris*/qmake.conf
michael@340 280 # MSvB In R/D: echo "QMAKE_LIBDIR += %{l_prefix}/lib/qt/dynamic" \
michael@340 281 # MSvB In R/D: >>mkspecs/features/shared.prf
michael@340 282 # MSvB In R/D: %{l_shtool} subst \
michael@340 283 # MSvB In R/D: -e 's; *\.\./3rdparty/freetype/.*;;g' \
michael@340 284 # MSvB In R/D: -e 's;^\( *contains(QT_CONFIG, freetype) {\);\1 LIBS += -lfreetype;' \
michael@340 285 # MSvB In R/D: src/gui/text/text.pri
michael@340 286 # Trolltech Bug:
michael@340 287 # image/qtiffhandler.cpp:48:20: fatal error: tiffio.h: No such file or directory
michael@340 288 # compilation terminated.
michael@340 289 # make[1]: *** [.obj/release-static/qtiffhandler.o] Error 1
michael@1 290 %{l_shtool} subst \
michael@1 291 -e 's;\(#include *"\)\(tiffio.h"\);\1tiff/\2;' \
michael@257 292 src/gui/image/qtiffhandler.cpp
michael@340 293 # MSvB In R/D: %{l_shtool} subst \
michael@340 294 # MSvB In R/D: -e 's;\(CONFIG[\t ]*+=[\t ]*qt\);\1 x11;' \
michael@340 295 # MSvB In R/D: tools/qtconfig/qtconfig.pro
michael@340 296 # MSvB In R/D: %{l_shtool} subst \
michael@340 297 # MSvB In R/D: -e 's;webkit;web-broken-kit;g' \
michael@340 298 # MSvB In R/D: tools/assistant/tools/assistant/assistant.pro
michael@340 299 # MSvB In R/D: echo "DEFINES += QT_NO_WEBKIT" \
michael@340 300 # MSvB In R/D: >>tools/assistant/tools/assistant/assistant.pro
michael@340 301 # MSvB In R/D: %{l_shtool} subst \
michael@341 302 # MSvB In R/D: -e 's;Qt.s Classes;All Classes;' \
michael@340 303 # MSvB In R/D: tools/assistant/tools/assistant/doc/assistant.qdoc \
michael@340 304 # MSvB In R/D: tools/qdoc3/doc/qdoc-manual.qdoc \
michael@340 305 # MSvB In R/D: tools/qdoc3/doc/files/qt.qdocconf \
michael@340 306 # MSvB In R/D: tools/qdoc3/test/qt-build-docs.qdocconf \
michael@340 307 # MSvB In R/D: tools/qdoc3/test/qt.qdocconf
michael@1 308
michael@1 309 %build
michael@1 310 # protect against sloppy code inclusion of all unused subprojects
michael@340 311 # MSvB In R/D: ce-compat clucene des easing harfbuzz javascriptcore md4 md5 s60 sha1 webkit xorg zlib_dependency.pri
michael@257 312 (cd src/3rdparty && rm -rf [^cdehjmswxz]* sql* win* zlib zlib.pri) || exit $?
michael@1 313
michael@92 314 # detect which platform for which to build
michael@1 315 case "%{l_platform -t}" in
michael@86 316 sun4[uv]-sunos* | amd64-sunos* ) platcomp="solaris-g++-64" ;;
michael@86 317 i?86-sunos* ) platcomp="solaris-g++" ;;
michael@86 318 amd64-linux* ) platcomp="linux-g++-64" ;;
michael@86 319 i?86-linux* ) platcomp="linux-g++" ;;
michael@86 320 amd64-freebsd* | i?86-freebsd* ) platcomp="freebsd-g++" ;;
michael@86 321 *-aix* ) platcomp="aix-g++" ;;
michael@86 322 *-darwin* ) platcomp="macx-g++" ;;
michael@86 323 *-hpux* ) platcomp="hpux-g++" ;;
michael@86 324 *-irix* ) platcomp="irix-g++" ;;
michael@86 325 * ) echo "Platform '%{l_platform -t}' is not supported." 2>&1; exit 1 ;;
michael@1 326 esac
michael@1 327
michael@92 328 # detect which architecture extensions are available
michael@92 329 archflags=''
michael@92 330 case "%{l_platform -t}" in
michael@92 331 amd64-* )
michael@92 332 break
michael@92 333 ;;
michael@92 334 * )
michael@92 335 archflags='-no-sse2 -no-3dnow'
michael@92 336 ;;
michael@92 337 esac
michael@92 338
michael@1 339 %if "%{with_shared}" == "yes"
michael@1 340 # optional shared build (precedes mandatory static build)
michael@1 341 echo 'yes' | ./configure \
michael@92 342 $archflags \
michael@205 343 -opensource \
michael@1 344 -prefix %{l_prefix} \
michael@1 345 -bindir %{l_prefix}/bin \
michael@263 346 -libdir %{l_prefix}/lib/qt/dynamic \
michael@1 347 -docdir %{l_prefix}/share/qt/doc \
michael@1 348 -headerdir %{l_prefix}/include \
michael@86 349 -plugindir %{l_prefix}/lib/qt/plugins \
michael@1 350 -datadir %{l_prefix}/share/qt \
michael@1 351 -translationdir %{l_prefix}/share/qt/translations \
michael@1 352 -sysconfdir %{l_prefix}/etc/qt \
michael@1 353 -examplesdir %{l_prefix}/share/qt/examples \
michael@1 354 -demosdir %{l_prefix}/share/qt/demos \
michael@340 355 %if 0
michael@340 356 # Build time Qt definitions should predominate,
michael@340 357 # otherwise foreign definitions cause errors like:
michael@340 358 #
michael@340 359 # g++ -c -I/foreign/include [...] animation/qguivariantanimation.cpp
michael@340 360 # .moc/release-shared/moc_qnamespace.cpp:426:16: error: 'WA_LockPortraitOrientation' is not a member of 'Qt'
michael@340 361 # .moc/release-shared/moc_qnamespace.cpp:427:16: error: 'WA_LockLandscapeOrientation' is not a member of 'Qt'
michael@340 362 # .moc/release-shared/moc_qnamespace.cpp:428:16: error: 'WA_AutoOrientation' is not a member of 'Qt'
michael@340 363 # .moc/release-shared/moc_qnamespace.cpp:440:16: error: 'AA_S60DisablePartialScreenInputMode' is not a member of 'Qt'
michael@340 364 #
michael@340 365 # Other problems include flawed definitions polluting (C|CXX)FLAGS
michael@340 366 # and overriding the correct definitions in CPPFLAGS. Variables
michael@340 367 # like QMAKE_(C|CXX)FLAGS exhibit this problem as well.
michael@340 368 #
michael@340 369 # The work around is to force a Qt dist include path in (C|CXX)FLAGS.
michael@340 370 %endif
michael@340 371 -I$RPM_BUILD_DIR/qt-everywhere-opensource-src-%{version}/include \
michael@1 372 -release \
michael@1 373 -shared \
michael@1 374 -platform $platcomp \
michael@340 375 -s60 \
michael@340 376 -qt-style-s60 \
michael@1 377 -no-sql-ibase \
michael@288 378 %if "%{with_glib}" == "yes"
michael@288 379 -glib \
michael@288 380 %else
michael@288 381 -no-glib \
michael@288 382 %endif
michael@65 383 %if "%{with_mysql}" == "yes"
michael@3 384 -qt-sql-mysql \
michael@86 385 -plugin-sql-mysql \
michael@65 386 %else
michael@65 387 -no-sql-mysql \
michael@65 388 %endif
michael@65 389 %if "%{with_pgsql}" == "yes"
michael@65 390 -qt-sql-psql \
michael@86 391 -plugin-sql-psql \
michael@65 392 %else
michael@65 393 -no-sql-psql \
michael@65 394 %endif
michael@1 395 -no-sql-odbc \
michael@65 396 -system-sqlite \
michael@65 397 -qt-sql-sqlite \
michael@86 398 -plugin-sql-sqlite \
michael@1 399 -no-sql-sqlite2 \
michael@3 400 -openssl-linked \
michael@288 401 -optimized-qmake \
michael@1 402 -xmlpatterns \
michael@1 403 -svg \
michael@215 404 -webkit \
michael@1 405 -system-zlib \
michael@1 406 -qt-gif \
michael@1 407 -system-libpng \
michael@1 408 -system-libmng \
michael@1 409 -system-libjpeg \
michael@1 410 -system-libtiff \
michael@1 411 -rpath \
michael@1 412 -no-cups \
michael@257 413 -iconv \
michael@1 414 -pch \
michael@1 415 -dbus-linked \
michael@1 416 -opengl \
michael@1 417 -xrender \
michael@1 418 -fontconfig \
michael@288 419 -freetype
michael@1 420
michael@86 421 # default options are implicitly used, for example...
michael@1 422 #-no-fast -exceptions -accessibility -stl -qt3support -nis
michael@1 423 #-sm -xshape -xinerama -xcursor -xfixes -xrandr -tablet -xkb
michael@1 424
michael@1 425 # carry out shared build procedure
michael@1 426 ( cd src
michael@1 427 %{l_make} %{l_mflags -O} \
michael@215 428 sub-moc sub-rcc sub-uic sub-uic3
michael@1 429 ) || exit $?
michael@257 430 %{l_make} %{l_mflags -O} \
michael@257 431 sub-corelib-make_default-ordered \
michael@257 432 sub-xml-make_default-ordered \
michael@257 433 sub-network-make_default-ordered \
michael@257 434 sub-sql-make_default-ordered \
michael@257 435 sub-testlib-make_default-ordered \
michael@257 436 sub-dbus-make_default-ordered \
michael@257 437 sub-gui-make_default-ordered \
michael@257 438 sub-qt3support-make_default-ordered \
michael@257 439 sub-opengl-make_default-ordered \
michael@257 440 sub-xmlpatterns-make_default-ordered \
michael@257 441 sub-multimedia-make_default-ordered \
michael@257 442 sub-svg-make_default-ordered \
michael@257 443 sub-script-make_default-ordered \
michael@257 444 sub-declarative-make_default-ordered \
michael@257 445 sub-javascriptcore-make_default-ordered \
michael@257 446 sub-webkit-make_default-ordered \
michael@257 447 sub-scripttools-make_default-ordered \
michael@257 448 sub-plugins-make_default-ordered \
michael@257 449 sub-imports-make_default-ordered \
michael@257 450 sub-webkitdeclarative-make_default-ordered \
michael@257 451 sub-translations-make_default-ordered
michael@205 452
michael@205 453 # arthur plugin requires libQtDesigner
michael@92 454 ( cd demos
michael@205 455 ( cd ../tools/designer/src/lib
michael@263 456 %{l_make} %{l_mflags -O}
michael@205 457 ) || exit $?
michael@92 458 %{l_make} %{l_mflags -O} sub-arthurplugin
michael@92 459 ) || exit $?
michael@1 460
michael@1 461 # cache shared libs and initialize the build configuration, which
michael@1 462 # would otherwise still contain references to our shared libs build
michael@263 463 %{l_shtool} mkdir -f -p -m 755 sharbuild/dynamic
michael@263 464 mv lib/* sharbuild/dynamic/
michael@263 465 mv plugins sharbuild/
michael@257 466 %{l_make} %{l_mflags} confclean
michael@1 467 %endif
michael@1 468
michael@1 469 # mandatory static build (follows optional shared build)
michael@1 470 echo 'yes' | ./configure \
michael@92 471 $archflags \
michael@205 472 -opensource \
michael@1 473 -prefix %{l_prefix} \
michael@1 474 -bindir %{l_prefix}/bin \
michael@1 475 -libdir %{l_prefix}/lib \
michael@1 476 -docdir %{l_prefix}/share/qt/doc \
michael@1 477 -headerdir %{l_prefix}/include \
michael@86 478 -plugindir %{l_prefix}/lib/qt/plugins \
michael@1 479 -datadir %{l_prefix}/share/qt \
michael@1 480 -translationdir %{l_prefix}/share/qt/translations \
michael@1 481 -sysconfdir %{l_prefix}/etc/qt \
michael@1 482 -examplesdir %{l_prefix}/share/qt/examples \
michael@1 483 -demosdir %{l_prefix}/share/qt/demos \
michael@340 484 %if 0
michael@340 485 # Build time Qt definitions should predominate,
michael@340 486 # otherwise foreign definitions cause errors like:
michael@340 487 #
michael@340 488 # g++ -c -I/foreign/include [...] animation/qguivariantanimation.cpp
michael@340 489 # .moc/release-shared/moc_qnamespace.cpp:426:16: error: 'WA_LockPortraitOrientation' is not a member of 'Qt'
michael@340 490 # .moc/release-shared/moc_qnamespace.cpp:427:16: error: 'WA_LockLandscapeOrientation' is not a member of 'Qt'
michael@340 491 # .moc/release-shared/moc_qnamespace.cpp:428:16: error: 'WA_AutoOrientation' is not a member of 'Qt'
michael@340 492 # .moc/release-shared/moc_qnamespace.cpp:440:16: error: 'AA_S60DisablePartialScreenInputMode' is not a member of 'Qt'
michael@340 493 #
michael@340 494 # Other problems include flawed definitions polluting (C|CXX)FLAGS
michael@340 495 # and overriding the correct definitions in CPPFLAGS. Variables
michael@340 496 # like QMAKE_(C|CXX)FLAGS exhibit this problem as well.
michael@340 497 #
michael@340 498 # The work around is to force a Qt dist include path in (C|CXX)FLAGS.
michael@340 499 %endif
michael@340 500 -I$RPM_BUILD_DIR/qt-everywhere-opensource-src-%{version}/include \
michael@1 501 -release \
michael@1 502 -static \
michael@1 503 -platform $platcomp \
michael@340 504 -s60 \
michael@340 505 -qt-style-s60 \
michael@1 506 -no-sql-ibase \
michael@288 507 %if "%{with_glib}" == "yes"
michael@288 508 -glib \
michael@288 509 %else
michael@288 510 -no-glib \
michael@288 511 %endif
michael@65 512 %if "%{with_mysql}" == "yes"
michael@3 513 -qt-sql-mysql \
michael@65 514 %else
michael@65 515 -no-sql-mysql \
michael@65 516 %endif
michael@65 517 %if "%{with_pgsql}" == "yes"
michael@65 518 -qt-sql-psql \
michael@65 519 %else
michael@65 520 -no-sql-psql \
michael@65 521 %endif
michael@1 522 -no-sql-odbc \
michael@65 523 -system-sqlite \
michael@65 524 -qt-sql-sqlite \
michael@1 525 -no-sql-sqlite2 \
michael@3 526 -openssl-linked \
michael@288 527 -optimized-qmake \
michael@1 528 -xmlpatterns \
michael@1 529 -svg \
michael@265 530 -webkit \
michael@1 531 -system-zlib \
michael@1 532 -qt-gif \
michael@1 533 -system-libpng \
michael@1 534 -system-libmng \
michael@1 535 -system-libjpeg \
michael@1 536 -system-libtiff \
michael@1 537 -rpath \
michael@1 538 -no-cups \
michael@257 539 -iconv \
michael@1 540 -pch \
michael@1 541 -dbus-linked \
michael@1 542 -opengl \
michael@1 543 -xrender \
michael@1 544 -fontconfig \
michael@288 545 -freetype
michael@1 546
michael@86 547 # default options are implicitly used, for example...
michael@1 548 #-no-fast -exceptions -accessibility -stl -qt3support -nis
michael@1 549 #-sm -xshape -xinerama -xcursor -xfixes -xrandr -tablet -xkb
michael@1 550
michael@1 551 # carry out static build procedure
michael@341 552 # Trolltech Bug:
michael@341 553 # Problem with dependency order, causes compiling of qtreeview.cpp
michael@341 554 # with dependency to moc_qtreeview.cpp before moc(1) has finished.
michael@341 555 # The implemented work around is disabling parallel make, causing
michael@341 556 # a nearly 100% build deceleration but allowing the build to procede.
michael@341 557 # In file included from itemviews/qtreeview.cpp:3761:0:
michael@341 558 # .moc/release-static/moc_qtreeview.cpp: In member function 'QPixmap QTreeViewPrivate::renderTreeToPixmapForAnimation(const QRect&) const':
michael@341 559 # .moc/release-static/moc_qtreeview.cpp:209:1: internal compiler error: Segmentation fault
michael@341 560 %{l_make} %{l_mflags} sub-src
michael@1 561 %if "%{with_tools}" == "yes"
michael@258 562 %{l_make} %{l_mflags -O} \
michael@258 563 sub-tools-make_default-ordered sub-translations-make_default-ordered
michael@1 564 %endif
michael@1 565 %if "%{with_examples}" == "yes"
michael@1 566 %{l_make} %{l_mflags -O} \
michael@1 567 sub-demos-make_default-ordered \
michael@1 568 sub-examples-make_default-ordered
michael@1 569 %endif
michael@258 570 %if "%{with_tools}" == "yes"
michael@258 571 %{l_make} %{l_mflags -O} docs
michael@258 572 %else
michael@258 573 %if "%{with_examples}" == "yes"
michael@258 574 %{l_make} %{l_mflags -O} docs
michael@258 575 %endif
michael@258 576 %endif
michael@1 577
michael@1 578 %install
michael@1 579 rm -rf $RPM_BUILD_ROOT
michael@1 580
michael@1 581 # carry out installation procedure
michael@215 582 targets="sub-tools-bootstrap-install_subtargets-ordered \
michael@215 583 sub-moc-install_subtargets-ordered \
michael@1 584 sub-rcc-install_subtargets-ordered \
michael@1 585 sub-uic-install_subtargets-ordered \
michael@1 586 sub-corelib-install_subtargets-ordered \
michael@1 587 sub-xml-install_subtargets-ordered \
michael@1 588 sub-network-install_subtargets-ordered \
michael@257 589 sub-sql-install_subtargets-ordered \
michael@257 590 sub-testlib-install_subtargets-ordered \
michael@257 591 sub-dbus-install_subtargets-ordered \
michael@1 592 sub-gui-install_subtargets-ordered \
michael@1 593 sub-qt3support-install_subtargets-ordered \
michael@1 594 sub-uic3-install_subtargets-ordered \
michael@1 595 sub-opengl-install_subtargets-ordered \
michael@1 596 sub-xmlpatterns-install_subtargets-ordered \
michael@257 597 sub-multimedia-install_subtargets-ordered \
michael@1 598 sub-svg-install_subtargets-ordered \
michael@257 599 sub-script-install_subtargets-ordered \
michael@257 600 sub-declarative-install_subtargets-ordered \
michael@257 601 sub-scripttools-install_subtargets-ordered \
michael@257 602 sub-imports-install_subtargets-ordered \
michael@257 603 sub-translations-install_subtargets-ordered"
michael@257 604
michael@1 605 %if "%{with_tools}" == "yes"
michael@258 606 targets="$targets sub-tools-install_subtargets-ordered install_htmldocs install_qchdocs install_docimages"
michael@1 607 %endif
michael@1 608 %if "%{with_examples}" == "yes"
michael@258 609 targets="$targets sub-demos-install_subtargets-ordered sub-examples-install_subtargets-ordered install_htmldocs install_qchdocs install_docimages"
michael@1 610 %endif
michael@258 611 targets="$targets install_qmake install_mkspecs"
michael@1 612 %{l_make} %{l_mflags} $targets INSTALL_ROOT="$RPM_BUILD_ROOT"
michael@266 613 %{l_shtool} install -c -m 644 \
michael@266 614 lib/libjscore.a lib/libjscore.prl \
michael@266 615 $RPM_BUILD_ROOT%{l_prefix}/lib/
michael@1 616
michael@266 617 # correct paths in pkg-config(1) configuration files
michael@266 618 %{l_shtool} subst \
michael@341 619 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version};-L%{l_prefix};' \
michael@341 620 -e 's;=\([\t ]*\)[^\t ]*qt-everywhere-opensource-src-%{version};=\1%{l_prefix};g' \
michael@341 621 $RPM_BUILD_ROOT%{l_prefix}/lib/pkgconfig/*
michael@341 622 # keep library paths clean by removing redundant paths
michael@341 623 %{l_shtool} subst \
michael@341 624 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version}[^\t ]*[\t ]*;;g' \
michael@266 625 $RPM_BUILD_ROOT%{l_prefix}/lib/pkgconfig/*
michael@266 626
michael@266 627 # install static or shared plugins according to user choice
michael@263 628 %if "%{with_shared}" != "yes"
michael@263 629 %{l_make} %{l_mflags} sub-plugins-install_subtargets-ordered INSTALL_ROOT="$RPM_BUILD_ROOT"
michael@263 630 %else
michael@264 631 %{l_tar} cf - -C sharbuild plugins | %{l_tar} xf - -C $RPM_BUILD_ROOT%{l_prefix}/lib/qt
michael@263 632 %endif
michael@266 633
michael@1 634 %if "%{with_shared}" == "yes"
michael@1 635 # install shared libs and symlinks
michael@1 636 %{l_shtool} mkdir -f -p -m 755 \
michael@1 637 $RPM_BUILD_ROOT%{l_prefix}/lib/qt
michael@264 638 %{l_tar} cf - -C sharbuild dynamic | %{l_tar} xf - -C $RPM_BUILD_ROOT%{l_prefix}/lib/qt
michael@1 639
michael@86 640 # offer limited support of pkg-config(1) for shared libs
michael@87 641 # substitution unfortunately only handles paths with no whitespace
michael@86 642 %{l_shtool} subst \
michael@341 643 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version}/lib;-L%{l_prefix}/lib/qt/dynamic;' \
michael@341 644 -e 's;=\([\t ]*\)[^\t ]*qt-everywhere-opensource-src-%{version};=\1%{l_prefix};g' \
michael@341 645 $RPM_BUILD_ROOT%{l_prefix}/lib/qt/dynamic/pkgconfig/*
michael@341 646 # keep library paths clean by removing redundant paths
michael@341 647 %{l_shtool} subst \
michael@341 648 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version}[^\t ]*[\t ]*;;g' \
michael@87 649 $RPM_BUILD_ROOT%{l_prefix}/lib/qt/dynamic/pkgconfig/*
michael@86 650
michael@1 651 # explain nonstandard shared library placement
michael@86 652 ( echo "This OpenPKG Qt build is using the with_shared option."
michael@86 653 echo ""
michael@263 654 echo "The directory %{l_prefix}/lib/qt/dynamic contains the"
michael@263 655 echo "requested shared libraries. Although shared libraries"
michael@263 656 echo "have been optionally built (see the build time"
michael@263 657 echo "'with_shared yes' option), static libraries were"
michael@263 658 echo "built by default as usual, and installed in the"
michael@86 659 echo "standard library directory %{l_prefix}/lib."
michael@86 660 echo ""
michael@86 661 echo "To build applications using shared libraries instead,"
michael@262 662 echo "please direct pkg-config(1) to use the proper definitions"
michael@86 663 echo "by setting the environment variable PKG_CONFIG_PATH to "
michael@86 664 echo "%{l_prefix}/lib/qt/dynamic/pkgconfig."
michael@263 665 echo ""
michael@263 666 echo "Note: If building via qmake(1), please append"
michael@263 667 echo " either 'static' or 'shared' to the line"
michael@263 668 echo " 'CONFIG +=' in the project file (name.pro)."
michael@263 669 echo " Then execute %{l_prefix}/bin/qmake on this file."
michael@1 670 ) >$RPM_BUILD_ROOT%{l_prefix}/lib/qt/README
michael@263 671 %endif
michael@1 672
michael@263 673 # correct temporary runtime link paths (static libs)
michael@1 674 %{l_shtool} subst \
michael@341 675 -e 's;/./;/;g' \
michael@341 676 -e 's;\(QMAKE_PRL_BUILD_DIR[\t ]*=\).*\(qt-everywhere-opensource-src-%{version}.*\);\1 /.../\2;' \
michael@341 677 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version};-L%{l_prefix};' \
michael@341 678 $RPM_BUILD_ROOT%{l_prefix}/lib/qt/plugins/*/*.prl \
michael@341 679 $RPM_BUILD_ROOT%{l_prefix}/lib/*.prl \
michael@341 680 $RPM_BUILD_ROOT%{l_prefix}/lib/*.la
michael@341 681 # keep library paths clean by removing redundant paths
michael@341 682 %{l_shtool} subst \
michael@341 683 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version}[^\t ]*[\t ]*;;g' \
michael@263 684 $RPM_BUILD_ROOT%{l_prefix}/lib/*.prl \
michael@263 685 $RPM_BUILD_ROOT%{l_prefix}/lib/*.la
michael@263 686 %if "%{with_shared}" == "yes"
michael@263 687 # correct temporary runtime link paths (dynamic libs)
michael@263 688 %{l_shtool} subst \
michael@341 689 -e 's;/./;/;g' \
michael@341 690 -e 's;\(QMAKE_PRL_BUILD_DIR[\t ]*=\).*\(qt-everywhere-opensource-src-%{version}.*\);\1 /.../\2;' \
michael@341 691 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version}/lib;-L%{l_prefix}/lib/qt/dynamic;' \
michael@92 692 $RPM_BUILD_ROOT%{l_prefix}/lib/qt/dynamic/*.prl \
michael@92 693 $RPM_BUILD_ROOT%{l_prefix}/lib/qt/dynamic/*.la
michael@341 694 # keep library paths clean by removing redundant paths
michael@341 695 %{l_shtool} subst \
michael@341 696 -e 's;-L[\t ]*[^\t ]*qt-everywhere-opensource-src-%{version}[^\t ]*[\t ]*;;g' \
michael@341 697 $RPM_BUILD_ROOT%{l_prefix}/lib/*.prl \
michael@341 698 $RPM_BUILD_ROOT%{l_prefix}/lib/*.la
michael@1 699 %endif
michael@1 700
michael@259 701 ## Doesn't work as expected, because RPM reads the --[in|ex]cludedocs
michael@259 702 ## argument only when installing binary packages, rather than building.
michael@259 703 #%define _excludedocs 0
michael@259 704 #%define _includedocs 1
michael@259 705 # echo %{_excludedocs}
michael@259 706 # echo %{_includedocs}
michael@259 707 #
michael@259 708 ## Doesn't work as expected, because it seems that OpenPKG too mercilessly
michael@340 709 ## removes RPM reading of the %docdir keyword in rpm.patch.feature.
michael@259 710 # %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
michael@259 711 # %{l_files_std} \
michael@259 712 # '%docdir %{l_prefix}/share/pkg/doc'
michael@259 713 #
michael@259 714 ## Doesn't work as expected, because the rpmtool(1) marks
michael@259 715 ## only einzeln files as documents, skipping directories
michael@259 716 # %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
michael@259 717 # %{l_files_std} \
michael@259 718 # '%doc %{l_prefix}/share/pkg/doc/doc.txt'
michael@259 719 #
michael@1 720 # determine internal file listing
michael@1 721 %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
michael@1 722 %{l_files_std} \
michael@1 723 '%not %dir %{l_prefix}/lib/pkgconfig'
michael@1 724
michael@1 725 %files -f files
michael@1 726
michael@1 727 %clean
michael@1 728 rm -rf $RPM_BUILD_ROOT
michael@1 729

mercurial