0014-contrib-gcrypt-use-git-version-on-iOS.patch 4.78 KB
Newer Older
1
From 3555c6e0d1df4bbe0dbe96b14f85986f9bbea1e4 Mon Sep 17 00:00:00 2001
2 3
From: =?UTF-8?q?Felix=20Paul=20K=C3=BChne?= <fkuehne@videolan.org>
Date: Thu, 31 Oct 2013 20:42:59 +0100
Felix Paul Kühne's avatar
Felix Paul Kühne committed
4
Subject: [PATCH 14/16] contrib/gcrypt: use git version on iOS
5 6 7

---
 contrib/src/gcrypt/disable-doc-compilation.patch   | 43 ++++++++++++++++++++++
Felix Paul Kühne's avatar
Felix Paul Kühne committed
8
 contrib/src/gcrypt/rules.mak                       | 14 ++++++-
9
 .../gcrypt/work-around-libtool-limitation.patch    | 25 +++++++++++++
Felix Paul Kühne's avatar
Felix Paul Kühne committed
10
 3 files changed, 81 insertions(+), 1 deletion(-)
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
 create mode 100644 contrib/src/gcrypt/disable-doc-compilation.patch
 create mode 100644 contrib/src/gcrypt/work-around-libtool-limitation.patch

diff --git a/contrib/src/gcrypt/disable-doc-compilation.patch b/contrib/src/gcrypt/disable-doc-compilation.patch
new file mode 100644
index 0000000..e63224e
--- /dev/null
+++ b/contrib/src/gcrypt/disable-doc-compilation.patch
@@ -0,0 +1,43 @@
+From 18ac3f6a6e0ab9fe353ee8b5ab2b34ef5ce500d7 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Felix=20Paul=20K=C3=BChne?= <fkuehne@videolan.org>
+Date: Thu, 31 Oct 2013 20:34:15 +0100
+Subject: [PATCH] disable doc compilation
+
+---
+ Makefile.am  | 6 +++---
+ configure.ac | 1 -
+ 2 files changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index f1dbd09..9e0abd6 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -25,10 +25,10 @@ DISTCHECK_CONFIGURE_FLAGS = --disable-random-daemon \
+ # (A suitable gitlog-to-changelog script can be found in GnuPG master.)
+ GITLOG_TO_CHANGELOG=gitlog-to-changelog
+ 
+-DIST_SUBDIRS = m4 compat mpi cipher random src doc tests
+-SUBDIRS =         compat mpi cipher random src doc tests
++DIST_SUBDIRS = m4 compat mpi cipher random src tests
++SUBDIRS =         compat mpi cipher random src tests
+ EXTRA_DIST = autogen.sh README.GIT 					\
+-             ChangeLog-2011 scripts/ChangeLog-2011 doc/ChangeLog-2011 	\
++             ChangeLog-2011 scripts/ChangeLog-2011 	\
+              m4/ChangeLog-2011 cipher/ChangeLog-2011 src/ChangeLog-2011 \
+              random/ChangeLog-2011 tests/ChangeLog-2011 mpi/ChangeLog-2011 \
+              scripts/git-log-footer scripts/git-log-fix
+diff --git a/configure.ac b/configure.ac
+index e3471d0..6fa4ad6 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1799,7 +1799,6 @@ compat/Makefile
+ mpi/Makefile
+ cipher/Makefile
+ random/Makefile
+-doc/Makefile
+ src/Makefile
+ src/gcrypt.h
+ src/libgcrypt-config
+-- 
+1.8.3.4 (Apple Git-47)
+
diff --git a/contrib/src/gcrypt/rules.mak b/contrib/src/gcrypt/rules.mak
64
index 7e67319..8773aa1 100644
65 66 67 68
--- a/contrib/src/gcrypt/rules.mak
+++ b/contrib/src/gcrypt/rules.mak
@@ -1,6 +1,7 @@
 # GCRYPT
Felix Paul Kühne's avatar
Felix Paul Kühne committed
69
 GCRYPT_VERSION := 1.6.2
