1 # Maintainer: Stefan Husmann <stefan-husmann@t-online.de>
2 # based on a PKGBUILD of Mathias Nedrebø <mathias <at> nedrebo.org>
8 pkgdesc="Emacs, bazaar-version from the xwidget branch"
9 url="http://www.gnu.org/software/emacs/emacs.html"
11 depends=('gconf' 'alsa-lib' 'librsvg' 'gpm' 'giflib' 'desktop-file-utils' 'hicolor-icon-theme' 'libwebkit3' 'imagemagick' 'm17n-lib')
12 makedepends=('bzr' 'texinfo' 'glproto')
13 options=('docs' '!emptydirs')
17 backup=('usr/share/applications/emacs.desktop' 'usr/share/emacs/site-lisp/subdirs.el')
20 _bzrtrunk=http://bzr.savannah.gnu.org/r/emacs/xwidget
24 if [[ -d $_bzrmod/.bzr ]]; then
25 (cd $_bzrmod && bzr update -v && cd ..)
26 msg "Local checkout updated or server timeout"
28 bzr co --lightweight -v $_bzrtrunk $_bzrmod
29 msg "Checkout done or server timeout"
33 msg "starting build ..."
35 [ -d $srcdir/${_bzrmod}-build ] && rm -rf $srcdir/${_bzrmod}-build
36 cp -r $srcdir/${_bzrmod} $srcdir/${_bzrmod}-build
39 cd $srcdir/${_bzrmod}-build
41 export CFLAGS="`pkg-config --cflags webkitgtk-3.0 ` -DHAVE_WEBKIT_OSR -g"
42 export LDFLAGS=`pkg-config --libs webkitgtk-3.0 `
43 ./autogen.sh && ./configure --prefix=/usr --with-x-toolkit=gtk3 \
44 --with-sound --libexecdir=/usr/lib --localstatedir=/var \
52 cd $srcdir/${_bzrmod}-build
53 make DESTDIR=$pkgdir install
54 chown -R root:root $pkgdir/usr
55 for _i in 16x16 24x24 32x32 48x48 128x128
57 mv $pkgdir/usr/share/icons/hicolor/${_i}/apps/emacs.png \
58 $pkgdir/usr/share/icons/hicolor/${_i}/apps/$pkgname.png
60 mv $pkgdir/usr/share/icons/hicolor/scalable/apps/emacs.svg \
61 $pkgdir/usr/share/icons/hicolor/scalable/apps/$pkgname.svg
62 mv $pkgdir/usr/share/icons/hicolor/scalable/mimetypes/emacs-document.svg \
63 $pkgdir/usr/share/icons/hicolor/scalable/mimetypes/$pkgname-document.svg
64 chmod 775 $pkgdir/var/games
66 install -Dm644 $srcdir/${_bzrmod}-build/README \
67 $pkgdir/usr/share/doc/$pkgname/README
68 install -Dm644 $srcdir/${_bzrmod}-build/README.xwidget \
69 $pkgdir/usr/share/doc/$pkgname/README.xwidget