Magellan Linux

Annotation of /trunk/core/argon2/argon2-20171227-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 30636 - (hide annotations) (download)
Thu Feb 8 09:50:56 2018 UTC (6 years, 4 months ago) by niro
File size: 1497 byte(s)
-several build fixes
1 niro 30631 # $Id$
2    
3     PNAME="argon2"
4     PVER="20171227"
5     PBUILD="r1"
6    
7     PCAT="app-crypt"
8    
9     DESCRIPTION="A password-hashing function."
10     HOMEPAGE="https://github.com/P-H-C/phc-winner-argon2"
11    
12     DEPEND=">= virtual/glibc"
13    
14     SRCFILE="${PNAME}-${PVER}.tar.gz"
15 niro 30632 SRCDIR="${BUILDDIR}/phc-winner-argon2-${PVER}"
16 niro 30631
17 niro 30633 msetfeature "!check" # makefile provide no check function
18 niro 30631 sminclude multilib mbuild
19    
20     SRC_URI=(
21     https://github.com/P-H-C/phc-winner-argon2/archive/${PVER}/${SRCFILE}
22     mirror://${PNAME}/${SRCFILE}
23     )
24    
25     UP2SEPERATOR="\/"
26     UP2DATE="updatecmd https://github.com/P-H-C/phc-winner-argon2/releases | highesttarball gz"
27    
28 niro 30636 src_prepare()
29     {
30     munpack ${SRCFILE} || die
31    
32     # fix libdir
33     all-abis 'sed -i "s:^\(LIBRARY_REL =\).*:\1 $(mlibdir):"' ${SRCDIR}-$(mabi)/Makefile || die
34     }
35    
36 niro 30631 src_compile()
37     {
38     mmake OPTTARGET=none || die
39     }
40    
41     src_install()
42     {
43 niro 30636 mmake OPTTARGET=none DESTDIR=${BINDIR} install || die
44 niro 30631
45     # create and install a custon pkgconfig file
46 niro 30636 cat > ${BUILDDIR}/libargon2.pc << 'EOF'
47     prefix=/usr
48     exec_prefix=${prefix}
49     libdir=${prefix}/@@MLIBDIR@@
50     includedir=${prefix}/include
51    
52     Name: libargon2
53     Description: Development libraries for libargon2
54     Version: @@PVER@@
55     Libs: -L${libdir} -largon2 -lrt -ldl
56     Cflags:
57     URL: https://github.com/P-H-C/phc-winner-argon2
58     EOF
59    
60 niro 30631 all-abis minstalldir /usr/'$(mlibdir)'/pkgconfig || die
61 niro 30636 all-abis minstallfile ${BUILDDIR}/libargon2.pc /usr/'$(mlibdir)'/pkgconfig/ || die
62     all-abis sed -i -e 's:@@MLIBDIR@@:$(mlibdir):g' -e "s:@@PVER@@:${PVER}:g" ${BINDIR}/usr/'$(mlibdir)'/pkgconfig/libargon2.pc || die
63 niro 30631 }