70 71 72 73 74
 GCRYPT_URL := ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-$(GCRYPT_VERSION).tar.bz2
+GCRYPT_GITURL := git://git.gnupg.org/libgcrypt.git
 
 PKGS += gcrypt
 
Felix Paul Kühne's avatar
Felix Paul Kühne committed
75
@@ -9,11 +10,22 @@ $(TARBALLS)/libgcrypt-$(GCRYPT_VERSION).tar.bz2:
76 77 78 79 80 81 82 83 84
 
 .sum-gcrypt: libgcrypt-$(GCRYPT_VERSION).tar.bz2
 
+$(TARBALLS)/libgcrypt-git.tar.xz:
+	$(call download_git,$(GCRYPT_GITURL),,d1cadd145)
+
+ifndef HAVE_IOS
 libgcrypt: libgcrypt-$(GCRYPT_VERSION).tar.bz2 .sum-gcrypt
 	$(UNPACK)
85
 	$(APPLY) $(SRC)/gcrypt/fix-amd64-assembly-on-solaris.patch
Felix Paul Kühne's avatar
Felix Paul Kühne committed
86
 	$(APPLY) $(SRC)/gcrypt/0001-Fix-assembly-division-check.patch
87 88
 	$(MOVE)
+else
89
+libgcrypt: libgcrypt-git.tar.xz
90 91 92 93 94 95 96 97
+	$(UNPACK)
+	$(APPLY) $(SRC)/gcrypt/disable-doc-compilation.patch
+	$(APPLY) $(SRC)/gcrypt/work-around-libtool-limitation.patch
+	$(MOVE)
+endif
 
 DEPS_gcrypt = gpg-error
 
98
@@ -47,6 +59,6 @@ endif
99 100
 
 .gcrypt: libgcrypt
101
 	$(RECONF)
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137
-	cd $< && $(HOSTVARS) CFLAGS="$(CFLAGS) $(GCRYPT_EXTRA_CFLAGS)" ./configure $(HOSTCONF) $(GCRYPT_CONF)
+	cd $< && $(HOSTVARS) ./configure $(HOSTCONF) $(GCRYPT_CONF)
 	cd $< && $(MAKE) install
 	touch $@
diff --git a/contrib/src/gcrypt/work-around-libtool-limitation.patch b/contrib/src/gcrypt/work-around-libtool-limitation.patch
new file mode 100644
index 0000000..df97ffb
--- /dev/null
+++ b/contrib/src/gcrypt/work-around-libtool-limitation.patch
@@ -0,0 +1,25 @@
+diff -ru libgcrypt-broken/cipher/Makefile.am libgcrypt/cipher/Makefile.am
+--- libgcrypt-broken/cipher/Makefile.am	2013-11-06 23:05:24.000000000 +0100
++++ libgcrypt/cipher/Makefile.am	2013-11-06 23:21:25.000000000 +0100
+@@ -19,6 +19,8 @@
+ 
+ # Process this file with automake to produce Makefile.in
+ 
++LIBTOOL=@LIBTOOL@ --tag=CC
++
+ EXTRA_DIST = Manifest
+ 
+ # Need to include ../src in addition to top_srcdir because gcrypt.h is
+diff -ru libgcrypt-broken/mpi/Makefile.am libgcrypt/mpi/Makefile.am
+--- libgcrypt-broken/mpi/Makefile.am	2013-11-06 23:05:24.000000000 +0100
++++ libgcrypt/mpi/Makefile.am	2013-11-06 23:22:04.000000000 +0100
+@@ -23,6 +23,9 @@
+ 
+ # Need to include ../src in addition to top_srcdir because gcrypt.h is
+ # a built header.
++
++LIBTOOL=@LIBTOOL@ --tag=CC
++
+ AM_CPPFLAGS = -I../src -I$(top_srcdir)/src
+ AM_CFLAGS = $(GPG_ERROR_CFLAGS)
+ 
-- 
138
2.3.0
139