update argon2 to 20190702

This commit is contained in:
yixiangzhike 2020-09-01 15:14:26 +08:00
parent 0cef97381e
commit 57e183486b
3 changed files with 14 additions and 8 deletions

View File

@ -1,12 +1,13 @@
Name: argon2 Name: argon2
Version: 20161029 Version: 20190702
Release: 9 Release: 1
Summary: A password-hashing tool Summary: A password-hashing tool
License: Public Domain or ASL 2.0 License: Public Domain or ASL 2.0
URL: https://github.com/P-H-C/phc-winner-argon2 URL: https://github.com/P-H-C/phc-winner-argon2
Source0: https://github.com/P-H-C/phc-winner-argon2/archive/1c4fc41f81f358283755eea88d4ecd05e43b7fd3/phc-winner-argon2-20161029-1c4fc41.tar.gz Source0: https://github.com/P-H-C/phc-winner-argon2/archive/62358ba2123abd17fccf2a108a301d4b52c01a7c/phc-winner-argon2-20190702-62358ba.tar.gz
BuildRequires: gcc BuildRequires: gcc
BuildRequires: libargon2
Requires: libargon2%{?_isa} = %{version}-%{release} Requires: libargon2%{?_isa} = %{version}-%{release}
%description %description
@ -51,15 +52,15 @@ This package contains dynamic library for argon2
%package_help %package_help
%prep %prep
%setup -qn phc-winner-argon2-1c4fc41f81f358283755eea88d4ecd05e43b7fd3 %setup -qn phc-winner-argon2-62358ba2123abd17fccf2a108a301d4b52c01a7c
if ! grep -q 'soname,libargon2.so.*' Makefile; then if ! grep -q 'ABI_VERSION = 1' Makefile; then
: soname have changed : soname have changed
grep soname Makefile grep soname Makefile
exit 1 exit 1
fi fi
sed -e 's:lib/@HOST_MULTIARCH@:%{_lib}:;s/@UPSTREAM_VER@/%{version}/' -i libargon2.pc sed -e 's:lib/@HOST_MULTIARCH@:%{_lib}:;s/@UPSTREAM_VER@/%{version}/' -i libargon2.pc.in
sed -e '/^CFLAGS/s:^CFLAGS:LDFLAGS=%{build_ldflags}\nCFLAGS:' \ sed -e '/^CFLAGS/s:^CFLAGS:LDFLAGS=%{build_ldflags}\nCFLAGS:' \
-e 's:-O3 -Wall:%{optflags}:' \ -e 's:-O3 -Wall:%{optflags}:' \
@ -68,6 +69,8 @@ sed -e '/^CFLAGS/s:^CFLAGS:LDFLAGS=%{build_ldflags}\nCFLAGS:' \
-e 's:CFLAGS += -march=\$(OPTTARGET)::' \ -e 's:CFLAGS += -march=\$(OPTTARGET)::' \
-i Makefile -i Makefile
sed -e 's/\/x86_64-linux-gnu//g' -i Makefile
%build %build
make -j1 make -j1
@ -75,11 +78,11 @@ make -j1
%make_install %make_install
%delete_la_and_a %delete_la_and_a
install -Dpm 755 libargon2.so.* %{buildroot}%{_libdir}/
install -Dpm 644 libargon2.pc %{buildroot}%{_libdir}/pkgconfig/libargon2.pc install -Dpm 644 libargon2.pc %{buildroot}%{_libdir}/pkgconfig/libargon2.pc
install -Dpm 644 man/argon2.1 %{buildroot}%{_mandir}/man1/argon2.1 install -Dpm 644 man/argon2.1 %{buildroot}%{_mandir}/man1/argon2.1
mv %{buildroot}%{_libdir}/libargon2.so %{buildroot}%{_libdir}/libargon2.so.0 cp -p %{_libdir}/libargon2.so.0 %{buildroot}%{_libdir}
ln -s libargon2.so.0 %{buildroot}%{_libdir}/libargon2.so
%check %check
make test make test
@ -113,6 +116,9 @@ make test
%{_mandir}/man1/* %{_mandir}/man1/*
%changelog %changelog
* Tue Sep 1 2020 zhangxingliang <zhangxingliang3@huawei.com> - 20190702-1
- update to 20190702
* Sat Mar 21 2020 openEuler Buildteam <buildteam@openeuler.org> - 20161029-9 * Sat Mar 21 2020 openEuler Buildteam <buildteam@openeuler.org> - 20161029-9
- obsoletes argon2-devel - obsoletes argon2-devel

Binary file not shown.