[packages/libxcrypt] - updated to 4.4.0 - removed outdated noWerror,libc-lock,link patches - added xcrypt patch (still in
qboosh
qboosh at pld-linux.org
Fri Nov 30 18:38:44 CET 2018
commit c311c8361b99216274b805b4596c42213a707d92
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Fri Nov 30 18:42:53 2018 +0100
- updated to 4.4.0
- removed outdated noWerror,libc-lock,link patches
- added xcrypt patch (still install as libxcrypt, not glibc libcrypt replacement)
libxcrypt-libc-lock.patch | 40 ---------
libxcrypt-link.patch | 10 ---
libxcrypt-noWerror.patch | 11 ---
libxcrypt-xcrypt.patch | 209 ++++++++++++++++++++++++++++++++++++++++++++++
libxcrypt.spec | 43 +++++-----
5 files changed, 231 insertions(+), 82 deletions(-)
---
diff --git a/libxcrypt.spec b/libxcrypt.spec
index e9e11f3..0b25718 100644
--- a/libxcrypt.spec
+++ b/libxcrypt.spec
@@ -1,21 +1,19 @@
Summary: Crypt Library for DES, MD5, and Blowfish
Summary(pl.UTF-8): Biblioteka szyfrująca hasła obsługująca DES, MD5 i Blowfish
Name: libxcrypt
-Version: 3.1.1
+Version: 4.4.0
Release: 1
-License: LGPL v2.1+ (library), LGPL v2.1+/Public Domain (plugins)
+License: LGPL v2.1+
Group: Libraries
#Source0Download: https://github.com/besser82/libxcrypt/releases
Source0: https://github.com/besser82/libxcrypt/archive/v%{version}/%{name}-%{version}.tar.gz
-# Source0-md5: 7eff183695f0dc4744b0f4bc8334eae9
-Patch0: %{name}-noWerror.patch
-Patch1: %{name}-libc-lock.patch
-Patch2: %{name}-link.patch
+# Source0-md5: 13e9f41b9881956c529a028b636ff22b
+Patch0: %{name}-xcrypt.patch
URL: https://github.com/besser82/libxcrypt
-BuildRequires: autoconf >= 2.50
-BuildRequires: automake >= 1:1.7
+BuildRequires: autoconf >= 2.62
+BuildRequires: automake >= 1:1.14
BuildRequires: libtool >= 2:2
-BuildRequires: sed >= 4.0
+BuildRequires: pkgconfig >= 1:0.27
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%undefine __cxx
@@ -62,8 +60,6 @@ Ten pakiet zawiera statyczną wersję biblioteki libxcrypt.
%prep
%setup -q
%patch0 -p1
-%patch1 -p1
-%patch2 -p1
%build
%{__libtoolize}
@@ -72,21 +68,23 @@ Ten pakiet zawiera statyczną wersję biblioteki libxcrypt.
%{__autoheader}
%{__automake}
%configure \
- --libdir=/%{_lib}
+ --includedir=%{_includedir}/xcrypt \
+ --disable-obsolete-api \
+ --disable-werror \
+ --disable-xcrypt-compat-files
%{__make}
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_libdir}
+install -d $RPM_BUILD_ROOT/%{_lib}
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
-%{__mv} $RPM_BUILD_ROOT/%{_lib}/libxcrypt.{so,la,a} $RPM_BUILD_ROOT%{_libdir}
-%{__sed} -i -e 's#/%{_lib}#%{_libdir}#g' $RPM_BUILD_ROOT%{_libdir}/libxcrypt.la
+%{__mv} $RPM_BUILD_ROOT%{_libdir}/libxcrypt.so.* $RPM_BUILD_ROOT/%{_lib}
ln -snf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libxcrypt.so.*.*.*) $RPM_BUILD_ROOT%{_libdir}/libxcrypt.so
-%{__rm} $RPM_BUILD_ROOT/%{_lib}/xcrypt/*.{la,a}
+%{__rm} $RPM_BUILD_ROOT%{_mandir}/man3/crypt{,_r,_ra,_rn}.3*
%clean
rm -rf $RPM_BUILD_ROOT
@@ -96,18 +94,21 @@ rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
-# COPYING specifies licenses for particular plugins
-%doc COPYING ChangeLog NEWS README*
+%doc AUTHORS ChangeLog LICENSING NEWS README.md THANKS TODO.md
%attr(755,root,root) /%{_lib}/libxcrypt.so.*.*.*
%attr(755,root,root) %ghost /%{_lib}/libxcrypt.so.2
-%dir /%{_lib}/xcrypt
-%attr(755,root,root) /%{_lib}/xcrypt/libxcrypt_*.so*
%files devel
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/libxcrypt.so
%{_libdir}/libxcrypt.la
-%{_includedir}/xcrypt.h
+%{_includedir}/xcrypt
+%{_pkgconfigdir}/libcrypt.pc
+%{_pkgconfigdir}/libxcrypt.pc
+%{_mandir}/man3/crypt_checksalt.3*
+%{_mandir}/man3/crypt_gensalt*.3*
+%{_mandir}/man3/crypt_preferred_method.3*
+%{_mandir}/man5/crypt.5*
%files static
%defattr(644,root,root,755)
diff --git a/libxcrypt-libc-lock.patch b/libxcrypt-libc-lock.patch
deleted file mode 100644
index 150ff99..0000000
--- a/libxcrypt-libc-lock.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-diff -urN libxcrypt-3.0.2/src/crypt_util.c libxcrypt-3.0.2.new/src/crypt_util.c
---- libxcrypt-3.0.2/src/crypt_util.c 2007-10-25 15:17:46.000000000 +0200
-+++ libxcrypt-3.0.2.new/src/crypt_util.c 2013-02-04 12:45:20.560191479 +0100
-@@ -30,8 +30,7 @@
- #endif
- #include <string.h>
-
--#include <bits/libc-lock.h>
--#define __libc_lock_t pthread_mutex_t
-+#include <pthread.h>
-
- #ifndef STATIC
- #define STATIC static
-@@ -265,7 +264,7 @@
- */
- struct crypt_data _ufc_foobar;
-
--__libc_lock_define_initialized (static, _ufc_tables_lock)
-+static pthread_mutex_t _ufc_tables_lock = PTHREAD_MUTEX_INITIALIZER;
-
- #ifdef DEBUG
-
-@@ -362,7 +361,7 @@
- #endif
-
- if(small_tables_initialized == 0) {
-- __libc_lock_lock (_ufc_tables_lock);
-+ pthread_mutex_lock (&_ufc_tables_lock);
- if(small_tables_initialized)
- goto small_tables_done;
-
-@@ -471,7 +470,7 @@
- }
- small_tables_initialized = 1;
- small_tables_done:
-- __libc_lock_unlock(_ufc_tables_lock);
-+ pthread_mutex_unlock (&_ufc_tables_lock);
- }
-
- /*
diff --git a/libxcrypt-link.patch b/libxcrypt-link.patch
deleted file mode 100644
index 147c5d1..0000000
--- a/libxcrypt-link.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- libxcrypt-3.1.1/plugins/blowfish/Makefile.am.orig 2015-05-13 01:29:46.000000000 +0200
-+++ libxcrypt-3.1.1/plugins/blowfish/Makefile.am 2017-04-10 19:13:39.158177658 +0200
-@@ -16,6 +16,7 @@
-
- TESTS = blowfish-test
-
-+libxcrypt_2a_la_LIBADD = -ldl
- libxcrypt_2a_la_LDFLAGS = -version-info 1:0:0 \
- -Wl,--version-script=$(top_srcdir)/plugins/plugin.map
-
diff --git a/libxcrypt-noWerror.patch b/libxcrypt-noWerror.patch
deleted file mode 100644
index bade05f..0000000
--- a/libxcrypt-noWerror.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- libxcrypt-3.1.1/configure.ac.orig 2015-05-13 01:29:46.000000000 +0200
-+++ libxcrypt-3.1.1/configure.ac 2017-04-10 18:59:27.731520714 +0200
-@@ -38,7 +38,7 @@
- EXTRA_CFLAGS="$EXTRA_CFLAGS -Wcast-qual -Winline"
- EXTRA_CFLAGS="$EXTRA_CFLAGS -Wmissing-declarations -Wmissing-prototypes"
- EXTRA_CFLAGS="$EXTRA_CFLAGS -Wnested-externs -Wshadow -Wstrict-prototypes"
-- EXTRA_CFLAGS="$EXTRA_CFLAGS -Wundef -Wpointer-arith -Werror"
-+ EXTRA_CFLAGS="$EXTRA_CFLAGS -Wundef -Wpointer-arith"
- fi
- AC_SUBST(EXTRA_CFLAGS)
-
diff --git a/libxcrypt-xcrypt.patch b/libxcrypt-xcrypt.patch
new file mode 100644
index 0000000..7470d9e
--- /dev/null
+++ b/libxcrypt-xcrypt.patch
@@ -0,0 +1,209 @@
+--- libxcrypt-4.4.0/Makefile.am.orig 2018-11-19 20:39:12.000000000 +0100
++++ libxcrypt-4.4.0/Makefile.am 2018-11-29 20:46:27.369590776 +0100
+@@ -37,17 +37,13 @@
+ alg-yescrypt-sysendian.h byteorder.h crypt-common.h \
+ crypt-obsolete.h crypt-port.h test-des-cases.h
+
+-if ENABLE_XCRYPT_COMPAT_FILES
+ include_HEADERS = xcrypt.h
+-else
+-noinst_HEADERS += xcrypt.h
+-endif
+
+
+ noinst_PROGRAMS = gen-des-tables
+
+-lib_LTLIBRARIES = libcrypt.la
+-libcrypt_la_SOURCES = \
++lib_LTLIBRARIES = libxcrypt.la
++libxcrypt_la_SOURCES = \
+ alg-des.c alg-des-tables.c alg-gost3411-2012-core.c \
+ alg-gost3411-2012-hmac.c alg-hmac-sha1.c alg-md4.c alg-md5.c \
+ alg-sha1.c alg-sha256.c alg-sha512.c alg-yescrypt-opt.c \
+@@ -75,23 +71,23 @@
+
+ # Build libcrypt.so.2 if obsolete APIs are excluded, libcrypt.so.1 otherwise.
+ if ENABLE_OBSOLETE_API
+-libcrypt_la_VERSION = 2:0:1
++libxcrypt_la_VERSION = 2:0:1
+ else
+-libcrypt_la_VERSION = 2:0:0
++libxcrypt_la_VERSION = 2:0:0
+ endif
+
+-libcrypt_la_LDFLAGS = -version-info $(libcrypt_la_VERSION)
++libxcrypt_la_LDFLAGS = -version-info $(libxcrypt_la_VERSION)
+
+ if HAVE_VSCRIPT
+-libcrypt_la_LDFLAGS += $(VSCRIPT_LDFLAGS),$(builddir)/libcrypt.map
++libxcrypt_la_LDFLAGS += $(VSCRIPT_LDFLAGS),$(builddir)/libcrypt.map
+ endif
+
+-libcrypt_la_LDFLAGS += $(UNDEF_FLAG) $(TEXT_RELOC_FLAG)
++libxcrypt_la_LDFLAGS += $(UNDEF_FLAG) $(TEXT_RELOC_FLAG)
+
+-libcrypt_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_LIBCRYPT
++libxcrypt_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_LIBCRYPT
+
+ CONFIG_STATUS_DEPENDENCIES = libcrypt.minver
+-EXTRA_libcrypt_la_DEPENDENCIES = libcrypt.map
++EXTRA_libxcrypt_la_DEPENDENCIES = libcrypt.map
+ CLEANFILES = Makefile.deps.T Makefile.deps \
+ libcrypt.map libcrypt.map.T \
+ crypt-symbol-vers.h crypt-symbol-vers.h.T \
+@@ -151,9 +147,9 @@
+ uninstall-hook-xcrypt-static
+ install-exec-hook-xcrypt-static:
+ cd $(DESTDIR)$(libdir) && \
+- $(LN_S) libcrypt.a libxcrypt.a
++ $(LN_S) libxcrypt.a libcrypt.a
+ uninstall-hook-xcrypt-static:
+- -rm -f $(DESTDIR)$(libdir)/libxcrypt.a
++ -rm -f $(DESTDIR)$(libdir)/libcrypt.a
+ endif
+
+ if ENABLE_SHARED
+@@ -166,9 +162,9 @@
+ uninstall-hook-xcrypt-shared
+ install-exec-hook-xcrypt-shared:
+ cd $(DESTDIR)$(libdir) && \
+- $(LN_S) libcrypt.so libxcrypt.so
++ $(LN_S) libxcrypt.so libcrypt.so
+ uninstall-hook-xcrypt-shared:
+- -rm -f $(DESTDIR)$(libdir)/libxcrypt.so
++ -rm -f $(DESTDIR)$(libdir)/libcrypt.so
+ endif
+ endif
+
+@@ -195,7 +191,7 @@
+ uninstall-hook-libstatic
+ install-exec-hook-libstatic:
+ cd $(DESTDIR)$(libdir) && \
+- $(LN_S) libcrypt.a libowcrypt.a
++ $(LN_S) libxcrypt.a libowcrypt.a
+ uninstall-hook-libstatic:
+ -rm -f $(DESTDIR)$(libdir)/libowcrypt.a
+ endif
+@@ -208,8 +204,8 @@
+ uninstall-hook-libshared
+ install-exec-hook-libshared:
+ cd $(DESTDIR)$(libdir) && \
+- $(LN_S) libcrypt.so libowcrypt.so && \
+- $(LN_S) libcrypt.so.1 libowcrypt.so.1
++ $(LN_S) libxcrypt.so libowcrypt.so && \
++ $(LN_S) libxcrypt.so.1 libowcrypt.so.1
+ uninstall-hook-libshared:
+ -rm -f $(DESTDIR)$(libdir)/libowcrypt.so \
+ $(DESTDIR)$(libdir)/libowcrypt.so.1
+@@ -231,7 +227,7 @@
+ test-getrandom-interface test-getrandom-fallbacks
+
+ if ENABLE_OBSOLETE_API
+-libcrypt_la_SOURCES += crypt-des-obsolete.c
++libxcrypt_la_SOURCES += crypt-des-obsolete.c
+ check_PROGRAMS += test-des-obsolete test-des-obsolete_r
+ endif
+
+@@ -252,7 +248,7 @@
+ EXTRA_DIST += test-symbols-static.sh test-symbols-compat.sh test-symbols-renames.sh
+
+ AM_TESTS_ENVIRONMENT = \
+- lib_la="./libcrypt.la"; lib_map="$(srcdir)/libcrypt.map.in"; \
++ lib_la="./libxcrypt.la"; lib_map="$(srcdir)/libcrypt.map.in"; \
+ CC="$(CC)"; CPP="$(CPP)"; \
+ CPPFLAGS="$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES)"; \
+ CPPFLAGS="$${CPPFLAGS} $(AM_CPPFLAGS) $(CPPFLAGS)"; \
+@@ -267,7 +263,7 @@
+ # Refer to object files that are linked into libxcrypt with the
+ # qualified name, libcrypt_la-foobar.lo, to prevent them from
+ # being compiled a second time.
+-COMMON_TEST_OBJECTS = libcrypt_la-crypt-common.lo libcrypt.la
++COMMON_TEST_OBJECTS = libxcrypt_la-crypt-common.lo libxcrypt.la
+
+ test_crypt_bcrypt_LDADD = $(COMMON_TEST_OBJECTS)
+ test_crypt_des_LDADD = $(COMMON_TEST_OBJECTS)
+@@ -293,53 +289,53 @@
+ # These tests call internal APIs that may not be accessible from the
+ # fully linked shared library.
+ test_alg_des_LDADD = \
+- libcrypt_la-alg-des.lo \
+- libcrypt_la-alg-des-tables.lo \
++ libxcrypt_la-alg-des.lo \
++ libxcrypt_la-alg-des-tables.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_gost3411_2012_LDADD = \
+- libcrypt_la-alg-gost3411-2012-core.lo \
+- libcrypt_la-alg-gost3411-2012-hmac.lo \
++ libxcrypt_la-alg-gost3411-2012-core.lo \
++ libxcrypt_la-alg-gost3411-2012-hmac.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_gost3411_2012_hmac_LDADD = \
+- libcrypt_la-alg-gost3411-2012-core.lo \
+- libcrypt_la-alg-gost3411-2012-hmac.lo \
++ libxcrypt_la-alg-gost3411-2012-core.lo \
++ libxcrypt_la-alg-gost3411-2012-hmac.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_hmac_sha1_LDADD = \
+- libcrypt_la-alg-sha1.lo \
+- libcrypt_la-alg-hmac-sha1.lo \
++ libxcrypt_la-alg-sha1.lo \
++ libxcrypt_la-alg-hmac-sha1.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_md4_LDADD = \
+- libcrypt_la-alg-md4.lo \
++ libxcrypt_la-alg-md4.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_md5_LDADD = \
+- libcrypt_la-alg-md5.lo \
++ libxcrypt_la-alg-md5.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_pbkdf_hmac_sha256_LDADD = \
+- libcrypt_la-alg-sha256.lo \
++ libxcrypt_la-alg-sha256.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_sha1_LDADD = \
+- libcrypt_la-alg-sha1.lo \
++ libxcrypt_la-alg-sha1.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_sha256_LDADD = \
+- libcrypt_la-alg-sha256.lo \
++ libxcrypt_la-alg-sha256.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_alg_sha512_LDADD = \
+- libcrypt_la-alg-sha512.lo \
++ libxcrypt_la-alg-sha512.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_crypt_gost_yescrypt_LDADD = \
+- libcrypt_la-alg-gost3411-2012-core.lo \
+- libcrypt_la-alg-gost3411-2012-hmac.lo \
+- libcrypt_la-alg-sha256.lo \
+- libcrypt_la-alg-yescrypt-common.lo \
+- libcrypt_la-alg-yescrypt-opt.lo \
+- libcrypt_la-crypt-yescrypt.lo \
++ libxcrypt_la-alg-gost3411-2012-core.lo \
++ libxcrypt_la-alg-gost3411-2012-hmac.lo \
++ libxcrypt_la-alg-sha256.lo \
++ libxcrypt_la-alg-yescrypt-common.lo \
++ libxcrypt_la-alg-yescrypt-opt.lo \
++ libxcrypt_la-crypt-yescrypt.lo \
+ $(COMMON_TEST_OBJECTS)
+
+ test_getrandom_interface_LDADD = \
+- libcrypt_la-randombytes.lo \
++ libxcrypt_la-randombytes.lo \
+ $(COMMON_TEST_OBJECTS)
+ test_getrandom_fallbacks_LDADD = \
+- libcrypt_la-randombytes.lo \
++ libxcrypt_la-randombytes.lo \
+ $(COMMON_TEST_OBJECTS)
+
+ if HAVE_LD_WRAP
+--- libxcrypt-4.4.0/libxcrypt.pc.in.orig 2018-11-19 20:39:12.000000000 +0100
++++ libxcrypt-4.4.0/libxcrypt.pc.in 2018-11-29 20:47:35.179590003 +0100
+@@ -11,5 +11,5 @@
+ Name: @PACKAGE@
+ Version: @VERSION@
+ Description: Extended crypt library for DES, MD5, Blowfish and others
+-Libs: -L${libdir} -lcrypt
++Libs: -L${libdir} -lxcrypt
+ Cflags: -I${includedir}
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/libxcrypt.git/commitdiff/c311c8361b99216274b805b4596c42213a707d92
More information about the pld-cvs-commit
mailing list