From 7d352f54940f79fdab7b506924f34222f25480a6 Mon Sep 17 00:00:00 2001 From: Alexandre Ratchov Date: Fri, 13 Mar 2020 19:06:18 +0100 Subject: [PATCH] Include bsd/bsd.h necessary if --with-libbsd is used --- bsd-compat/bsd-compat.h | 4 ++++ configure | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/bsd-compat/bsd-compat.h b/bsd-compat/bsd-compat.h index 853f171..5ecc771 100644 --- a/bsd-compat/bsd-compat.h +++ b/bsd-compat/bsd-compat.h @@ -1,6 +1,10 @@ #ifndef BSD_COMPAT_H #define BSD_COMPAT_H +#ifdef USE_LIBBSD +#include +#endif + #ifndef HAVE_ISSETUGID #define issetugid _sndio_issetugid int issetugid(void); diff --git a/configure b/configure index 22bfbda..fc0dcab 100755 --- a/configure +++ b/configure @@ -237,7 +237,7 @@ fi # if [ $libbsd = yes ]; then # no arc4random as libbsd has a questionable implementation - defs="$defs -DHAVE_STRLCPY -DHAVE_STRLCAT -DHAVE_STRTONUM" + defs="$defs -DUSE_LIBBSD -DHAVE_STRLCPY -DHAVE_STRLCAT -DHAVE_STRTONUM" ldadd="$ldadd -lbsd" fi