summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Palimaka <kensington@gentoo.org>2019-03-16 15:51:26 +1100
committerMichael Palimaka <kensington@gentoo.org>2019-03-16 15:55:31 +1100
commit60c0897b68f5e4a80e733a7ef0716b4bba421762 (patch)
treedab5b7ee79b1336bbf5379a79a8838599780855a /app-crypt/argon2
parentmetadata: gitignore repoman (diff)
downloadgentoo-60c0897b68f5e4a80e733a7ef0716b4bba421762.tar.gz
gentoo-60c0897b68f5e4a80e733a7ef0716b4bba421762.tar.bz2
gentoo-60c0897b68f5e4a80e733a7ef0716b4bba421762.zip
app-crypt/argon2: revision bump
* Port to EAPI 7 * Install documentation * Respect CC * Install pkg-config file Closes: https://bugs.gentoo.org/674918 Package-Manager: Portage-2.3.62, Repoman-2.3.12 Signed-off-by: Michael Palimaka <kensington@gentoo.org>
Diffstat (limited to 'app-crypt/argon2')
-rw-r--r--app-crypt/argon2/argon2-20171227-r1.ebuild40
1 files changed, 40 insertions, 0 deletions
diff --git a/app-crypt/argon2/argon2-20171227-r1.ebuild b/app-crypt/argon2/argon2-20171227-r1.ebuild
new file mode 100644
index 000000000000..c7176327af16
--- /dev/null
+++ b/app-crypt/argon2/argon2-20171227-r1.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs
+
+DESCRIPTION="Password hashing software that won the Password Hashing Competition (PHC)"
+HOMEPAGE="https://github.com/P-H-C/phc-winner-argon2"
+SRC_URI="https://github.com/P-H-C/phc-winner-argon2/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="|| ( Apache-2.0 CC0-1.0 )"
+SLOT="0/1"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-fbsd"
+IUSE="static-libs"
+
+S="${WORKDIR}/phc-winner-${P}"
+
+DOCS=( argon2-specs.pdf CHANGELOG.md README.md )
+
+src_prepare() {
+ default
+ if ! use static-libs; then
+ sed -i -e 's/LIBRARIES = \$(LIB_SH) \$(LIB_ST)/LIBRARIES = \$(LIB_SH)/' Makefile || die "sed failed!"
+ fi
+ sed -i -e 's/-O3 //' -e 's/-g //' -e "s/-march=\$(OPTTARGET) /${CFLAGS} /" -e 's/CFLAGS += -march=\$(OPTTARGET)//' Makefile || die "sed failed"
+
+ sed -i -e "s/lib\/@HOST_MULTIARCH@/$(get_libdir)/" -e "s/@UPSTREAM_VER@/${PV}/" lib${PN}.pc || die
+
+ tc-export CC
+}
+
+src_install() {
+ emake DESTDIR="${ED}" LIBRARY_REL="$(get_libdir)" install
+ einstalldocs
+ doman man/${PN}.1
+
+ insinto /usr/$(get_libdir)/pkgconfig
+ doins lib${PN}.pc
+}