diff options
author | 2010-02-20 20:28:11 +0000 | |
---|---|---|
committer | 2010-02-20 20:28:11 +0000 | |
commit | 4ad567344dcca4529bd5ba66d26460875a5cf15d (patch) | |
tree | a15df040a67bebd90f08e53b14436c6e48a19139 | |
parent | alphabetically sort the list of supported controllers; while here, (diff) | |
download | wireguard-openbsd-4ad567344dcca4529bd5ba66d26460875a5cf15d.tar.xz wireguard-openbsd-4ad567344dcca4529bd5ba66d26460875a5cf15d.zip |
unbreak build for NOPIC systems; noticed, help and ok deraadt@
-rw-r--r-- | usr.bin/ssh/Makefile.inc | 6 | ||||
-rw-r--r-- | usr.bin/ssh/lib/Makefile | 3 | ||||
-rw-r--r-- | usr.bin/ssh/ssh-pkcs11.c | 9 |
3 files changed, 16 insertions, 2 deletions
diff --git a/usr.bin/ssh/Makefile.inc b/usr.bin/ssh/Makefile.inc index 172440d287f..04606afd41d 100644 --- a/usr.bin/ssh/Makefile.inc +++ b/usr.bin/ssh/Makefile.inc @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile.inc,v 1.35 2010/02/09 08:55:31 markus Exp $ +# $OpenBSD: Makefile.inc,v 1.36 2010/02/20 20:28:11 markus Exp $ CFLAGS+= -I${.CURDIR}/.. @@ -18,6 +18,10 @@ CDIAGFLAGS+= -Wshadow #CFLAGS+= -DJPAKE CFLAGS+= -DENABLE_PKCS11 +.include <bsd.own.mk> +.ifndef NOPIC +CFLAGS+= -DHAVE_DLOPEN +.endif .include <bsd.obj.mk> diff --git a/usr.bin/ssh/lib/Makefile b/usr.bin/ssh/lib/Makefile index 584403b49f0..f0e1b005ed6 100644 --- a/usr.bin/ssh/lib/Makefile +++ b/usr.bin/ssh/lib/Makefile @@ -1,6 +1,7 @@ -# $OpenBSD: Makefile,v 1.60 2010/02/08 13:05:27 markus Exp $ +# $OpenBSD: Makefile,v 1.61 2010/02/20 20:28:11 markus Exp $ .PATH: ${.CURDIR}/.. +.include "${.CURDIR}/../Makefile.inc" LIB= ssh WANTLINT= diff --git a/usr.bin/ssh/ssh-pkcs11.c b/usr.bin/ssh/ssh-pkcs11.c index f82454329ac..39ba7849f47 100644 --- a/usr.bin/ssh/ssh-pkcs11.c +++ b/usr.bin/ssh/ssh-pkcs11.c @@ -430,6 +430,7 @@ pkcs11_fetch_keys(struct pkcs11_provider *p, CK_ULONG slotidx, Key ***keysp, return (0); } +#ifdef HAVE_DLOPEN /* register a new provider, fails if provider already exists */ int pkcs11_add_provider(char *provider_id, char *pin, Key ***keyp) @@ -542,3 +543,11 @@ fail: dlclose(handle); return (-1); } +#else +int +pkcs11_add_provider(char *provider_id, char *pin, Key ***keyp) +{ + error("dlopen() not supported"); + return (-1); +} +#endif |