diff options
| author | Roy Marples <roy@marples.name> | 2014-06-05 13:53:20 +0000 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2014-06-05 13:53:20 +0000 |
| commit | 6c9c45832452e256002b65fb178b1e49ac3d27a2 (patch) | |
| tree | 53b42a94659a884829b425e461b52d126241d45f /configure | |
| parent | c9ce5cc4ff17930660ca89c742b90e45673708da (diff) | |
| download | dhcpcd-6c9c45832452e256002b65fb178b1e49ac3d27a2.tar.xz | |
be32enc is missing on OpenBSD, so provide a configure test.
Fix compile on OpenBSD.
Diffstat (limited to 'configure')
| -rwxr-xr-x | configure | 21 |
1 files changed, 20 insertions, 1 deletions
@@ -716,7 +716,7 @@ case "$POLLTS" in yes) ;; ppoll) - echo "#define pollts ppoll" >>$CONFIG_H + echo "#define pollts ppoll" >>$CONFIG_H ;; pselect) echo "COMPAT_SRCS+= compat/pselect.c" >>$CONFIG_MK @@ -751,6 +751,25 @@ if [ "$LOG_PERROR" = no ]; then echo "#define syslog psyslog" >>$CONFIG_H fi +if [ -z "$BE64ENC" ]; then + printf "Testing for be64enc ... " + cat <<EOF >_be64enc.c +#include <sys/endian.h> +int main(void) { + be64enc(NULL, 0); +} +EOF + if $XCC _be64enc.c -o _be64enc 2>/dev/null; then + BE64ENC=yes + else + BE64ENC=no + fi + echo "$BE64ENC" +fi +if [ "$BE64ENC" == no ]; then + echo "#include \"compat/endian.h\"" >>$CONFIG_H +fi + if [ -z "$MD5" ]; then MD5_LIB= printf "Testing for MD5Init ... " |
