[ create a new paste ] login | about

Link: http://codepad.org/CoT8bvUL    [ raw code | fork ]

Plain Text, pasted on Nov 3:
# Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>
# Contributor: Denis Martinez <deuns.martinez AT gmail.com>
# Contributor: Alexander 'hatred' Drozdov <adrozdoff AT gmail.com>
# Contributor: mosra <mosra@centrum.cz>
# Contributor: Alexandre Bique <bique.alexandre@gmail.com>

pkgname=mingw32-qt
true && pkgname=(mingw32-qt mingw32-qt-private-headers)
pkgver=4.7.4
pkgrel=3
pkgdesc="The Qt gui toolkit (mingw32)."
arch=('any')
url="http://qt.nokia.com/"
license=('LGPL')
depends=('mingw32-gcc' 'mingw32-zlib' 'mingw32-libjpeg' 'mingw32-libiconv' 'mingw32-libtiff' 'mingw32-sqlite3' 'mingw32-libpng14') #'mingw32-openssl'
makedepends=()
options=(!strip !buildflags !libtool)
_pkgfqn="qt-everywhere-opensource-src-${pkgver}"
source=("ftp://ftp.qt.nokia.com/qt/source/${_pkgfqn}.tar.gz"
        i486-mingw32-qmake
        qplatformdefs.h
        qmake.conf
        qt-dbus-dont-link-to-dbus-1d.patch)
md5sums=('9831cf1dfa8d0689a06c2c54c5c65aaf'
         '5b5fa1cc1b42fbde1f77ac05bdb519e3'
         'e3edee8c1b183043198f826fb3171670'
         '6f2741c3f83e563325ae7be484248083'
         '878ff1ea1ae368647c75cdaa7444ae86')

build() {
  cd "${srcdir}/${_pkgfqn}"

  patch -Np0 < ${srcdir}/qt-dbus-dont-link-to-dbus-1d.patch

  mkdir -p mkspecs/win32-g++-cross
  cp ${srcdir}/qplatformdefs.h mkspecs/win32-g++-cross
  cp ${srcdir}/qmake.conf mkspecs/win32-g++-cross

  export PKG_CONFIG_LIBDIR="/usr/i486-mingw32/lib/pkgconfig"
  unset PKG_CONFIG_PATH

#  [[ -d build ]] && rm -rf build
#  mkdir build && cd build

#    -bindir %{_mingw32_bindir} \
#    -datadir %{_mingw32_datadir}/qt4 \
#    -demosdir %{_mingw32_datadir}/qt4/demos \
#    -docdir %{_mingw32_docdir}/qt4 \
#    -examplesdir %{_mingw32_datadir}/qt4/examples \
#    -headerdir %{_mingw32_includedir} \
#    -libdir %{_mingw32_libdir} \
#    -plugindir %{_mingw32_libdir}/qt4/plugins \
#    -sysconfdir %{_mingw32_sysconfdir} \
#    -translationdir %{_mingw32_datadir}/qt4/translations \
    #-openssl \
    #-dbus-linked \
  ./configure -confirm-license -opensource \
      -release \
      -prefix /usr/i486-mingw32 \
      -shared \
      -qt3support \
      -verbose \
      -exceptions \
      -fast \
      -confirm-license \
      -force-pkg-config \
      -little-endian \
      -xplatform win32-g++-cross \
      -xmlpatterns \
      -multimedia \
      -audio-backend \
      -webkit \
      -script \
      -scripttools \
      -declarative \
      -no-phonon \
      -qt-libmng \
      -system-zlib \
      -system-libtiff \
      -system-libpng \
      -system-libjpeg \
      -system-sqlite \
      -iconv \
      -nomake demos,examples

  make
}

package_mingw32-qt() {
    pkgdesc='A cross-platform application and UI framework (mingw32)'

    cd "${srcdir}/${_pkgfqn}"

    make install INSTALL_ROOT=${pkgdir}

    cd "$pkgdir/usr/i486-mingw32"

    # Move plugins to bin/qt-plugins
    mkdir -p bin/qt-plugins
    mv plugins bin/qt-plugins

    # Move imports to bin/qt-imports
    mkdir -p bin/qt-imports
    mv imports bin/qt-imports

    # Install only relevant mkspecs
    rm -r mkspecs
    mkdir -p ${pkgdir}/usr/share/qt/mkspecs/win32-g++-cross
    cp ${srcdir}/qplatformdefs.h ${pkgdir}/usr/share/qt/mkspecs/win32-x-g++
    cp ${srcdir}/qmake.conf ${pkgdir}/usr/share/qt/mkspecs/win32-x-g++

    # qmake wrapper
    install -D -m755 ${srcdir}/i486-mingw32-qmake ${pkgdir}/usr/bin/i486-mingw32-qmake
}

package_mingw32-qt-private-headers() {
    pkgdesc='Qt private header development (mingw32)'

    install -d ${pkgdir}/usr/i486-mingw32/include/{QtCore,QtDeclarative,QtGui,QtScript}
    install -d ${pkgdir}/usr/i486-mingw32/src/{corelib,declarative,gui,script}

    for i in QtCore QtDeclarative QtGui QtScript; do
        cp -r "${srcdir}/$_pkgfqn/include/${i}/private/" \
            "${pkgdir}/usr/i486-mingw32/include/${i}/"
    done

    for i in corelib declarative gui script; do
        cp -r "${srcdir}/$_pkgfqn/src/${i}" "${pkgdir}/usr/i486-mingw32/src/"
    done
}



Create a new paste based on this one


Comments: