summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libre/your-freedom/PKGBUILD40
-rw-r--r--libre/your-freedom/post-recieve-hook.sh56
-rw-r--r--pcr/emacs-lucid/PKGBUILD4
-rw-r--r--pcr/emacs-lucid/emacs-24.3-giflib5.patch71
4 files changed, 152 insertions, 19 deletions
diff --git a/libre/your-freedom/PKGBUILD b/libre/your-freedom/PKGBUILD
index 6f2b209d5..1c15ca6ed 100644
--- a/libre/your-freedom/PKGBUILD
+++ b/libre/your-freedom/PKGBUILD
@@ -1,25 +1,31 @@
-# Maintainer: Parabola Project <dev@list.parabolagnulinux.org>
+# Maintainer: Parabola Project <dev@lists.parabolagnulinux.org>
+
pkgname=your-freedom
-pkgver=$(LC_ALL=C date -u +%Y%m%d)
-pkgrel=1
+pkgver=...
+_gitver=...
pkgdesc="This package conflicts with every nonfree package known to date to ensure your system is free."
-arch=('any')
-url="https://parabolagnulinux.org"
license=('GPL3')
+url="https://projects.parabolagnulinux.org/blacklist.git"
+
+pkgrel=1
+arch=('any')
groups=('base')
install=${pkgname}.install
-source=(blacklist-${pkgver}.txt::https://projects.parabolagnulinux.org/blacklist.git/plain/blacklist.txt)
+
+makedepends=(librelib)
+source=(blacklist-${_gitver}.txt::https://projects.parabolagnulinux.org/blacklist.git/plain/blacklist.txt?id=${_gitver})
+md5sums=('5fd14982619414fea1882b351607291e')
package() {
- conflicts=($(cut -d: -f1,2 blacklist-${pkgver}.txt | \
- sed "s/:$//" | \
- grep -v ":" | \
- grep -v '^#' | \
- sort -u
- ))
- cd ${srcdir}
- install -d ${pkgdir}/usr/share/doc/${pkgname}
- install -m644 blacklist-${pkgver}.txt ${pkgdir}/usr/share/doc/${pkgname}/
-}
+ cd "$srcdir"
-md5sums=('5fd14982619414fea1882b351607291e')
+ conflicts=($(
+ < blacklist-${pkgver}.txt \
+ libreblacklist normalize |
+ cut -d: -f1,2 |
+ sed -n 's/:$//p' |
+ sort -u
+ ))
+
+ install -Dm644 blacklist-${_gitver}.txt "$pkgdir"/usr/share/doc/${pkgname}/blacklist.txt
+}
diff --git a/libre/your-freedom/post-recieve-hook.sh b/libre/your-freedom/post-recieve-hook.sh
new file mode 100644
index 000000000..4da0cd147
--- /dev/null
+++ b/libre/your-freedom/post-recieve-hook.sh
@@ -0,0 +1,56 @@
+#!/bin/bash
+
+# Get this first thing
+newpkgver_date=$(LC_ALL=C date -u +%Y%m%d)
+
+. "$(librelib messages)"
+setup_traps
+lock 9 "${0}.lock" "Waiting for previous run of %q to finish" "$0"
+
+. "$(librelib conf)"
+load_files libretools
+check_vars libretools WORKDIR ABSLIBRERECV ABSLIBRESEND
+
+# Start in the blacklist.git directory
+newgitver=$(git log -n1 --format='%H' master -- blacklist.txt)
+
+# Get the ABSLibre tree
+gitget -f -p "$ABSLIBRESEND" checkout "$ABSLIBRERECV" "$WORKDIR/abslibre"
+cd "$WORKDIR/abslibre/libre/your-freedom"
+
+# Figure out info about the last version of your-freedom
+oldgitver=$(sed -n 's/^_gitver=//p' PKGBUILD)
+oldpkgver=$(sed -n 's/^pkgver=//p' PKGBUILD)
+oldpkgver_date=${oldpkgver%%.*}
+oldpkgver_rel=${oldpkgver#${oldpkgver_date}}; oldpkgver_rel=${oldpkgver_rel#.} oldpkgver_rel=${oldpkgver_rel:-0}
+
+# Make sure we actually have changes
+if [[ "$newgitver" == "$oldgitver" ]]; then
+ msg 'blacklist.txt has not changed, nothing to do'
+ exit 0
+fi
+
+# Handle doing multiple versions in the same day
+if [[ "$newpkgver_date" == "$oldpkgver_date" ]]; then
+ declare -i newpkgver_rel=${oldpkgver_rel}+1
+ newpkgver=${newpkgver_date}.${newpkgver_rel}
+else
+ newpkgver=${newpkgver_date}
+fi
+
+# Update the PKGBUILD
+sed -i -e 's|^pkgver=.*|pkgver=${newpkgver}|' \
+ -e 's|^_gitver=.*|_gitver=${newgitver}|' \
+ -e 's|^pkgrel=.*|pkgrel=1|' \
+ PKGBUILD
+updpkgsums
+git add PKGBUILD
+git commit -m 'Update libre/your-freedom'
+
+# Build the new package
+makepkg
+librestage libre
+
+# Publish the updates
+git push
+librerelease
diff --git a/pcr/emacs-lucid/PKGBUILD b/pcr/emacs-lucid/PKGBUILD
index 1e3be71a4..e7ff10972 100644
--- a/pcr/emacs-lucid/PKGBUILD
+++ b/pcr/emacs-lucid/PKGBUILD
@@ -5,7 +5,7 @@
_pkgname=emacs
pkgname=emacs-lucid
pkgver=24.3
-pkgrel=5
+pkgrel=7
pkgdesc="The extensible, customizable, self-documenting real-time display editor"
arch=('i686' 'x86_64')
url="http://www.gnu.org/software/emacs/emacs.html"
@@ -16,7 +16,7 @@ source=(ftp://ftp.gnu.org/gnu/emacs/$_pkgname-$pkgver.tar.xz{,.sig}
emacs-24.3-giflib5.patch)
md5sums=('ea9ed000ca165280265aabb55b9afbd7'
'SKIP'
- '560cdf463299e059c5fadf474bcba218')
+ 'ccbe4e77440ff6ea56c8532ebc960446')
pkgdesc+=", with the Lucid X11 toolkit"
provides=("$_pkgname=$pkgver")
diff --git a/pcr/emacs-lucid/emacs-24.3-giflib5.patch b/pcr/emacs-lucid/emacs-24.3-giflib5.patch
index b8571abb2..f58c31907 100644
--- a/pcr/emacs-lucid/emacs-24.3-giflib5.patch
+++ b/pcr/emacs-lucid/emacs-24.3-giflib5.patch
@@ -24,3 +24,74 @@
if (!gif)
{
image_error ("Cannot open memory source `%s'", img->spec, Qnil);
+@@ -7225,7 +7225,11 @@
+ if (!check_image_size (f, gif->SWidth, gif->SHeight))
+ {
+ image_error ("Invalid image size (see `max-image-size')", Qnil, Qnil);
++#if GIFLIB_MAJOR >= 5 && GIFLIB_MINOR >= 1
++ fn_DGifCloseFile (gif, NULL);
++#else
+ fn_DGifCloseFile (gif);
++#endif
+ return 0;
+ }
+
+@@ -7234,7 +7238,11 @@
+ if (rc == GIF_ERROR || gif->ImageCount <= 0)
+ {
+ image_error ("Error reading `%s'", img->spec, Qnil);
++#if GIFLIB_MAJOR >= 5 && GIFLIB_MINOR >= 1
++ fn_DGifCloseFile (gif, NULL);
++#else
+ fn_DGifCloseFile (gif);
++#endif
+ return 0;
+ }
+
+@@ -7246,7 +7254,11 @@
+ {
+ image_error ("Invalid image number `%s' in image `%s'",
+ image_number, img->spec);
++#if GIFLIB_MAJOR >= 5 && GIFLIB_MINOR >= 1
++ fn_DGifCloseFile (gif, NULL);
++#else
+ fn_DGifCloseFile (gif);
++#endif
+ return 0;
+ }
+ }
+@@ -7264,14 +7276,22 @@
+ if (!check_image_size (f, width, height))
+ {
+ image_error ("Invalid image size (see `max-image-size')", Qnil, Qnil);
++#if GIFLIB_MAJOR >= 5 && GIFLIB_MINOR >= 1
++ fn_DGifCloseFile (gif, NULL);
++#else
+ fn_DGifCloseFile (gif);
++#endif
+ return 0;
+ }
+
+ /* Create the X image and pixmap. */
+ if (!x_create_x_image_and_pixmap (f, width, height, 0, &ximg, &img->pixmap))
+ {
++#if GIFLIB_MAJOR >= 5 && GIFLIB_MINOR >= 1
++ fn_DGifCloseFile (gif, NULL);
++#else
+ fn_DGifCloseFile (gif);
++#endif
+ return 0;
+ }
+
+@@ -7447,7 +7467,11 @@
+ Fcons (make_number (gif->ImageCount),
+ img->lisp_data));
+
++#if GIFLIB_MAJOR >= 5 && GIFLIB_MINOR >= 1
++ fn_DGifCloseFile (gif, NULL);
++#else
+ fn_DGifCloseFile (gif);
++#endif
+
+ /* Maybe fill in the background field while we have ximg handy. */
+ if (NILP (image_spec_value (img->spec, QCbackground, NULL)))