Skip to content

Instantly share code, notes, and snippets.

@jabranham
Created May 22, 2018 13:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jabranham/3deb494e92e85102917913517f43d9e3 to your computer and use it in GitHub Desktop.
Save jabranham/3deb494e92e85102917913517f43d9e3 to your computer and use it in GitHub Desktop.
pkgname=emacs26
pkgver=26.0.99
pkgrel=1
pkgdesc="GNU Emacs RC1."
arch=('x86_64')
url="http://www.gnu.org/software/emacs/"
license=('GPL3')
depends=(
'alsa-lib'
'dbus'
'giflib'
'gnutls'
'hicolor-icon-theme'
'jansson'
'lcms2'
'libjpeg-turbo'
'libmagick6'
'libotf'
'librsvg'
'libxinerama'
'libxml2'
'xaw3d'
)
conflicts=('emacs')
provides=('emacs')
source=("ftp://alpha.gnu.org/gnu/emacs/pretest/emacs-26.1-rc1.tar.xz")
validpkgkeys=('B29426DEFB07724C3C35E5D36592E9A3A0B0F199' '28D3BED851FDF3AB57FEF93C233587A47C207910')
sha256sums=('6594e668de00b96e73ad4f168c897fe4bca7c55a4caf19ee20eac54b62a05758')
build() {
cd "$srcdir/emacs-26.1"
export PKG_CONFIG_PATH=/usr/lib/imagemagick6/pkgconfig
local _conf=(
--prefix=/usr
--sysconfdir=/etc
--libexecdir=/usr/lib
--localstatedir=/var
--mandir=/usr/share/man
--with-gameuser=:games
--with-sound=alsa
--with-modules
--without-gconf
--without-gsettings
--with-mailutils
--with-xml2
--with-x-toolkit=lucid --with-xft --with-xaw3d
--with-imagemagick
)
./configure "${_conf[@]}"
make
}
package() {
cd "$srcdir/emacs-26.1"
make DESTDIR="$pkgdir/" install
# remove conflict with ctags package
mv "$pkgdir"/usr/bin/{ctags,ctags.emacs}
mv "$pkgdir"/usr/share/man/man1/{ctags.1.gz,ctags.emacs.1.gz}
# fix user/root permissions on usr/share files
find "$pkgdir"/usr/share/emacs/ | xargs chown root:root
# fix permssions on /var/games
mkdir -p "$pkgdir"/var/games/emacs
chmod 775 "$pkgdir"/var/games
chmod 775 "$pkgdir"/var/games/emacs
chown -R root:games "$pkgdir"/var/games
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment