# HG changeset patch # User diego # Date 1156516119 0 # Node ID 17439bdff148085fbccd0fe634ef4aa83fda9502 # Parent 771698922515a1261289cf681fcc6a5cc3d17f38 Disentangle toolame CFLAGS and LDFLAGS handling. diff -r 771698922515 -r 17439bdff148 Makefile --- a/Makefile Fri Aug 25 13:32:22 2006 +0000 +++ b/Makefile Fri Aug 25 14:28:39 2006 +0000 @@ -113,7 +113,6 @@ $(SPEEX_LIB) \ ifeq ($(TOOLAME),yes) -CFLAGS += $(TOOLAME_EXTRAFLAGS) CODEC_LIBS += $(TOOLAME_LIB) endif diff -r 771698922515 -r 17439bdff148 configure --- a/configure Fri Aug 25 13:32:22 2006 +0000 +++ b/configure Fri Aug 25 14:28:39 2006 +0000 @@ -418,7 +418,7 @@ --with-x264libdir=DIR libx264 in DIR --with-libdtslibdir=DIR libdts library in DIR (*) --with-livelibdir=DIR LIVE555 Streaming Media libraries in DIR - --with-toolamedir=DIR path to Toolame library and include file + --with-toolamelibdir=DIR Toolame library in DIR --with-xmmsplugindir=DIR XMMS plugins in DIR --with-xmmslibdir=DIR libxmms.so.1 in DIR --with-cdparanoialibdir=DIR cdparanoia libraries (libcdda_*) in DIR (*) @@ -2064,9 +2064,6 @@ --with-livelibdir=*) _livelibdir=`echo $ac_option | cut -d '=' -f 2` ;; - --with-toolamedir=*) - _toolamedir=`echo $ac_option | cut -d '=' -f 2` - ;; --with-mlibdir=*) _mlibdir=`echo $ac_option | cut -d '=' -f 2` ;; @@ -2150,6 +2147,9 @@ --with-cdparanoialibdir=*) _ld_cdparanoia=-L`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'` ;; + --with-toolamelibdir=*) + _ld_toolame=-L`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'` + ;; --with-termcaplib=*) _ld_termcap=-l`echo $ac_option | cut -d '=' -f 2` ;; @@ -5532,19 +5532,14 @@ int main(void) { toolame_init(); return 0; } EOF _toolame=no - _toolame_extraflags="" - _toolame_lib="-ltoolame" - if test -n "$_toolamedir"; then - _toolame_extraflags="-I$_toolamedir -L$_toolamedir" - fi - cc_check $_toolame_extraflags $_toolame_lib $_ld_lm && _toolame=yes + cc_check $_ld_toolame -ltoolame $_ld_lm && _toolame=yes fi if test "$_toolame" = yes ; then _def_toolame='#define HAVE_TOOLAME 1' + _toolame_lib="-ltoolame" _codecmodules="$_codecmodules toolame" else _def_toolame='#undef HAVE_TOOLAME' - _toolame_lib="" _nocodecmodules="toolame $_nocodecmodules" fi if test "$_toolamedir" ; then @@ -7435,7 +7430,6 @@ MACOSX_FRAMEWORKS = $_macosx_frameworks MACOSX_COREVIDEO = $_macosx_corevideo TOOLAME=$_toolame -TOOLAME_EXTRAFLAGS=$_toolame_extraflags TOOLAME_LIB=$_toolame_lib TWOLAME=$_twolame TWOLAME_LIB=$_twolame_lib