From aa947c9474ad83aa9315bc585d1f0b79060fee61 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Thu, 7 Nov 2013 12:58:33 +0100 Subject: BUILD: Split configure.engines down to a single file per engine. This is the first part of allowing engines to be added dynamically. They are placed into a folder in engines/ which must contain a file named "configure.engine" to add the engine, which is pulled into the top level configure script automatically. --- configure | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index cb0b8902fc..4825cdc498 100755 --- a/configure +++ b/configure @@ -97,7 +97,9 @@ add_feature() { _srcdir=`dirname $0` # Read list of engines -. $_srcdir/engines/configure.engines +for i in $_srcdir/engines/*/configure.engine; do + . "$i" +done # # Default settings -- cgit v1.2.3 From 00c27a28f91cc2bbf512461e69c86be998462728 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Thu, 7 Nov 2013 12:58:34 +0100 Subject: BUILD: Split engines/plugins_table header down to a file per engine. This is the third and final commit enabling fully pluggable engines. Now providing an engine folder contains a configure.engine, engine.mk and engine-plugin.h file, it will be picked up automatically by the configure script. --- configure | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'configure') diff --git a/configure b/configure index 4825cdc498..2bad89a87d 100755 --- a/configure +++ b/configure @@ -4382,3 +4382,14 @@ include \$(srcdir)/Makefile EOF fi + +echo "Creating engines/plugins_table.h" +cat > engines/plugins_table.h << EOF +/* This file is automatically generated by configure */ +/* DO NOT EDIT MANUALLY */ +// This file is being included by "base/plugins.cpp" +EOF + +for i in $_srcdir/engines/*/engine-plugin.h; do + cat $i >> engines/plugins_table.h +done -- cgit v1.2.3 From 1ac01d2333af11d403ef84dd5192abb18814e5b3 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Thu, 7 Nov 2013 12:58:34 +0100 Subject: BUILD: Remove need for engine-plugin.h in engines. This is now generated automatically by the configure script from the engine directory names. --- configure | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 2bad89a87d..1832383a25 100755 --- a/configure +++ b/configure @@ -4390,6 +4390,13 @@ cat > engines/plugins_table.h << EOF // This file is being included by "base/plugins.cpp" EOF -for i in $_srcdir/engines/*/engine-plugin.h; do - cat $i >> engines/plugins_table.h +for i in $_srcdir/engines/*; do + if [ -d $i ]; then + j=`echo ${i#$_srcdir/engines/} | tr '[:lower:]' '[:upper:]'` + cat >> engines/plugins_table.h << EOF +#if PLUGIN_ENABLED_STATIC($j) +LINK_PLUGIN($j) +#endif +EOF + fi done -- cgit v1.2.3 From ef85456859e466adc8913041e4f31809485c45ab Mon Sep 17 00:00:00 2001 From: D G Turner Date: Thu, 7 Nov 2013 12:58:34 +0100 Subject: BUILD: Remove need for engine.mk in each engine directory. Each engine now only has to provide a single configure.engine file adding the engine into the configure script, which then produces the required other files automatically. --- configure | 40 +++++++++++++++++++++++++++++++++++++--- 1 file changed, 37 insertions(+), 3 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 1832383a25..bf8649a9b8 100755 --- a/configure +++ b/configure @@ -4383,6 +4383,40 @@ EOF fi +echo "Creating engines/engines.mk" +cat > engines/engines.mk << EOF +# This file is automatically generated by configure +# DO NOT EDIT MANUALLY +# This file is being included by "Makefile.common" +EOF + +for engine in $_engines; do + j=`echo $engine | tr '[:lower:]' '[:upper:]'` + if test "`get_engine_sub $engine`" = "no" ; then + # main engine + cat >> engines/engines.mk << EOF + +ifdef ENABLE_$j +DEFINES += -DENABLE_$j=\$(ENABLE_$j) +MODULES += engines/$engine +EOF + + for subeng in `get_engine_subengines $engine` ; do + k=`echo $subeng | tr '[:lower:]' '[:upper:]'` + cat >> engines/engines.mk << EOF + +ifdef ENABLE_$k +DEFINES += -DENABLE_$k +endif +EOF + done + + cat >> engines/engines.mk << EOF +endif +EOF + fi +done + echo "Creating engines/plugins_table.h" cat > engines/plugins_table.h << EOF /* This file is automatically generated by configure */ @@ -4390,9 +4424,9 @@ cat > engines/plugins_table.h << EOF // This file is being included by "base/plugins.cpp" EOF -for i in $_srcdir/engines/*; do - if [ -d $i ]; then - j=`echo ${i#$_srcdir/engines/} | tr '[:lower:]' '[:upper:]'` +for engine in $_engines; do + if test "`get_engine_sub $engine`" = "no" ; then + j=`echo $engine | tr '[:lower:]' '[:upper:]'` cat >> engines/plugins_table.h << EOF #if PLUGIN_ENABLED_STATIC($j) LINK_PLUGIN($j) -- cgit v1.2.3 From 19a20ad71fb8b57504f54786b39ba481dd1400b0 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Thu, 7 Nov 2013 12:58:34 +0100 Subject: BUILD: Create engines/ dir if necessary, to fix out-of-tree builds --- configure | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'configure') diff --git a/configure b/configure index bf8649a9b8..e474490efb 100755 --- a/configure +++ b/configure @@ -4383,6 +4383,10 @@ EOF fi +# Ensure engines folder exists prior to trying to generate +# files into it (used for out-of-tree-builds) +mkdir -p engines + echo "Creating engines/engines.mk" cat > engines/engines.mk << EOF # This file is automatically generated by configure -- cgit v1.2.3 From ffce805fb2b116ef1d4f03540158d42b3fcd5e80 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Thu, 7 Nov 2013 12:58:35 +0100 Subject: BUILD: Add code to maintain ordering of engines in generated files. This is mainly "cosmetic" to keep the SCUMM engine and subengines at the top of the various files, but probably a good idea to prevent any subtle regressions associated with changing the order. --- configure | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'configure') diff --git a/configure b/configure index e474490efb..d454591f08 100755 --- a/configure +++ b/configure @@ -4199,8 +4199,18 @@ for engine in $_engines; do fi done -# Prepare the information to be shown +# Sort engines to place our headline engine at start... +# No technical reason, just historical convention +headline_engine=scumm +_sorted_engines="${headline_engine}" for engine in $_engines; do + if test "${engine}" != "${headline_engine}" ; then + _sorted_engines="${_sorted_engines} ${engine}" + fi +done + +# Prepare the information to be shown +for engine in $_sorted_engines; do if test "`get_engine_sub $engine`" = "no" ; then # It's a main engine prepare_engine_build_strings $engine @@ -4394,7 +4404,7 @@ cat > engines/engines.mk << EOF # This file is being included by "Makefile.common" EOF -for engine in $_engines; do +for engine in $_sorted_engines; do j=`echo $engine | tr '[:lower:]' '[:upper:]'` if test "`get_engine_sub $engine`" = "no" ; then # main engine @@ -4428,7 +4438,7 @@ cat > engines/plugins_table.h << EOF // This file is being included by "base/plugins.cpp" EOF -for engine in $_engines; do +for engine in $_sorted_engines; do if test "`get_engine_sub $engine`" = "no" ; then j=`echo $engine | tr '[:lower:]' '[:upper:]'` cat >> engines/plugins_table.h << EOF -- cgit v1.2.3 From 5686d606f0c7d766a37992075e8e7b8f1fae486e Mon Sep 17 00:00:00 2001 From: Willem Jan Palenstijn Date: Thu, 2 Jan 2014 00:39:47 +0100 Subject: BUILD: Support libedit readline wrapper This is used in Mac OS X. Thanks to waltervn for pointing this out and testing. --- configure | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'configure') diff --git a/configure b/configure index d454591f08..e954ad9417 100755 --- a/configure +++ b/configure @@ -3667,6 +3667,25 @@ fi if test "$_readline" = yes ; then LIBS="$LIBS $READLINE_LIBS $_READLINE_LIBS" INCLUDES="$INCLUDES $READLINE_CFLAGS" + + # + # Check the type of rl_completion_entry_function. + # It can be int(*)(const char *, int) or char *(*)(const char *, int). + # + cat > $TMPC << EOF +#include +#include +#include + +int readline_completionFunction(const char *, int); + +int main(void) { + char *x = readline(""); + rl_completion_entry_function = &readline_completionFunction; +} +EOF + cc_check -c && add_line_to_config_h '#define USE_READLINE_INT_COMPLETION' + fi define_in_config_h_if_yes "$_readline" 'USE_READLINE' -- cgit v1.2.3 From e3502c8f53f8cce7546134b1697f04211fc67b50 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Fri, 10 Jan 2014 21:41:15 +0000 Subject: CONFIGURE: Add workaround for GCC bug in Dreamcast toolchain. --- configure | 2 ++ 1 file changed, 2 insertions(+) (limited to 'configure') diff --git a/configure b/configure index e954ad9417..117d44e48e 100755 --- a/configure +++ b/configure @@ -2423,6 +2423,8 @@ if test -n "$_host"; then CXXFLAGS="$CXXFLAGS -fschedule-insns2" CXXFLAGS="$CXXFLAGS -fomit-frame-pointer" CXXFLAGS="$CXXFLAGS -fdelete-null-pointer-checks" + # no-delayed-branch is a workaround for GCC bug #42841 - "SH: Assembler complains pcrel too far." + CXXFLAGS="$CXXFLAGS -fno-delayed-branch" _backend="dc" _build_scalers=no _mad=yes -- cgit v1.2.3 From 0af3db72c54d99c49a926d65b4e7596823996404 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Sat, 18 Jan 2014 12:56:39 +0000 Subject: CONFIGURE: Disable taskbar integration for Dreamcast. This caused an exception if a error() call occurs, rather than a clean exit. This occurred in the defaultErrorHandler() function of engines/engine.cpp, probably due to g_system->getTaskbarManager() returning a null pointer. --- configure | 1 + 1 file changed, 1 insertion(+) (limited to 'configure') diff --git a/configure b/configure index 117d44e48e..db78feb43e 100755 --- a/configure +++ b/configure @@ -2427,6 +2427,7 @@ if test -n "$_host"; then CXXFLAGS="$CXXFLAGS -fno-delayed-branch" _backend="dc" _build_scalers=no + _taskbar=no _mad=yes _zlib=yes add_line_to_config_mk 'ronindir = /usr/local/ronin' -- cgit v1.2.3 From a2313aef6635bb553e6bded3e1bd9ee7f2cf3621 Mon Sep 17 00:00:00 2001 From: Max Lingua Date: Fri, 10 Jan 2014 18:17:32 -0500 Subject: configure: enhanced PS2 support --- configure | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) (limited to 'configure') diff --git a/configure b/configure index db78feb43e..f6fbad5ffe 100755 --- a/configure +++ b/configure @@ -1378,6 +1378,9 @@ ps2) _host_os=ps2 _host_cpu=mips64r5900el _host_alias=ee + # PS2 bogus dirs: they actually depend on launch medium + datadir='host:data' + docdir='host:docs' ;; ps3) _host_os=ps3 @@ -2634,6 +2637,8 @@ if test -n "$_host"; then DEFINES="$DEFINES -DDISABLE_DOSBOX_OPL" DEFINES="$DEFINES -DDISABLE_SID" DEFINES="$DEFINES -DDISABLE_NES_APU" + CXXFLAGS="$CXXFLAGS -fno-exceptions" + CXXFLAGS="$CXXFLAGS -fno-rtti" _backend="ps2" _build_scalers=no _mt32emu=no @@ -2641,10 +2646,12 @@ if test -n "$_host"; then # This trick doesn't work for tremor right now, as the PS2 port the resulting library # libtremor, while our code later on expects it to be called libvorbisidec. # TODO: Enable tremor, e.g. by adding -ltremor or by renaming the lib. + _tremor=yes _mad=yes _zlib=yes # HACK to fix compilation of C source files for now. - add_line_to_config_mk 'CC = ee-gcc' + add_line_to_config_mk 'CC := ee-gcc' + add_line_to_config_mk 'CFLAGS := -std=c99 -W -Wno-unused-parameter -Wconversion -pedantic -G2 -s -O2 -Wuninitialized' # HACK to fix linking for now. It seems ee-g++ does not handle linking correctly. LD=ee-gcc @@ -3162,9 +3169,10 @@ POST_OBJS_FLAGS := -Wl,--export-all-symbols -Wl,--no-whole-archive -Wl,--out-im ;; ps2) _elf_loader=yes + DEFINES="$DEFINES -DUNCACHED_PLUGINS" _mak_plugins=' -LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/main_prog.ld -PLUGIN_LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/plugin.ld -lstdc++ -lc +LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/main_prog.ld +PLUGIN_LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -Wl,-T$(srcdir)/backends/plugins/ps2/plugin.ld -lstdc++ -lc ' ;; psp) @@ -3300,6 +3308,8 @@ if test "$_tremor" = yes && test "$_vorbis" = no; then if test "$_tremolo" = yes ; then add_line_to_config_h '#define USE_TREMOLO' LIBS="$LIBS $TREMOR_LIBS -ltremolo" + elif test "$_host" = ps2 ; then + LIBS="-ltremor $LIBS" else LIBS="$LIBS $TREMOR_LIBS -lvorbisidec" fi @@ -4055,6 +4065,10 @@ case $_backend in # without a scummvm sub directory. DEFINES="$DEFINES -DPLUGIN_DIRECTORY=\\\"$libdir\\\"" ;; + ps2) + # PS2 bogus dir: it actually depends on launch medium + DEFINES="$DEFINES -DPLUGIN_DIRECTORY=\\\"host:plugins\\\"" + ;; *) DEFINES="$DEFINES -DPLUGIN_DIRECTORY=\\\"$libdir/scummvm\\\"" ;; -- cgit v1.2.3 From eff22cb43d22b0f47ac2bf5063916639a632705d Mon Sep 17 00:00:00 2001 From: AReim1982 Date: Fri, 22 Nov 2013 15:13:56 +0100 Subject: WII: Implement changes needed by DevKitPPC R26 and later This changes makes ScummVM compilable with newer versions of DevKitPPC. ScummVM can be linked against the original libogc and libfat. That makes some newer WiiMotes work, improves audio-/video-playback and contains various improvements. --- configure | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index cb0b8902fc..8e9854434d 100755 --- a/configure +++ b/configure @@ -1426,7 +1426,7 @@ webos) wii) _host_os=wii _host_cpu=ppc - _host_alias=powerpc-gekko + _host_alias=powerpc-eabi ;; wince) _host_os=wince @@ -2704,6 +2704,7 @@ if test -n "$_host"; then _backend="wii" _build_scalers=no _vkeybd=yes + _taskbar=no _port_mk="backends/platform/wii/wii.mk" add_line_to_config_mk 'GAMECUBE = 0' add_line_to_config_h '#define AUDIO_REVERSE_STEREO' -- cgit v1.2.3 From 4412e12debd77a5cef60054d2ad437a180d00817 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Tue, 21 Jan 2014 19:01:28 +0100 Subject: BUILD: Rename libunity support variable to "USE_UNITY" instead of "USE_TASKBAR_UNITY". This makes it consistent with other library support variables. --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index db78feb43e..adeba28612 100755 --- a/configure +++ b/configure @@ -3727,7 +3727,7 @@ if test "$_libunity" = yes ; then LIBS="$LIBS $LIBUNITY_LIBS" INCLUDES="$INCLUDES $LIBUNITY_CFLAGS" fi -define_in_config_h_if_yes "$_libunity" 'USE_TASKBAR_UNITY' +define_in_config_h_if_yes "$_libunity" 'USE_UNITY' fi echo "$_libunity" -- cgit v1.2.3 From db07a1cfacdb67be02a64dcecfb22e773a733fca Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Tue, 21 Jan 2014 19:19:27 +0100 Subject: BUILD: Auto detect taskbar support. Formerly the taskbar support was *always* enabled except when the backend or user specified that it should be disabled. This causes nasty crashes for backends which do not have any taskbar support (like DC, Tizen and probably more which simply did not disable it so far) when defaultErrorHandler was called for example (Mass Add is also broken for those). The SDL (and derived backends) worked around missing taskbar support by simply faking a dummy taskbar implementation (but still claiming in configure that we feature taskbar integration, ouch). To avoid all non-SDL backends from manually specifying _taskbar=no I added some auto detection code which simply only enables taskbar support in case ScummVM is built on Win32 or libunity is present. --- configure | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'configure') diff --git a/configure b/configure index adeba28612..d47a460622 100755 --- a/configure +++ b/configure @@ -126,7 +126,7 @@ _opengl=auto _opengles=auto _readline=auto _freetype2=auto -_taskbar=yes +_taskbar=auto _updates=no _libunity=auto # Default option behavior yes/no @@ -2427,7 +2427,6 @@ if test -n "$_host"; then CXXFLAGS="$CXXFLAGS -fno-delayed-branch" _backend="dc" _build_scalers=no - _taskbar=no _mad=yes _zlib=yes add_line_to_config_mk 'ronindir = /usr/local/ronin' @@ -2686,7 +2685,6 @@ if test -n "$_host"; then _backend="tizen" _port_mk="backends/platform/tizen/tizen.mk" _arm_asm=yes - _taskbar=no _build_scalers=no _seq_midi=no _mt32emu=no @@ -3989,24 +3987,27 @@ fi # Check whether to build taskbar integration support # echo_n "Building taskbar integration support... " -define_in_config_if_yes $_taskbar 'USE_TASKBAR' -if test "$_taskbar" = yes; then +if test "$_taskbar" = "no"; then + echo "no" +else case $_host_os in mingw*) LIBS="$LIBS -lole32 -luuid" echo "win32" + _taskbar=yes ;; *) if test "$_libunity" = yes; then echo "unity" + _taskbar=yes else - echo "$_taskbar" + echo "no" + _taskbar=no fi ;; esac -else - echo "$_taskbar" fi +define_in_config_if_yes $_taskbar 'USE_TASKBAR' # # Check whether to build Bink video support -- cgit v1.2.3 From 10a3b3e9604d5ef1d0bfad8bba639dd082130544 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Tue, 21 Jan 2014 23:15:49 +0100 Subject: BUILD: Remove now superfluous _taskbar=no in Wii specific configuration. --- configure | 1 - 1 file changed, 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index ae4e36cfb0..83f3e88b6c 100755 --- a/configure +++ b/configure @@ -2707,7 +2707,6 @@ if test -n "$_host"; then _backend="wii" _build_scalers=no _vkeybd=yes - _taskbar=no _port_mk="backends/platform/wii/wii.mk" add_line_to_config_mk 'GAMECUBE = 0' add_line_to_config_h '#define AUDIO_REVERSE_STEREO' -- cgit v1.2.3 From a7f94591b03984978b77bad069a2456417b55df9 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Fri, 24 Jan 2014 00:15:13 +0100 Subject: BUILD: Enable RTTI on Android. Thanks to fuzzie for these changes. --- configure | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'configure') diff --git a/configure b/configure index cb0b8902fc..bcb3b17ac7 100755 --- a/configure +++ b/configure @@ -2044,18 +2044,21 @@ case $_host_os in CXXFLAGS="$CXXFLAGS -march=armv5te" CXXFLAGS="$CXXFLAGS -mtune=xscale" CXXFLAGS="$CXXFLAGS -msoft-float" + ABI="armeabi" ;; android-v7a) CXXFLAGS="$CXXFLAGS -march=armv7-a" CXXFLAGS="$CXXFLAGS -mfloat-abi=softfp" CXXFLAGS="$CXXFLAGS -mfpu=vfp" LDFLAGS="$LDFLAGS -Wl,--fix-cortex-a8" + ABI="armeabi-v7a" ;; ouya) CXXFLAGS="$CXXFLAGS -march=armv7-a" CXXFLAGS="$CXXFLAGS -mtune=cortex-a9" CXXFLAGS="$CXXFLAGS -mfloat-abi=softfp" CXXFLAGS="$CXXFLAGS -mfpu=neon" + ABI="armeabi-v7a" ;; esac CXXFLAGS="$CXXFLAGS --sysroot=$ANDROID_NDK/platforms/android-4/arch-arm" @@ -2081,6 +2084,8 @@ case $_host_os in CXXFLAGS="$CXXFLAGS -Wno-psabi" LDFLAGS="$LDFLAGS --sysroot=$ANDROID_NDK/platforms/android-4/arch-arm" LDFLAGS="$LDFLAGS -mthumb-interwork" + LDFLAGS="$LDFLAGS -L$ANDROID_NDK/sources/cxx-stl/gnu-libstdc++/`$CXX -dumpversion`/libs/$ABI/" + LIBS="$LIBS -lsupc++" add_line_to_config_mk "ANDROID_SDK = $ANDROID_SDK" _seq_midi=no ;; -- cgit v1.2.3 From c65464a43ba61bf92446e0d6dc033bfd7e677022 Mon Sep 17 00:00:00 2001 From: Max Lingua Date: Thu, 23 Jan 2014 19:04:19 -0500 Subject: PS2: Added support for latest SDK in configure --- configure | 1 + 1 file changed, 1 insertion(+) (limited to 'configure') diff --git a/configure b/configure index 1de0e65630..4a9474846a 100755 --- a/configure +++ b/configure @@ -2260,6 +2260,7 @@ case $_host_os in CXXFLAGS="$CXXFLAGS -G2" DEFINES="$DEFINES -D_EE" DEFINES="$DEFINES -D__PLAYSTATION2__" + DEFINES="$DEFINES -D__NEW_PS2SDK__" ;; ps3) # Force use of SDL and freetype from the ps3 toolchain -- cgit v1.2.3 From d918a503eedf79aaef9e8fd3b6646c437cb6a81e Mon Sep 17 00:00:00 2001 From: D G Turner Date: Sat, 25 Jan 2014 09:49:57 +0000 Subject: WII: Fix Gamecube build. Compiler prefix change for r26 SDK missed. The previous update to the Wii configure sections including changing the compiler prefix missed changing the Gamecube section. --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index be614883da..a2022c113a 100755 --- a/configure +++ b/configure @@ -1305,7 +1305,7 @@ ds) gamecube) _host_os=gamecube _host_cpu=ppc - _host_alias=powerpc-gekko + _host_alias=powerpc-eabi ;; gp2x) _host_os=gph-linux -- cgit v1.2.3 From a42941180486cc698cdcaf46a9c9f33c7490c24d Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Fri, 14 Feb 2014 02:20:59 +0100 Subject: IPHONE: Don't link against private framework GraphicsServices. Nothing from that framework in specific is used, thus it's not required to link against it. --- configure | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'configure') diff --git a/configure b/configure index a2022c113a..567cb096d7 100755 --- a/configure +++ b/configure @@ -2779,8 +2779,8 @@ case $_backend in ;; iphone) LIBS="$LIBS -lobjc -framework UIKit -framework CoreGraphics -framework OpenGLES" - LIBS="$LIBS -framework QuartzCore -framework GraphicsServices -framework CoreFoundation" - LIBS="$LIBS -framework Foundation -framework AudioToolbox -framework CoreAudio" + LIBS="$LIBS -framework QuartzCore -framework CoreFoundation -framework Foundation" + LIBS="$LIBS -framework AudioToolbox -framework CoreAudio" ;; linuxmoto) DEFINES="$DEFINES -DLINUXMOTO" -- cgit v1.2.3 From 6d7fcdd2b544fa4eb29988bd627af94aa8238d6c Mon Sep 17 00:00:00 2001 From: Thierry Crozat Date: Sun, 26 Jan 2014 20:40:36 +0000 Subject: OSX: Implement TaskbarManager for Mac OS X This implements count badge, progress bar, and icon overlay. It uses the NSDockTile API which is available since OS X 10.5. The code compiles and run on older system but without doing anything. --- configure | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'configure') diff --git a/configure b/configure index 567cb096d7..5499ceccb1 100755 --- a/configure +++ b/configure @@ -4001,6 +4001,10 @@ else echo "win32" _taskbar=yes ;; + darwin*) + echo "osx" + _taskbar=yes + ;; *) if test "$_libunity" = yes; then echo "unity" -- cgit v1.2.3 From 948d4feb234b7f9fa8b4951921c593cabf7dafea Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Sun, 16 Feb 2014 01:38:07 +0100 Subject: CONFIGURE: Allow iPhone backend to be build with cctools' as. --- configure | 1 + 1 file changed, 1 insertion(+) (limited to 'configure') diff --git a/configure b/configure index 5499ceccb1..5f5013535b 100755 --- a/configure +++ b/configure @@ -2497,6 +2497,7 @@ if test -n "$_host"; then ;; iphone) DEFINES="$DEFINES -DIPHONE" + ASFLAGS="$ASFLAGS -arch armv6" _backend="iphone" _build_scalers=no _mt32emu=no -- cgit v1.2.3 From b827d14924dac186267dab3d0db689ba08cc21aa Mon Sep 17 00:00:00 2001 From: D G Turner Date: Wed, 12 Mar 2014 03:38:27 +0000 Subject: ANDROID: Modify configure script for multi architecture builds. The host targets for Android ARM builds are changed to "android-arm" and "android-arm-v7a", from "android" and "android-v7a", and two new targets are added of "android-mips" for MIPS and "android-x86" for x86. The older "android" and "android-v7a" targets are still supported, but are deprecated. --- configure | 71 +++++++++++++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 56 insertions(+), 15 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 5f5013535b..de9c7d0f19 100755 --- a/configure +++ b/configure @@ -850,7 +850,9 @@ Fine tuning of the installation directories: Special configuration feature: --host=HOST cross-compile to target HOST (arm-linux, ...) - special targets: android for Android + special targets: android-arm for Android ARM + android-mips for Android MIPS + android-x86 for Android x86 tizen for Samsung Tizen caanoo for Caanoo dingux for Dingux @@ -1271,11 +1273,21 @@ get_system_exe_extension $guessed_host NATIVEEXEEXT=$_exeext case $_host in -android | android-v7a | ouya) +android | android-arm | android-v7a | android-arm-v7a | ouya) _host_os=android _host_cpu=arm _host_alias=arm-linux-androideabi ;; +android-mips) + _host_os=android + _host_cpu=mipsel + _host_alias=mipsel-linux-android + ;; +android-x86) + _host_os=android + _host_cpu=i686 + _host_alias=i686-linux-android + ;; arm-riscos) _host_os=riscos _host_cpu=arm @@ -2042,18 +2054,34 @@ case $_host_os in ;; android) case $_host in - android) + android | android-arm) CXXFLAGS="$CXXFLAGS -march=armv5te" CXXFLAGS="$CXXFLAGS -mtune=xscale" CXXFLAGS="$CXXFLAGS -msoft-float" ABI="armeabi" + ANDROID_PLATFORM=4 ;; - android-v7a) + android-v7a | android-arm-v7a) CXXFLAGS="$CXXFLAGS -march=armv7-a" CXXFLAGS="$CXXFLAGS -mfloat-abi=softfp" CXXFLAGS="$CXXFLAGS -mfpu=vfp" LDFLAGS="$LDFLAGS -Wl,--fix-cortex-a8" ABI="armeabi-v7a" + ANDROID_PLATFORM=4 + ;; + android-mips) + CXXFLAGS="$CXXFLAGS -march=mips32" + CXXFLAGS="$CXXFLAGS -mtune=mips32" + ABI="mips" + # Platform version 9 is needed as earlier versions of platform do not support this arch. + ANDROID_PLATFORM=9 + ;; + android-x86) + CXXFLAGS="$CXXFLAGS -march=i686" + CXXFLAGS="$CXXFLAGS -mtune=i686" + ABI="x86" + # Platform version 9 is needed as earlier versions of platform do not support this arch. + ANDROID_PLATFORM=9 ;; ouya) CXXFLAGS="$CXXFLAGS -march=armv7-a" @@ -2061,9 +2089,15 @@ case $_host_os in CXXFLAGS="$CXXFLAGS -mfloat-abi=softfp" CXXFLAGS="$CXXFLAGS -mfpu=neon" ABI="armeabi-v7a" + ANDROID_PLATFORM=4 ;; esac - CXXFLAGS="$CXXFLAGS --sysroot=$ANDROID_NDK/platforms/android-4/arch-arm" + + # Setup platform version and arch + ABI_SHORT=`echo $ABI | cut -c1-3` + CXXFLAGS="$CXXFLAGS --sysroot=$ANDROID_NDK/platforms/android-$ANDROID_PLATFORM/arch-$ABI_SHORT" + LDFLAGS="$LDFLAGS --sysroot=$ANDROID_NDK/platforms/android-$ANDROID_PLATFORM/arch-$ABI_SHORT" + CXXFLAGS="$CXXFLAGS -fpic" CXXFLAGS="$CXXFLAGS -ffunction-sections" CXXFLAGS="$CXXFLAGS -funwind-tables" @@ -2076,16 +2110,23 @@ case $_host_os in fi CXXFLAGS="$CXXFLAGS -finline-limit=300" _optimization_level=-Os - CXXFLAGS="$CXXFLAGS -mthumb-interwork" - # FIXME: Why is the following in CXXFLAGS and not in DEFINES? Change or document this. - CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5__" - CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5T__" - CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5E__" - CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5TE__" - # supress 'mangling of 'va_list' has changed in GCC 4.4' + + if test "$_host" = android -o "$_host" = android-arm; then + CXXFLAGS="$CXXFLAGS -mthumb-interwork" + # FIXME: Why is the following in CXXFLAGS and not in DEFINES? Change or document this. + CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5__" + CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5T__" + CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5E__" + CXXFLAGS="$CXXFLAGS -D__ARM_ARCH_5TE__" + fi + + # surpress 'mangling of 'va_list' has changed in GCC 4.4' warning CXXFLAGS="$CXXFLAGS -Wno-psabi" - LDFLAGS="$LDFLAGS --sysroot=$ANDROID_NDK/platforms/android-4/arch-arm" - LDFLAGS="$LDFLAGS -mthumb-interwork" + + if test "$_host" = android -o "$_host" = android-arm; then + LDFLAGS="$LDFLAGS -mthumb-interwork" + fi + LDFLAGS="$LDFLAGS -L$ANDROID_NDK/sources/cxx-stl/gnu-libstdc++/`$CXX -dumpversion`/libs/$ABI/" LIBS="$LIBS -lsupc++" add_line_to_config_mk "ANDROID_SDK = $ANDROID_SDK" @@ -2352,7 +2393,7 @@ if test -n "$_host"; then # Cross-compiling mode - add your target here if needed echo "Cross-compiling to $_host" case "$_host" in - android | android-v7a | ouya) + android | android-arm | android-v7a | android-arm-v7a | android-mips | android-x86 | ouya) # we link a .so as default LDFLAGS="$LDFLAGS -shared" LDFLAGS="$LDFLAGS -Wl,-Bsymbolic,--no-undefined" -- cgit v1.2.3 From d7bddea6db5c7d252c95c0626ea325cadb8fdb68 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Sat, 15 Mar 2014 19:58:13 +0000 Subject: ANDROID: Fix platform architecture and thus MIPS builds. Can't use the first three characters of the ABI as "mips" is four characters. Better than this is a separate variable anyway. --- configure | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'configure') diff --git a/configure b/configure index de9c7d0f19..74d1264f20 100755 --- a/configure +++ b/configure @@ -2060,6 +2060,7 @@ case $_host_os in CXXFLAGS="$CXXFLAGS -msoft-float" ABI="armeabi" ANDROID_PLATFORM=4 + ANDROID_PLATFORM_ARCH="arm" ;; android-v7a | android-arm-v7a) CXXFLAGS="$CXXFLAGS -march=armv7-a" @@ -2068,6 +2069,7 @@ case $_host_os in LDFLAGS="$LDFLAGS -Wl,--fix-cortex-a8" ABI="armeabi-v7a" ANDROID_PLATFORM=4 + ANDROID_PLATFORM_ARCH="arm" ;; android-mips) CXXFLAGS="$CXXFLAGS -march=mips32" @@ -2075,6 +2077,7 @@ case $_host_os in ABI="mips" # Platform version 9 is needed as earlier versions of platform do not support this arch. ANDROID_PLATFORM=9 + ANDROID_PLATFORM_ARCH="mips" ;; android-x86) CXXFLAGS="$CXXFLAGS -march=i686" @@ -2082,6 +2085,7 @@ case $_host_os in ABI="x86" # Platform version 9 is needed as earlier versions of platform do not support this arch. ANDROID_PLATFORM=9 + ANDROID_PLATFORM_ARCH="x86" ;; ouya) CXXFLAGS="$CXXFLAGS -march=armv7-a" @@ -2090,13 +2094,13 @@ case $_host_os in CXXFLAGS="$CXXFLAGS -mfpu=neon" ABI="armeabi-v7a" ANDROID_PLATFORM=4 + ANDROID_PLATFORM_ARCH="arm" ;; esac # Setup platform version and arch - ABI_SHORT=`echo $ABI | cut -c1-3` - CXXFLAGS="$CXXFLAGS --sysroot=$ANDROID_NDK/platforms/android-$ANDROID_PLATFORM/arch-$ABI_SHORT" - LDFLAGS="$LDFLAGS --sysroot=$ANDROID_NDK/platforms/android-$ANDROID_PLATFORM/arch-$ABI_SHORT" + CXXFLAGS="$CXXFLAGS --sysroot=$ANDROID_NDK/platforms/android-$ANDROID_PLATFORM/arch-$ANDROID_PLATFORM_ARCH" + LDFLAGS="$LDFLAGS --sysroot=$ANDROID_NDK/platforms/android-$ANDROID_PLATFORM/arch-$ANDROID_PLATFORM_ARCH" CXXFLAGS="$CXXFLAGS -fpic" CXXFLAGS="$CXXFLAGS -ffunction-sections" -- cgit v1.2.3 From 554a1abae12c465f18a1b0265c185d9d5a0f12b2 Mon Sep 17 00:00:00 2001 From: raziel- Date: Sat, 22 Feb 2014 00:32:54 +0200 Subject: CONFIGURE: Modify AmigaOS debug information format to plain stabs. As the GCC manual notes, "On most systems that use stabs format, -g enables use of extra debugging information that only GDB can use; this extra information makes debugging work better in GDB but will probably make other debuggers crash or refuse to read the program." -gstabs produces stabs without GDB extensions, and thus the AmigaOS debugger will work. --- configure | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 74d1264f20..f964db3386 100755 --- a/configure +++ b/configure @@ -1487,8 +1487,16 @@ caanoo | gp2x | gp2xwiz | openpandora | ps2) esac if test "$_debug_build" != no; then - # debug mode not explicitly disabled -> compile with -g - CXXFLAGS="$CXXFLAGS -g" + # debug mode not explicitly disabled -> compile with debug information + case $_host_os in + amigaos*) + # AmigaOS debugger uses plain stabs, with no gdb extensions. + CXXFLAGS="$CXXFLAGS -gstabs" + ;; + *) + # Use the system default format for debug info. + CXXFLAGS="$CXXFLAGS -g" + esac fi if test "$_release_build" = yes; then -- cgit v1.2.3 From b7f8c11274ffafda63e5680ff489796e1cc86912 Mon Sep 17 00:00:00 2001 From: raziel- Date: Sun, 23 Feb 2014 22:24:47 +0200 Subject: CONFIGURE: Fix AmigaOS4 builds with dynamic plugins. These previously caused crashes due to missing symbols in the dynamic symbol table. --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index f964db3386..caf88b3720 100755 --- a/configure +++ b/configure @@ -2053,7 +2053,7 @@ echo_n "Checking hosttype... " echo $_host_os case $_host_os in amigaos*) - LDFLAGS="$LDFLAGS -use-dynld" + LDFLAGS="$LDFLAGS -use-dynld -Wl,--export-dynamic" LDFLAGS="$LDFLAGS -L/sdk/local/newlib/lib" # We have to use 'long' for our 4 byte typedef because AmigaOS already typedefs (u)int32 # as (unsigned) long, and consequently we'd get a compiler error otherwise. -- cgit v1.2.3 From 6a984425e877d5bb636fba185f550dc84dc7a70d Mon Sep 17 00:00:00 2001 From: D G Turner Date: Wed, 2 Apr 2014 13:13:22 +0100 Subject: CONFIGURE: Remove noisy format warnings from AmigaOS4 builds. This is due to the 4 byte long as int32 which leads to format mismatch warnings. These are supressed to allow any real issues to be seen. --- configure | 2 ++ 1 file changed, 2 insertions(+) (limited to 'configure') diff --git a/configure b/configure index caf88b3720..dc8eace88b 100755 --- a/configure +++ b/configure @@ -2058,6 +2058,8 @@ case $_host_os in # We have to use 'long' for our 4 byte typedef because AmigaOS already typedefs (u)int32 # as (unsigned) long, and consequently we'd get a compiler error otherwise. type_4_byte='long' + # Supress format warnings as the long 4 byte causes noisy warnings. + CXXFLAGS="$CXXFLAGS -Wno-format" add_line_to_config_mk 'AMIGAOS = 1' ;; android) -- cgit v1.2.3 From de3f81845a33f2656003bcb8b22cc806a0d6cd5e Mon Sep 17 00:00:00 2001 From: D G Turner Date: Fri, 18 Apr 2014 12:45:49 +0100 Subject: CONFIGURE: Add help note for option to disable freetype2 usage. --- configure | 1 + 1 file changed, 1 insertion(+) (limited to 'configure') diff --git a/configure b/configure index dc8eace88b..4b1bba4d3f 100755 --- a/configure +++ b/configure @@ -967,6 +967,7 @@ Optional Libraries: --with-freetype2-prefix=DIR Prefix where the freetype-config script is installed (optional) + --disable-freetype2 disable freetype2 TTF library usage [autodetect] --with-nasm-prefix=DIR Prefix where nasm executable is installed (optional) --disable-nasm disable assembly language optimizations [autodetect] -- cgit v1.2.3 From bfc9afbb3290a05b442ffbb5c467ccdf559b722e Mon Sep 17 00:00:00 2001 From: D G Turner Date: Tue, 29 Apr 2014 03:26:53 +0100 Subject: PS2: Add support for building against old SDK if PS2SDK_OLD envvar set. This will allow compilation using the older SDK until the buildbot PS2 toolchain SDK can be upgraded and we can confirm the newer SDK builds are working correctly. --- configure | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index b901943c7e..f0c01cea42 100755 --- a/configure +++ b/configure @@ -2316,7 +2316,9 @@ case $_host_os in CXXFLAGS="$CXXFLAGS -G2" DEFINES="$DEFINES -D_EE" DEFINES="$DEFINES -D__PLAYSTATION2__" - DEFINES="$DEFINES -D__NEW_PS2SDK__" + if test -z "$PS2SDK_OLD"; then + DEFINES="$DEFINES -D__NEW_PS2SDK__" + fi ;; ps3) # Force use of SDL and freetype from the ps3 toolchain -- cgit v1.2.3 From 2779e6825c266f271cba0da9257dadb5061e963e Mon Sep 17 00:00:00 2001 From: D G Turner Date: Wed, 30 Apr 2014 01:16:42 +0100 Subject: PS2: Fix hardcoded library settings to allow building against old SDK. The autodetection should be fixed or modified to remove these hardcoded library enables. For now, we add another minor HACK to disable the troublesome Tremor Ogg Vorbis enable on older SDK, which should fix the buildbot builds. --- configure | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index f0c01cea42..4e4e9d1456 100755 --- a/configure +++ b/configure @@ -2710,7 +2710,10 @@ if test -n "$_host"; then # This trick doesn't work for tremor right now, as the PS2 port the resulting library # libtremor, while our code later on expects it to be called libvorbisidec. # TODO: Enable tremor, e.g. by adding -ltremor or by renaming the lib. - _tremor=yes + # Disable this for older SDK as this breaks the build otherwise... + if test -z "$PS2SDK_OLD"; then + _tremor=yes + fi _mad=yes _zlib=yes # HACK to fix compilation of C source files for now. -- cgit v1.2.3 From 54c957913a0345709b04c2d78c73238ddfb7d1f1 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Sat, 17 May 2014 23:28:00 +0100 Subject: CONFIGURE: Add support for host-alias prefixed strings binary. This is the last outstanding change of patch #1359 - "Update wii/gamecube configure" submitted on 2010-11-15. --- configure | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index 4e4e9d1456..122b1ed3c1 100755 --- a/configure +++ b/configure @@ -1843,6 +1843,12 @@ if test "$_global_constructors" = yes; then fi echo $_global_constructors +if test ! "x$(which $_host_alias-strings)" = "x"; then +_strings=$_host_alias-strings +else +_strings=strings +fi + # # Check for endianness # @@ -1857,7 +1863,7 @@ void _ebcdic() { char* s = (char*) ebcdic_mm; s = (char*) ebcdic_ii; } int main() { _ascii (); _ebcdic (); return 0; } EOF $CXX $CXXFLAGS -c -o $TMPO.o tmp_endianness_check.cpp -if strings $TMPO.o | grep BIGenDianSyS >/dev/null; then +if $_strings $TMPO.o | grep BIGenDianSyS >/dev/null; then _endian=big elif strings $TMPO.o | grep LiTTleEnDian >/dev/null; then _endian=little -- cgit v1.2.3 From e89b0fd4393be93e79095f87d6ce3a1ca2c8d849 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Sun, 18 May 2014 00:30:12 +0100 Subject: CONFIGURE: Add support for host-alias prefixed strings binary on LE. This was missed from the Wii patch as the Wii is Big Endian. --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index 122b1ed3c1..411403408b 100755 --- a/configure +++ b/configure @@ -1865,7 +1865,7 @@ EOF $CXX $CXXFLAGS -c -o $TMPO.o tmp_endianness_check.cpp if $_strings $TMPO.o | grep BIGenDianSyS >/dev/null; then _endian=big -elif strings $TMPO.o | grep LiTTleEnDian >/dev/null; then +elif $_strings $TMPO.o | grep LiTTleEnDian >/dev/null; then _endian=little fi echo $_endian; -- cgit v1.2.3 From d0c363524451fbdeee7459ca544eb26f20b4d789 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Tue, 20 May 2014 19:29:55 +0100 Subject: CONFIGURE: Fix information output for host-alias-strings test. Thanks to LordHoto for the amendment to surpress error output. --- configure | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index 411403408b..ee97e17786 100755 --- a/configure +++ b/configure @@ -1843,10 +1843,13 @@ if test "$_global_constructors" = yes; then fi echo $_global_constructors -if test ! "x$(which $_host_alias-strings)" = "x"; then +echo_n "Checking for $_host_alias-strings... " +if test ! "x$(which $_host_alias-strings 2>/dev/null)" = "x"; then _strings=$_host_alias-strings +echo yes else _strings=strings +echo no fi # -- cgit v1.2.3 From 2ff0a553c303569412030a55d61802f7006727f1 Mon Sep 17 00:00:00 2001 From: D G Turner Date: Wed, 21 May 2014 22:26:22 +0100 Subject: CONFIGURE: Send output for host-alias-strings test to config.log This is not critical to build configuration and any problems would be visible by an incorrect endian test result. --- configure | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'configure') diff --git a/configure b/configure index ee97e17786..c2020ab89e 100755 --- a/configure +++ b/configure @@ -1843,13 +1843,13 @@ if test "$_global_constructors" = yes; then fi echo $_global_constructors -echo_n "Checking for $_host_alias-strings... " +echo_n "Checking for $_host_alias-strings... " >> "$TMPLOG" if test ! "x$(which $_host_alias-strings 2>/dev/null)" = "x"; then _strings=$_host_alias-strings -echo yes +echo yes >> "$TMPLOG" else _strings=strings -echo no +echo no >> "$TMPLOG" fi # -- cgit v1.2.3 From 3de1a9dcaa0458c7907839b3903f356eb811497d Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Wed, 28 May 2014 13:55:38 +0300 Subject: CONFIGURE: Detect and use Fink if installed --- configure | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'configure') diff --git a/configure b/configure index c2020ab89e..def2d915a4 100755 --- a/configure +++ b/configure @@ -2203,6 +2203,30 @@ case $_host_os in echo "Set staticlib-prefix to ${_staticlibpath}" fi fi + + # Fink + # There is no way to get the prefix, so implementing a hack here + fink_version=`fink -V 2>/dev/null` + if test "$?" -eq 0; then + fink_version="`echo "${fink_version}" | sed -ne 's/Package manager version: \([0-9.]*\)/\1/gp'`" + echo_n "You seem to be running Fink version ${fink_version}..." + + fink_prefix=`which fink` + # strip off /bin/fink from /sw/bin/port + fink_prefix=`dirname ${fink_prefix}` + fink_prefix=`dirname ${fink_prefix}` + + echo "adding ${fink_prefix} to paths" + + LDFLAGS="-L${fink_prefix}/lib $LDFLAGS" + CXXFLAGS="-I${fink_prefix}/include $CXXFLAGS" + + if test -z "$_staticlibpath"; then + _staticlibpath=${fink_prefix} + echo "Set staticlib-prefix to ${_staticlibpath}" + fi + fi + # If _staticlibpath is not set yet try first /sw (fink) then /usr/local # (the macports case is handled above). if test -z "$_staticlibpath"; then -- cgit v1.2.3 From 38ee05d75bb19d7a607bc85472d67281e43d72d0 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Wed, 28 May 2014 16:58:25 +0300 Subject: CONFIGURE: Detect and use Mac Homebrew if it is installed --- configure | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'configure') diff --git a/configure b/configure index def2d915a4..46edeafa4e 100755 --- a/configure +++ b/configure @@ -2227,6 +2227,25 @@ case $_host_os in fi fi + # Homebrew + brew_version=`brew -v 2>/dev/null` + if test "$?" -eq 0; then + brew_version="`echo "${brew_version}" | sed -ne 's/Homebrew \([0-9.]*\)/\1/gp'`" + echo_n "You seem to be running Homebrew version ${brew_version}..." + + brew_prefix=`brew --prefix` + + echo "adding ${brew_prefix} to paths" + + LDFLAGS="-L${brew_prefix}/lib $LDFLAGS" + CXXFLAGS="-I${brew_prefix}/include $CXXFLAGS" + + if test -z "$_staticlibpath"; then + _staticlibpath=${brew_prefix} + echo "Set staticlib-prefix to ${_staticlibpath}" + fi + fi + # If _staticlibpath is not set yet try first /sw (fink) then /usr/local # (the macports case is handled above). if test -z "$_staticlibpath"; then -- cgit v1.2.3