diff --git a/dtool/Config.pp b/dtool/Config.pp index 8f24bd39c7..351dc81230 100644 --- a/dtool/Config.pp +++ b/dtool/Config.pp @@ -322,6 +322,9 @@ #define RAD_MSS_LIBS Mss32 #defer HAVE_RAD_MSS $[libtest $[RAD_MSS_LPATH],$[RAD_MSS_LIBS]] +// Is Panda using the mpg123 library to play mp3, requiring it be built? +#define USE_MPG123 1 + // Is Gtk-- installed? How should we run the gtkmm-config program? // This matters only to programs in PANDATOOL. #define GTKMM_CONFIG gtkmm-config diff --git a/dtool/pptempl/Global.pp b/dtool/pptempl/Global.pp index 5aae3a4180..8c088088fd 100644 --- a/dtool/pptempl/Global.pp +++ b/dtool/pptempl/Global.pp @@ -208,6 +208,9 @@ #define AUDIO_IPATH $[RAD_MSS_IPATH] #define AUDIO_LPATH $[RAD_MSS_LPATH] #define AUDIO_LIBS $[RAD_MSS_LIBS] + + // Miles will play mp3, so we dont need the mpg123 lib + #define USE_MPG123 #endif #if $[HAVE_AUDIO] @@ -243,6 +246,7 @@ $[or $[not $[DIRECTORY_IF_IPC]],$[HAVE_IPC]], \ $[or $[not $[DIRECTORY_IF_NET]],$[HAVE_NET]], \ $[or $[not $[DIRECTORY_IF_AUDIO]],$[HAVE_AUDIO]], \ + $[or $[not $[DIRECTORY_IF_MPG123]],$[USE_MPG123]], \ $[or $[not $[DIRECTORY_IF_INTERROGATE]],$[HAVE_INTERROGATE]], \ 1 ] @@ -273,6 +277,7 @@ $[or $[not $[TARGET_IF_IPC]],$[HAVE_IPC]], \ $[or $[not $[TARGET_IF_NET]],$[HAVE_NET]], \ $[or $[not $[TARGET_IF_AUDIO]],$[HAVE_AUDIO]], \ + $[or $[not $[TARGET_IF_MPG123]],$[USE_MPG123]], \ 1 ] // This takes advantage of the above two variables to get the actual diff --git a/panda/src/mpg123/Sources.pp b/panda/src/mpg123/Sources.pp index fbea81b8da..031c2b1531 100644 --- a/panda/src/mpg123/Sources.pp +++ b/panda/src/mpg123/Sources.pp @@ -1,3 +1,5 @@ +#define DIRECTORY_IF_MPG123 yes + #begin static_lib_target #define TARGET mpg123 #define SOURCES \