summaryrefslogtreecommitdiff
path: root/pcr
diff options
context:
space:
mode:
Diffstat (limited to 'pcr')
-rw-r--r--pcr/emacs-mailcrypt/PKGBUILD32
-rw-r--r--pcr/emacs-mailcrypt/destdir.patch41
-rw-r--r--pcr/emacs-mailcrypt/mailcrypt.install22
3 files changed, 95 insertions, 0 deletions
diff --git a/pcr/emacs-mailcrypt/PKGBUILD b/pcr/emacs-mailcrypt/PKGBUILD
new file mode 100644
index 000000000..8dad422c0
--- /dev/null
+++ b/pcr/emacs-mailcrypt/PKGBUILD
@@ -0,0 +1,32 @@
+# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net>
+# Maintainer (AUR): Stefan Husmann <stefan-husmann@t-online.de>
+
+_pkgname=mailcrypt
+pkgname=emacs-$_pkgname
+pkgver=3.5.9
+pkgdesc="Emacs interface to PGP and GnuPG"
+url="http://mailcrypt.sourceforge.net/"
+license=('GPL')
+
+pkgrel=2.1
+arch=(any)
+depends=(emacs)
+install=$_pkgname.install
+source=(http://downloads.sourceforge.net/sourceforge/$_pkgname/$_pkgname-$pkgver.tar.gz
+ destdir.patch)
+
+build() {
+ cd "$srcdir/$_pkgname-$pkgver"
+ patch -Np1 -i "$srcdir/destdir.patch"
+ autoreconf
+ ./configure --prefix=/usr --infodir=/usr/share/info
+ make
+}
+
+package() {
+ cd "$srcdir/$_pkgname-$pkgver"
+ make DESTDIR="$pkgdir" install
+}
+
+md5sums=('18c0dea5dde0fc73168f4815df0d9db0'
+ '805f2c6bf624c946df2eefaf0edabcb3')
diff --git a/pcr/emacs-mailcrypt/destdir.patch b/pcr/emacs-mailcrypt/destdir.patch
new file mode 100644
index 000000000..a0159cd02
--- /dev/null
+++ b/pcr/emacs-mailcrypt/destdir.patch
@@ -0,0 +1,41 @@
+diff -ruN mailcrypt-3.5.9.orig/Makefile.in mailcrypt-3.5.9/Makefile.in
+--- mailcrypt-3.5.9.orig/Makefile.in 2010-03-11 08:38:05.000000000 -0500
++++ mailcrypt-3.5.9/Makefile.in 2012-12-13 18:38:59.000000000 -0500
+@@ -77,16 +77,16 @@
+
+ install: all installdirs install-info
+ for f in $(SOURCES); do \
+- $(INSTALL_DATA) $(srcdir)/$$f $(lispdir); \
++ $(INSTALL_DATA) $(srcdir)/$$f $(DESTDIR)$(lispdir); \
+ done;
+ for f in $(OBJECTS); do \
+- $(INSTALL_DATA) $$f $(lispdir); \
++ $(INSTALL_DATA) $$f $(DESTDIR)$(lispdir); \
+ done;
+
+ # Make sure all installation directories actually exist
+ # by making them if necessary.
+ installdirs: mkinstalldirs
+- $(srcdir)/mkinstalldirs $(lispdir) $(infodir)
++ $(srcdir)/mkinstalldirs $(DESTDIR)$(lispdir) $(DESTDIR)$(infodir)
+
+ # If your install-info doesn't know how to look inside the .info file for the
+ # menu entry to add, try adding
+@@ -95,14 +95,12 @@
+
+ install-info: info
+ cd $(srcdir) && for file in $(INFOFILES); do\
+- $(INSTALL_DATA) $$file $(infodir)/$$file; \
++ $(INSTALL_DATA) $$file $(DESTDIR)$(infodir)/$$file; \
+ done
+- -$(INSTALL_INFO) --info-dir=$(infodir) mailcrypt.info
+
+ uninstall:
+- -cd $(lispdir) && rm -f $(SOURCES) $(OBJECTS)
+- -cd $(infodir) && rm -f $(INFOFILES)
+- $(INSTALL_INFO) --remove --info-dir=$(infodir) mailcrypt.info
++ -cd $(DESTDIR)$(lispdir) && rm -f $(SOURCES) $(OBJECTS)
++ -cd $(DESTDIR)$(infodir) && rm -f $(INFOFILES)
+
+ info: $(INFOFILES)
+
diff --git a/pcr/emacs-mailcrypt/mailcrypt.install b/pcr/emacs-mailcrypt/mailcrypt.install
new file mode 100644
index 000000000..3257b7338
--- /dev/null
+++ b/pcr/emacs-mailcrypt/mailcrypt.install
@@ -0,0 +1,22 @@
+infodir=usr/share/info
+filelist=(mailcrypt.info)
+
+post_install() {
+ [[ -x usr/bin/install-info ]] || return 0
+ for file in "${filelist[@]}"; do
+ install-info "$infodir/$file.gz" "$infodir/dir" 2> /dev/null
+ done
+}
+
+post_upgrade() {
+ post_install "$1"
+}
+
+pre_remove() {
+ [[ -x usr/bin/install-info ]] || return 0
+ for file in "${filelist[@]}"; do
+ install-info --delete "$infodir/$file.gz" "$infodir/dir" 2> /dev/null
+ done
+}
+
+# vim:set ts=2 sw=2 et: