# $Id: PKGBUILD 268015 2016-05-14 19:41:45Z arojas $ # Maintainer: Ronald van Haren # Contributor: damir # Contributor: Gergely Imreh pkgname=qtiplot pkgver=0.9.8.9 pkgrel=9 arch=('i686' 'x86_64') url="http://soft.proindependent.com/qtiplot.html" pkgdesc="Data analysis and scientific plotting - free clone of Origin" depends=('muparser' 'gsl' 'python2-pyqt' 'boost-libs' 'shared-mime-info' 'glu' 'liborigin2' 'qt-assistant-compat' 'tamu-anova') # build against qwtplot3d provided in the package ... # build against qwt provided in the package ... # as systemwide one doesn't provide all needed functions makedepends=('pkg-config' 'boost' 'mesa') license=('GPL2') source=(http://downloads.sourceforge.net/project/qtiplot.berlios/$pkgname-$pkgver.tar.bz2 $pkgname.desktop $pkgname.png build.conf.archlinux qwtplot3d_gcc.patch qtiplot.xml qtiplot-0.9.8.6-gold.patch qtiplot-0.9.8.6-kde.patch qtiplot-0.9.8.6-tamuanova.patch qwtplot3d-qt-4.8.0.patch qwtplot3d-libpng15.patch pyqt-4.11.patch qtiplot-0.9.8.9-private.patch sip-4.15.patch qtiplot-gsl2.patch qtiplot-0.9.8.9-set_col_values.patch) sha1sums=('73b17dd9195c3d86750d5f1f5bdd4d5483c5fe30' '4d5d7cf3965a0a1b1aa9cafc34e70ee207700bc8' '4301cb2a36024a10108b689990d28c4fe5c7416e' '326ee6bc623a637d058ab7ee9f65fede40a23a09' '301bf6f70e8c1bb9ffd55eb49eedde7b29a12909' '285f57d865956d93250ec548288c5bface096b6b' 'b534a609f317cf3117d6495909854cdacea20124' 'a1d4bec744c9b8fe29bf177851e66c97cdd9d975' '830b518e3ef63625df84363a8047417124f243b0' '3d4c471dda29a04d432f8e0a4c5b977068cdae72' '4a45ee21f028f34da75d83c0d3e1d08c5f928892' 'cef3bca1c15be01ca8a8c0d75d557027d723286c' 'c5e9d075ce6a73c473e52a197d9919116b2cece5' '55a380bc61819258e0c11ccb42f9057e31d4881e' 'bcd28fda51444227e77638af1989a6a40e9f516c' 'ed9fbca568f3f49482a3229e27c8be523aed3a27' ) prepare() { cd $pkgname-$pkgver # gentoo fixes patch -Np1 -i "${srcdir}/qtiplot-0.9.8.6-gold.patch" patch -Np1 -i "${srcdir}/qtiplot-0.9.8.6-kde.patch" # patch -Np1 -i "${srcdir}/qtiplot-0.9.8.6-tamuanova.patch" patch -Np1 -i "$srcdir"/pyqt-4.11.patch patch -Np1 -i "$srcdir"/qtiplot-0.9.8.9-private.patch patch -Np1 -i "$srcdir"/sip-4.15.patch patch -Np1 -i "$srcdir"/qtiplot-gsl2.patch patch -Np1 -i "$srcdir"/qtiplot-0.9.8.9-set_col_values.patch # build also static qwtplot3d lib echo "unix:CONFIG += staticlib" >> 3rdparty/qwtplot3d/qwtplot3d.pro # install build configuration file install -Dm644 "${srcdir}/build.conf.archlinux" build.conf # Make qwt sed -i "s:elif:else:g" qtiplot/src/scripting/ScriptEdit.cpp patch -Np1 -i "${srcdir}/qwtplot3d_gcc.patch" } build() { cd ${pkgname}-${pkgver}/3rdparty/qwt qmake-qt4 make # Make qwtplot3d cd ../qwtplot3d patch -Np3 -i "${srcdir}/qwtplot3d-qt-4.8.0.patch" patch -Np0 -i "${srcdir}/qwtplot3d-libpng15.patch" qmake-qt4 make # Make qtiplot cd "${srcdir}/${pkgname}-${pkgver}/${pkgname}" # fix stuff sed -i 's|/usr/local/|/usr/share/|' qtiplot.pro sed -i 's|||' src/core/ApplicationWindow.cpp sed -i 's#d_python_config_folder + "#"/usr/share/qtiplot#' src/core/ApplicationWindow.cpp qmake-qt4 qtiplot.pro QMAKESPEC=linux-g++ QMAKE_CXXFLAGS+="-std=gnu++98" make QTDIR=/usr/ QMAKESPEC=linux-g++ } package() { cd "${srcdir}/${pkgname}-${pkgver}/${pkgname}" INSTALL_ROOT="${pkgdir}" make install # make it nice: install -D -m644 "${srcdir}/${pkgname}.png" \ "${pkgdir}/usr/share/pixmaps/${pkgname}.png" install -D -m644 "${srcdir}/${pkgname}.desktop" \ "${pkgdir}/usr/share/applications/${pkgname}.desktop" install -D -m644 "${srcdir}/${pkgname}.xml" \ "${pkgdir}/usr/share/mime/packages/${pkgname}.xml" }