Skip to content

Instantly share code, notes, and snippets.

@Malvineous
Created July 18, 2016 12:09
Show Gist options
  • Save Malvineous/ac42e1c819162c3d31aa87c0431a10b1 to your computer and use it in GitHub Desktop.
Save Malvineous/ac42e1c819162c3d31aa87c0431a10b1 to your computer and use it in GitHub Desktop.
adplay-unix proposed configure patch
diff --git a/configure.ac b/configure.ac
index 9d8db36..8a9cd10 100644
--- a/configure.ac
+++ b/configure.ac
@@ -28,9 +28,9 @@ AC_CHECK_HEADERS([getopt.h], ,
AC_SUBST(GETOPT_SOURCES, [getopt.c getopt1.c getopt.h]))
# Save compiler flags and set up for compiling test programs
-oldldflags="$LDFLAGS"
+oldlibs="$LIBS"
oldcppflags="$CPPFLAGS"
-LDFLAGS="$LDFLAGS $adplug_LIBS"
+LIBS="$LDFLAGS $adplug_LIBS"
CPPFLAGS="$CPPFLAGS $adplug_CFLAGS"
# Check if AdPlug is installed and linked correctly
@@ -77,7 +77,7 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <adplug/surroundopl.h>], [CSurroundopl
AC_MSG_RESULT([yes]), AC_MSG_RESULT([no - AdPlug >= 2.2 required]))
# Restore flags after compiling test programs
-LDFLAGS="$oldldflags"
+LIBS="$oldlibs"
CPPFLAGS="$oldcppflags"
##### Output mechanism checks #####
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment