diff options
author | 2009-08-16 20:56:21 +0200 | |
---|---|---|
committer | 2009-08-16 21:14:59 +0200 | |
commit | 1cdc11fdf2b5f01c3dd9370f5adc3b05159fe55c (patch) | |
tree | 4637a616e1efbb19eadcbe8f7546e324e6f1bd7b /libsidplay2/sidplay-libs-2.1.0/builders/resid-builder/acinclude.m4 | |
parent | 1e7c5ae1fa743a73fbc0c1831201271691c6ae95 (diff) |
moved libsidplay2
Diffstat (limited to 'libsidplay2/sidplay-libs-2.1.0/builders/resid-builder/acinclude.m4')
-rw-r--r-- | libsidplay2/sidplay-libs-2.1.0/builders/resid-builder/acinclude.m4 | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/libsidplay2/sidplay-libs-2.1.0/builders/resid-builder/acinclude.m4 b/libsidplay2/sidplay-libs-2.1.0/builders/resid-builder/acinclude.m4 new file mode 100644 index 00000000..5fcfce10 --- /dev/null +++ b/libsidplay2/sidplay-libs-2.1.0/builders/resid-builder/acinclude.m4 @@ -0,0 +1,39 @@ +dnl ------------------------------------------------------------------------- +dnl Try to find resid includes and library. +dnl ------------------------------------------------------------------------- + +AC_DEFUN(SID2_FIND_LIBRESID, +[ + if test "$SID2_LIB_CHECK" != "0"; then + MY_FIND_LIB(resid,,,resid/sid.h sid.h,SID *mySID,sid2_header) + else + MY_FIND_LIB_NO_CHECK(resid,resid/sid.h sid.h,sid2_header) + fi + + dnl list exported variables here so end up in makefile + AC_SUBST(LIBRESID_CXXFLAGS) + AC_SUBST(LIBRESID_LDFLAGS) + + if test "$sid2_header" = sid.h; then + AC_DEFINE(HAVE_USER_RESID,, + [Define this to \#include sid.h instead of resid/resid.h] + ) + fi + + if test "$SID2_LIB_CHECK" != "0"; then + AC_MSG_CHECKING([for extended resid features]) + MY_TRY_COMPILE($LIBRESID_CXXFLAGS,$LIBRESID_LDFLAGS,$sid2_header,SID mySID; + mySID.mute(0,true),sid2_works) + + if test "$sid2_works" = NO; then + AC_MSG_RESULT(no); + # Found non patched version of resid + AC_MSG_ERROR([ +resid requires patching to function with sidplay2. +Patches are available from http://sidplay2.sourceforge.net + ]) + else + AC_MSG_RESULT(yes); + fi + fi +]) |