2013-12-27 21:19:40 +01:00
|
|
|
# Template file for 'emacs'
|
|
|
|
pkgname=emacs
|
2014-10-21 16:44:11 +02:00
|
|
|
version=24.4
|
|
|
|
revision=1
|
2014-08-22 16:21:57 +02:00
|
|
|
nocross=yes
|
2013-12-28 10:13:21 +01:00
|
|
|
hostmakedepends="pkg-config"
|
2014-08-30 00:37:53 +02:00
|
|
|
makedepends="ncurses-devel libXaw-devel gtk+-devel $(vopt_if dbus dbus-devel)
|
|
|
|
$(vopt_if jpeg libjpeg-turbo-devel) $(vopt_if tiff tiff-devel)
|
|
|
|
$(vopt_if gif giflib-devel) $(vopt_if png libpng-devel) $(vopt_if xpm libXpm-devel)
|
|
|
|
$(vopt_if svg librsvg-devel) $(vopt_if imagemagick libmagick-devel)
|
|
|
|
$(vopt_if xml libxml2-devel) $(vopt_if gnutls gnutls-devel)
|
2014-10-21 16:44:11 +02:00
|
|
|
$(vopt_if sound alsa-lib-devel) acl-devel"
|
2014-07-11 23:20:22 +02:00
|
|
|
depends="emacs-common-${version}_${revision}"
|
|
|
|
replaces="emacs>=0"
|
2013-12-28 10:13:21 +01:00
|
|
|
build_style="gnu-configure"
|
2014-10-21 16:44:11 +02:00
|
|
|
configure_args="--with-file-notification=inotify
|
2014-08-30 00:37:53 +02:00
|
|
|
$(vopt_with dbus) $(vopt_with jpeg) $(vopt_with tiff) $(vopt_with gif)
|
|
|
|
$(vopt_with png) $(vopt_with xpm) $(vopt_with svg rsvg) $(vopt_with imagemagick)
|
|
|
|
$(vopt_with xml xml2) $(vopt_with gnutls) $(vopt_with sound)"
|
2014-07-11 23:20:22 +02:00
|
|
|
short_desc="GNU Emacs editor"
|
2014-10-21 16:44:11 +02:00
|
|
|
maintainer="Christian Neukirchen <chneukirchen@gmail.com>"
|
2013-12-27 21:19:40 +01:00
|
|
|
license="GPL-3"
|
|
|
|
homepage="http://www.gnu.org/software/${pkgname}/"
|
2014-10-21 16:44:11 +02:00
|
|
|
distfiles="${GNU_SITE}/${pkgname}/${pkgname}-${version}.tar.xz"
|
|
|
|
checksum=47e391170db4ca0a3c724530c7050655f6d573a711956b4cd84693c194a9d4fd
|
2013-12-27 21:19:40 +01:00
|
|
|
|
2013-12-28 10:13:21 +01:00
|
|
|
# Package build options
|
2014-07-11 23:20:22 +02:00
|
|
|
build_options="dbus jpeg tiff gif png xpm svg xml imagemagick gnutls sound"
|
|
|
|
desc_option_xpm="Enable support for XPM images"
|
|
|
|
desc_option_sound="Enable support for sound"
|
|
|
|
build_options_default="jpeg tiff gif png xpm svg xml gnutls sound"
|
2013-12-28 10:13:21 +01:00
|
|
|
|
2014-08-17 20:09:23 +02:00
|
|
|
pre_configure() {
|
|
|
|
# Just configuring in different directories results in
|
|
|
|
# spurious emacs rebuilds with incompatible build numbers.
|
|
|
|
mkdir -p nox
|
|
|
|
mv * nox || true
|
|
|
|
cp -a nox x11
|
2014-10-21 16:44:11 +02:00
|
|
|
cp -a nox gtk2
|
2014-08-17 20:09:23 +02:00
|
|
|
}
|
2014-07-11 23:20:22 +02:00
|
|
|
|
2014-08-17 20:09:23 +02:00
|
|
|
do_configure() {
|
2014-07-11 23:20:22 +02:00
|
|
|
cd $wrksrc/nox
|
2014-10-21 16:44:11 +02:00
|
|
|
./configure --without-x ${configure_args}
|
2014-07-11 23:20:22 +02:00
|
|
|
|
|
|
|
cd $wrksrc/x11
|
2014-10-21 16:44:11 +02:00
|
|
|
./configure --with-x-toolkit=athena --without-toolkit-scroll-bars ${configure_args}
|
2014-07-11 23:20:22 +02:00
|
|
|
|
|
|
|
cd $wrksrc/gtk2
|
2014-10-21 16:44:11 +02:00
|
|
|
./configure --with-x-toolkit=gtk2 ${configure_args}
|
2014-07-11 23:20:22 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
do_build() {
|
|
|
|
make ${makejobs} -C nox
|
|
|
|
make ${makejobs} -C x11
|
|
|
|
make ${makejobs} -C gtk2
|
|
|
|
}
|
|
|
|
|
|
|
|
do_install() {
|
|
|
|
make DESTDIR=$DESTDIR -C ${wrksrc}/nox install
|
2014-03-19 12:07:48 +01:00
|
|
|
rm -f ${DESTDIR}/usr/bin/ctags
|
2014-07-11 23:20:22 +02:00
|
|
|
rm -f ${DESTDIR}/usr/share/man/man1/ctags.1*
|
2014-03-19 12:07:48 +01:00
|
|
|
rm -f ${DESTDIR}/usr/share/info/info.info
|
2014-07-11 23:20:22 +02:00
|
|
|
rm -rf ${DESTDIR}/usr/share/applications
|
|
|
|
rm -rf ${DESTDIR}/usr/share/icons
|
|
|
|
}
|
|
|
|
|
|
|
|
emacs-common_package() {
|
|
|
|
short_desc+=" - common files"
|
|
|
|
noarch=yes
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/share/emacs
|
|
|
|
vmove usr/share/man
|
|
|
|
vmove usr/share/info
|
|
|
|
vmove var/games/emacs
|
2014-08-22 16:17:02 +02:00
|
|
|
rm -f ${PKGDESTDIR}/usr/share/info/info.info.gz
|
2014-07-11 23:20:22 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
emacs-x11_package() {
|
|
|
|
depends="emacs-common-${version}_${revision}"
|
|
|
|
provides="emacs-${version}_${revision}"
|
|
|
|
replaces="emacs>=0"
|
|
|
|
short_desc+=" - X11 version"
|
|
|
|
pkg_install() {
|
|
|
|
make DESTDIR=${PKGDESTDIR} -C ${wrksrc}/x11 install
|
|
|
|
rm -f ${PKGDESTDIR}/usr/bin/ctags
|
|
|
|
rm -rf ${PKGDESTDIR}/usr/share
|
|
|
|
rm -rf ${PKGDESTDIR}/var/games/emacs
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
emacs-gtk2_package() {
|
|
|
|
depends="emacs-common-${version}_${revision} desktop-file-utils hicolor-icon-theme"
|
|
|
|
provides="emacs-${version}_${revision}"
|
|
|
|
replaces="emacs>=0"
|
|
|
|
short_desc+=" - GTK+2 version"
|
|
|
|
pkg_install() {
|
|
|
|
make DESTDIR=${PKGDESTDIR} -C ${wrksrc}/gtk2 install
|
|
|
|
rm -f ${PKGDESTDIR}/usr/bin/ctags
|
|
|
|
rm -rf ${PKGDESTDIR}/usr/share/{emacs,man,info}
|
|
|
|
rm -rf ${PKGDESTDIR}/var/games/emacs
|
|
|
|
}
|
2014-03-19 12:07:48 +01:00
|
|
|
}
|