diff --git a/extra/kdebindings-smokegen/PKGBUILD b/extra/kdebindings-smokegen/PKGBUILD new file mode 100644 index 000000000..15a24ad59 --- /dev/null +++ b/extra/kdebindings-smokegen/PKGBUILD @@ -0,0 +1,39 @@ +# $Id: PKGBUILD 141752 2011-11-02 18:12:16Z andrea $ +# Maintainer: Andrea Scarpino + +# ALARM: Kevin Mihelich +# - Added patch to fix building of packages that depend on smokegen + +plugrel=1 + +pkgname=kdebindings-smokegen +pkgver=4.7.3 +pkgrel=1 +pkgdesc="A general purpose C++ parser with a plugin infrastructure" +url="http://kde.org/" +arch=('i686' 'x86_64') +license=('GPL' 'LGPL' 'FDL') +depends=('kdebase-runtime') +makedepends=('cmake' 'automoc4') +conflicts=('kdebindings-smoke') +source=("http://download.kde.org/stable/${pkgver}/src/smokegen-${pkgver}.tar.bz2" + "alarm.patch") +sha1sums=('ede4095fdb190b3bef13b246111e7d79903ad77e' + '1dd8dff3aa3cd8c6b29be54120060243cdc44277') + +build() { + cd "${srcdir}/smokegen-${pkgver}" + patch -p1 -i ${srcdir}/alarm.patch + cd "${srcdir}" + mkdir build + cd build + cmake ../smokegen-${pkgver} \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_PREFIX=/usr + make +} + +package() { + cd "${srcdir}"/build + make DESTDIR="${pkgdir}" install +} diff --git a/extra/kdebindings-smokegen/alarm.patch b/extra/kdebindings-smokegen/alarm.patch new file mode 100644 index 000000000..50f8ec5c7 --- /dev/null +++ b/extra/kdebindings-smokegen/alarm.patch @@ -0,0 +1,12 @@ +diff -urN a/type_compiler.cpp b/type_compiler.cpp +--- a/type_compiler.cpp 2011-05-20 14:33:31.000000000 -0600 ++++ b/type_compiler.cpp 2011-08-14 16:39:02.000000000 -0600 +@@ -191,6 +191,8 @@ + + void TypeCompiler::visitPtrOperator(PtrOperatorAST* node) + { ++ if ( ! m_session->token_stream ) return; ++ if ( ! token_text(m_session->token_stream->kind(node->op)) ) return; + if (token_text(m_session->token_stream->kind(node->op))[0] == '*') { + QPair cv = m_visitor->parseCv(node->cv); + pointerDepth.append(cv.first);