commit a3183addd331ab05294ca8f6680e717eb66acfb5
Author: Elan Ruusamäe <[email protected]>
Date:   Sun Jan 25 19:05:39 2015 +0200

    use system libtommath/libtomcrypt bcond
    
    disabled due linking errors when enabled

 dropbear.spec       |  9 +++++++++
 system-libtom.patch | 22 ++++++++++++++++++++++
 2 files changed, 31 insertions(+)
---
diff --git a/dropbear.spec b/dropbear.spec
index c508076..8da5812 100644
--- a/dropbear.spec
+++ b/dropbear.spec
@@ -3,6 +3,7 @@
 #
 # Conditional build:
 %bcond_with    pam             # PAM authentication support
+%bcond_with    system_libtom   # use system libtommath/libtomcrypt
 
 Summary:       Dropbear - a smallish ssh2 server
 Summary(pl.UTF-8):     Dropbear - mały serwer ssh2
@@ -13,9 +14,12 @@ License:     MIT
 Group:         Applications/Networking
 Source0:       
https://matt.ucc.asn.au/dropbear/releases/%{name}-%{version}.tar.bz2
 # Source0-md5: c21a01111aa5015db038c6efdb85717d
+Patch0:                system-libtom.patch
 URL:           https://matt.ucc.asn.au/dropbear/dropbear.html
 BuildRequires: autoconf >= 2.50
 BuildRequires: automake
+%{?with_system_libtom:BuildRequires:   libtomcrypt-devel}
+%{?with_system_libtom:BuildRequires:   libtommath-devel}
 %{?with_pam:BuildRequires:     pam-devel}
 BuildRequires: zlib-devel
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -39,12 +43,17 @@ trzeba go porządnie przetestować :)
 
 %prep
 %setup -q
+%patch0 -p1
+
+%{?with_system_libtom:rm -r libtomcrypt libtommath}
 
 %build
 %{__aclocal}
 %{__autoconf}
 %{__autoheader}
 %configure \
+       %{?with_system_libtom:--disable-bundled-libtom} \
+       %{__enable_disable_not system_libtom bundled-libtom} \
        %{?with_pam:--enable-pam}
 %{__make}
 
diff --git a/system-libtom.patch b/system-libtom.patch
new file mode 100644
index 0000000..60e36b4
--- /dev/null
+++ b/system-libtom.patch
@@ -0,0 +1,22 @@
+--- dropbear-2014.66/configure.ac~     2014-10-23 16:43:38.000000000 +0300
++++ dropbear-2014.66/configure.ac      2015-01-25 19:00:39.840166231 +0200
+@@ -660,6 +660,7 @@
+ AC_EXEEXT
+ 
+ # XXX there must be a nicer way to do this
++if test $BUNDLED_LIBTOM = 1 ; then
+ AS_MKDIR_P(libtomcrypt/src/ciphers/aes)
+ AS_MKDIR_P(libtomcrypt/src/ciphers/safer)
+ AS_MKDIR_P(libtomcrypt/src/ciphers/twofish)
+@@ -710,8 +711,10 @@
+ AS_MKDIR_P(libtomcrypt/src/pk/pkcs1)
+ AS_MKDIR_P(libtomcrypt/src/pk/rsa)
+ AS_MKDIR_P(libtomcrypt/src/prngs)
++LIBTOM_FILES="libtomcrypt/Makefile libtommath/Makefile"
++fi
+ AC_CONFIG_HEADER(config.h)
+-AC_CONFIG_FILES(Makefile libtomcrypt/Makefile libtommath/Makefile)
++AC_CONFIG_FILES(Makefile $LIBTOM_FILES)
+ AC_OUTPUT
+ 
+ AC_MSG_NOTICE()
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/dropbear.git/commitdiff/a3183addd331ab05294ca8f6680e717eb66acfb5

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to