summaryrefslogtreecommitdiff
path: root/package/ca-certificates/patches
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2009-08-22 22:45:52 +0200
committerPhil Sutter <phil@nwl.cc>2009-08-22 22:51:38 +0200
commitba0c06d2bb46e087f1782eb76573e0bef735c062 (patch)
tree5a1457c71ffba8be861365cc45ad4c02443ba6ca /package/ca-certificates/patches
parentc823698fc91f462eae028ba7e0dfcb9cc0f3e98c (diff)
new package ca-certificates
"Oh boy, here it comes ..."
Diffstat (limited to 'package/ca-certificates/patches')
-rw-r--r--package/ca-certificates/patches/patch-Makefile12
-rw-r--r--package/ca-certificates/patches/patch-sbin_Makefile9
-rw-r--r--package/ca-certificates/patches/patch-sbin_update-ca-certificates48
3 files changed, 69 insertions, 0 deletions
diff --git a/package/ca-certificates/patches/patch-Makefile b/package/ca-certificates/patches/patch-Makefile
new file mode 100644
index 000000000..24e9fab9c
--- /dev/null
+++ b/package/ca-certificates/patches/patch-Makefile
@@ -0,0 +1,12 @@
+ fix for the completely empty DESTDIR
+--- ca-certificates-20090814.orig/Makefile 2009-07-08 23:18:57.000000000 +0200
++++ ca-certificates-20090814/Makefile 2009-08-22 20:36:42.614405912 +0200
+@@ -17,7 +17,7 @@ clean:
+
+ install:
+ for dir in $(SUBDIRS); do \
+- mkdir $(DESTDIR)/$(CERTSDIR)/$$dir; \
++ mkdir -p $(DESTDIR)/$(CERTSDIR)/$$dir; \
+ $(MAKE) -C $$dir install CERTSDIR=$(DESTDIR)/$(CERTSDIR)/$$dir; \
+ done
+ for dir in sbin; do \
diff --git a/package/ca-certificates/patches/patch-sbin_Makefile b/package/ca-certificates/patches/patch-sbin_Makefile
new file mode 100644
index 000000000..ff59e4856
--- /dev/null
+++ b/package/ca-certificates/patches/patch-sbin_Makefile
@@ -0,0 +1,9 @@
+ fix for the completely empty DESTDIR
+--- ca-certificates-20090814.orig/sbin/Makefile 2007-02-02 07:23:19.000000000 +0100
++++ ca-certificates-20090814/sbin/Makefile 2009-08-22 20:37:17.581921717 +0200
+@@ -8,4 +8,5 @@ all:
+ clean:
+
+ install:
++ mkdir -p $(DESTDIR)/usr/sbin
+ install -m755 update-ca-certificates $(DESTDIR)/usr/sbin/
diff --git a/package/ca-certificates/patches/patch-sbin_update-ca-certificates b/package/ca-certificates/patches/patch-sbin_update-ca-certificates
new file mode 100644
index 000000000..dd6288366
--- /dev/null
+++ b/package/ca-certificates/patches/patch-sbin_update-ca-certificates
@@ -0,0 +1,48 @@
+ - prefix absolute paths with $DESTDIR
+ - subtract DESTDIR from the link name when linking
+ - add DESTDIR again when catting certs together (Yay.)
+--- ca-certificates-20090814.orig/sbin/update-ca-certificates 2009-07-08 23:23:12.000000000 +0200
++++ ca-certificates-20090814/sbin/update-ca-certificates 2009-08-22 21:10:24.210186675 +0200
+@@ -37,11 +37,11 @@ do
+ shift
+ done
+
+-CERTSCONF=/etc/ca-certificates.conf
+-CERTSDIR=/usr/share/ca-certificates
+-LOCALCERTSDIR=/usr/local/share/ca-certificates
++CERTSCONF=${DESTDIR}/etc/ca-certificates.conf
++CERTSDIR=${DESTDIR}/usr/share/ca-certificates
++LOCALCERTSDIR=${DESTDIR}/usr/local/share/ca-certificates
+ CERTBUNDLE=ca-certificates.crt
+-ETCCERTSDIR=/etc/ssl/certs
++ETCCERTSDIR=${DESTDIR}/etc/ssl/certs
+
+ cleanup() {
+ rm -f "$TEMPBUNDLE"
+@@ -60,7 +60,7 @@ REMOVED="$(mktemp -t "ca-certificates.tm
+ # in /etc/ssl/certs to the certificate file and its inclusion into the
+ # bundle.
+ add() {
+- CERT="$1"
++ CERT="${1##${DESTDIR}}"
+ PEM="$ETCCERTSDIR/$(basename "$CERT" .crt | sed -e 's/ /_/g' \
+ -e 's/[()]/=/g' \
+ -e 's/,/_/g').pem"
+@@ -69,7 +69,7 @@ add() {
+ ln -sf "$CERT" "$PEM"
+ echo +$PEM >> "$ADDED"
+ fi
+- cat "$CERT" >> "$TEMPBUNDLE"
++ cat "${DESTDIR}/$CERT" >> "$TEMPBUNDLE"
+ }
+
+ remove() {
+@@ -146,7 +146,7 @@ fi
+
+ echo "$ADDED_CNT added, $REMOVED_CNT removed; done."
+
+-HOOKSDIR=/etc/ca-certificates/update.d
++HOOKSDIR=${DESTDIR}/etc/ca-certificates/update.d
+ echo -n "Running hooks in $HOOKSDIR...."
+ VERBOSE_ARG=
+ [ "$verbose" = 0 ] || VERBOSE_ARG=--verbose