$OpenBSD: patch-configure,v 1.2 2018/04/27 15:43:20 jasper Exp $
Index: configure
--- configure.orig
+++ configure
@@ -12357,7 +12357,7 @@ if eval \${$as_ac_Lib+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lvorbisfile -lvorbis -logg -lm  $LIBS"
+LIBS="-lvorbisfile -lvorbis -logg $LIBM  $LIBS"
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -12447,7 +12447,7 @@ fi
 
     if test x$have_flac_export = xyes; then
         LIBS_SAVED="$LIBS"
-        LIBS="-lFLAC"
+        LIBS="-lFLAC -logg $LIBM"
         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libflac so-name version >= $libflac_ver" >&5
 $as_echo_n "checking for libflac so-name version >= $libflac_ver... " >&6; }
         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -12493,7 +12493,7 @@ if ${ac_cv_lib_FLAC_FLAC__stream_decoder_new+:} false;
   $as_echo_n "(cached) " >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lFLAC  $LIBS"
+LIBS="-lFLAC -logg $LIBM  $LIBS"
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
