mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-18 22:54:00 +00:00
139 lines
4.6 KiB
Bash
139 lines
4.6 KiB
Bash
|
# $Id: PKGBUILD 179026 2013-03-01 17:55:20Z andrea $
|
||
|
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
|
||
|
# Contributor: Pierre Schmitz <pierre@archlinux.de>
|
||
|
|
||
|
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
|
||
|
# - Just say NO to x86 optimizations, and no neon
|
||
|
# - disabled distcc - bad things happen
|
||
|
# - added -fno-strict-volatile-bitfields to CXXFLAGS to fix ARM bug
|
||
|
# - no libfbclient/ibase, issues building on ARM
|
||
|
|
||
|
pkgname=qt4
|
||
|
pkgver=4.8.4
|
||
|
pkgrel=12
|
||
|
arch=('i686' 'x86_64')
|
||
|
url='http://qt-project.org/'
|
||
|
license=('GPL3' 'LGPL')
|
||
|
pkgdesc='A cross-platform application and UI framework'
|
||
|
depends=('libtiff' 'libpng' 'libmng' 'sqlite' 'ca-certificates' 'dbus'
|
||
|
'fontconfig' 'libgl' 'libxrandr' 'libxv' 'libxi' 'alsa-lib'
|
||
|
'xdg-utils' 'hicolor-icon-theme' 'desktop-file-utils')
|
||
|
makedepends=('postgresql-libs' 'mysql' 'unixodbc' 'cups' 'gtk2'
|
||
|
'mesa-libgl')
|
||
|
optdepends=('postgresql-libs: PostgreSQL driver'
|
||
|
'libmysqlclient: MySQL driver'
|
||
|
'unixodbc: ODBC driver'
|
||
|
'libxinerama: Xinerama support'
|
||
|
'libxcursor: Xcursor support'
|
||
|
'libxfixes: Xfixes support'
|
||
|
'icu: Unicode support')
|
||
|
install="${pkgname}.install"
|
||
|
options=('!libtool' '!distcc')
|
||
|
replaces=('qt<=4.8.4')
|
||
|
conflicts=('qt')
|
||
|
_pkgfqn="qt-everywhere-opensource-src-${pkgver}"
|
||
|
source=("http://releases.qt-project.org/${pkgname}/source/${_pkgfqn}.tar.gz"
|
||
|
'qtconfig.desktop' 'qt4.profile'
|
||
|
'improve-cups-support.patch')
|
||
|
md5sums=('89c5ecba180cae74c66260ac732dc5cb'
|
||
|
'20ca06ef59775d749b9451ce7437fa9a'
|
||
|
'4ed0bd79a310e2b5d34fc71760b99139'
|
||
|
'c439c7731c25387352d8453ca7574971')
|
||
|
|
||
|
build() {
|
||
|
cd ${_pkgfqn}
|
||
|
|
||
|
# (FS#28381) (KDEBUG#180051)
|
||
|
patch -p1 -i "${srcdir}"/improve-cups-support.patch
|
||
|
|
||
|
export QT4DIR="${srcdir}"/${_pkgfqn}
|
||
|
export LD_LIBRARY_PATH=${QT4DIR}/lib:${LD_LIBRARY_PATH}
|
||
|
|
||
|
export CXXFLAGS="$CXXFLAGS -fno-strict-volatile-bitfields"
|
||
|
|
||
|
sed -i "s|-O2|${CXXFLAGS}|" mkspecs/common/{g++,gcc}-base.conf
|
||
|
sed -i "/^QMAKE_LFLAGS_RPATH/s| -Wl,-rpath,||g" mkspecs/common/gcc-base-unix.conf
|
||
|
sed -i "/^QMAKE_LFLAGS\s/s|+=|+= ${LDFLAGS}|g" mkspecs/common/gcc-base.conf
|
||
|
|
||
|
./configure -confirm-license -opensource \
|
||
|
-prefix /usr \
|
||
|
-bindir /usr/lib/qt4/bin \
|
||
|
-headerdir /usr/include/qt4 \
|
||
|
-docdir /usr/share/doc/qt4 \
|
||
|
-plugindir /usr/lib/qt4/plugins \
|
||
|
-importdir /usr/lib/qt4/imports \
|
||
|
-datadir /usr/share/qt4 \
|
||
|
-translationdir /usr/share/qt4/translations \
|
||
|
-sysconfdir /etc/xdg \
|
||
|
-examplesdir /usr/share/doc/qt4/examples \
|
||
|
-demosdir /usr/share/doc/qt4/demos \
|
||
|
-plugin-sql-{psql,mysql,sqlite,odbc} \
|
||
|
-system-sqlite \
|
||
|
-no-phonon \
|
||
|
-no-phonon-backend \
|
||
|
-no-webkit \
|
||
|
-graphicssystem raster \
|
||
|
-openssl-linked \
|
||
|
-nomake demos \
|
||
|
-nomake examples \
|
||
|
-nomake docs \
|
||
|
-silent \
|
||
|
-no-rpath \
|
||
|
-optimized-qmake \
|
||
|
-reduce-relocations \
|
||
|
-dbus-linked \
|
||
|
-no-openvg \
|
||
|
-no-mmx \
|
||
|
-no-3dnow \
|
||
|
-no-sse \
|
||
|
-no-sse2 \
|
||
|
-no-sse3 \
|
||
|
-no-ssse3 \
|
||
|
-no-sse4.1 \
|
||
|
-no-sse4.2 \
|
||
|
-no-avx \
|
||
|
-no-neon
|
||
|
make
|
||
|
}
|
||
|
|
||
|
package() {
|
||
|
cd ${_pkgfqn}
|
||
|
make INSTALL_ROOT="${pkgdir}" install
|
||
|
|
||
|
# install missing icons and desktop files
|
||
|
install -D -m644 src/gui/dialogs/images/qtlogo-64.png \
|
||
|
"${pkgdir}/usr/share/icons/hicolor/64x64/apps/qt4logo.png"
|
||
|
install -Dm644 "${srcdir}"/qtconfig.desktop \
|
||
|
"${pkgdir}/usr/share/applications/qtconfig4.desktop"
|
||
|
|
||
|
# install the profile
|
||
|
install -D -m755 "${srcdir}"/qt4.profile "${pkgdir}"/etc/profile.d/qt4.sh
|
||
|
|
||
|
# Useful symlinks for cmake and configure scripts
|
||
|
install -d "${pkgdir}"/usr/bin
|
||
|
for b in "${pkgdir}"/usr/lib/qt4/bin/*; do
|
||
|
ln -s /usr/lib/qt4/bin/$(basename $b) "${pkgdir}"/usr/bin/$(basename $b)-qt4
|
||
|
done
|
||
|
|
||
|
# install license addition
|
||
|
install -D -m644 LGPL_EXCEPTION.txt \
|
||
|
${pkgdir}/usr/share/licenses/${pkgname}/LGPL_EXCEPTION.txt
|
||
|
|
||
|
# Fix wrong libs path in pkgconfig files
|
||
|
find "${pkgdir}/usr/lib/pkgconfig" -type f -name '*.pc' \
|
||
|
-exec perl -pi -e "s, -L${srcdir}/?\S+,,g" {} \;
|
||
|
|
||
|
# Fix wrong bins path in pkgconfig files
|
||
|
find "${pkgdir}/usr/lib/pkgconfig" -type f -name '*.pc' \
|
||
|
-exec sed -i 's|/usr/bin/|/usr/lib/qt4/bin/|g' {} \;
|
||
|
|
||
|
# Fix wrong path in prl files
|
||
|
find "${pkgdir}/usr/lib" -type f -name '*.prl' \
|
||
|
-exec sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' {} \;
|
||
|
|
||
|
# Do not install the qttools
|
||
|
rm "${pkgdir}"/usr/lib/qt4/bin/{assistant,designer,linguist}
|
||
|
rm -r "${pkgdir}"/usr/lib/qt4/plugins/designer
|
||
|
rm "${pkgdir}"/usr/share/qt4/translations/{assistant,designer,linguist}_*.qm
|
||
|
}
|