Hi, here's updated argon2 package
The old version of the patch also was modifying linux/darwin/etc parts,
I skipped those, as deemed irrelevant herediff --git a/Makefile b/Makefile
index 837e7f7..769f053 100644
--- a/Makefile
+++ b/Makefile
@@ -66,6 +66,7 @@ KERNEL_NAME := $(shell uname -s)
MACHINE_NAME := $(shell uname -m)
LIB_NAME = argon2
+LIB_PFX=lib
PC_NAME = lib$(LIB_NAME).pc
PC_SRC = $(PC_NAME).in
@@ -88,18 +89,19 @@ ifeq ($(KERNEL_NAME), Darwin)
PC_EXTRA_LIBS ?=
endif
ifeq ($(findstring CYGWIN, $(KERNEL_NAME)), CYGWIN)
- LIB_EXT := dll
- LIB_CFLAGS := -shared -Wl,--out-implib,lib$(LIB_NAME).$(LIB_EXT).a
+ LIB_PFX = cyg
+ LIB_EXT := -$(ABI_VERSION).dll
+ LIB_CFLAGS := -shared -Wl,--out-implib,lib$(LIB_NAME).dll.a
PC_EXTRA_LIBS ?=
endif
ifeq ($(findstring MINGW, $(KERNEL_NAME)), MINGW)
- LIB_EXT := dll
- LIB_CFLAGS := -shared -Wl,--out-implib,lib$(LIB_NAME).$(LIB_EXT).a
+ LIB_EXT := .dll
+ LIB_CFLAGS := -shared -Wl,--out-implib,lib$(LIB_NAME)$(LIB_EXT).a
PC_EXTRA_LIBS ?=
endif
ifeq ($(findstring MSYS, $(KERNEL_NAME)), MSYS)
- LIB_EXT := dll
- LIB_CFLAGS := -shared -Wl,--out-implib,lib$(LIB_NAME).$(LIB_EXT).a
+ LIB_EXT := .dll
+ LIB_CFLAGS := -shared -Wl,--out-implib,lib$(LIB_NAME)$(LIB_EXT).a
PC_EXTRA_LIBS ?=
endif
ifeq ($(KERNEL_NAME), SunOS)
@@ -116,7 +118,7 @@ ifeq ($(CC), clang)
endif
endif
-LIB_SH := lib$(LIB_NAME).$(LIB_EXT)
+LIB_SH := $(LIB_PFX)$(LIB_NAME)$(LIB_EXT)
LIB_ST := lib$(LIB_NAME).a
ifdef LINKED_LIB_EXT
NAME="argon2"
VERSION=20190702
RELEASE=1
LICENSE=CC0-1.0
CATEGORY="Libs"
SUMMARY="Password-hashing function library"
DESCRIPTION="This is the reference C implementation of Argon2, a password-
hashing function that summarizes the state of the art in the design of
memory-hard functions and can be used to hash passwords for credential
storage, key derivation, or other applications."
HOMEPAGE="https://github.com/P-H-C/phc-winner-argon2"
SRC_URI="https://github.com/P-H-C/phc-winner-argon2/archive/${VERSION}/phc-winner-argon2-${VERSION}.tar.gz"
SRC_DIR="phc-winner-argon2-${VERSION}"
PATCH_URI="20190702-cygwin-dll.patch"
PKG_NAMES="argon2 libargon2_1 libargon2-devel"
argon2_CATEGORY="Utils"
argon2_SUMMARY=${SUMMARY/library/tool}
argon2_CONTENTS="usr/bin/argon2.exe usr/share/doc/"
libargon2_1_CONTENTS="usr/bin/cygargon2-1.dll"
libargon2_devel_CONTENTS="usr/include/argon2.h usr/lib/libargon2.dll.a
usr/lib/pkgconfig/libargon2.pc"
src_compile() {
lndirs
cd ${B}
cygmake OPTTARGET=${ARCH_i686+i686}${ARCH_x86_64+generic}
}
src_install() {
cd ${B}
dobin argon2.exe cygargon2-1.dll
doinclude include/argon2.h
dolib libargon2.dll.a
dopkgconfig libargon2.pc
}