summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Alexey Yakovenko <waker@users.sourceforge.net>2013-09-10 20:35:45 +0200
committerGravatar Alexey Yakovenko <waker@users.sourceforge.net>2013-09-10 20:39:20 +0200
commit8aaa885aae14ef3bd350b847e4e410d5dc3d0197 (patch)
tree60c215a306b2e36c540f48bfc5fa8f551914c5d6
parente1ded6f39ea4c00e4839cfed00330348cd75bb8f (diff)
fixed ffap build on osx
-rw-r--r--configure.ac21
-rw-r--r--plugins/ffap/Makefile.am4
-rwxr-xr-xyasmwrapper.sh4
3 files changed, 19 insertions, 10 deletions
diff --git a/configure.ac b/configure.ac
index 0d9d294d..12da0cbe 100644
--- a/configure.ac
+++ b/configure.ac
@@ -32,6 +32,18 @@ case "$host" in
esac
case "$host" in
+ i686-apple-*)
+ AC_DEFINE(ARCH_X86_32, 1, [architecture is x86 on OSX])
+ LIB="../deadbeef-deps/lib-x86-32-apple"
+ YASM_FLAGS="-f macho32 -D ARCH_X86_32 -m x86 -DPREFIX"
+ APE_USE_YASM=yes
+ ;;
+ x86_64-apple-*)
+ AC_DEFINE(ARCH_X86_64, 1, [architecture is x86_64 on OSX])
+ LIB="../deadbeef-deps/lib-x86-64-apple"
+ YASM_FLAGS="-f macho64 -D ARCH_X86_64 -m amd64 -DPIC -DPREFIX"
+ APE_USE_YASM=yes
+ ;;
i386-*-* | i486-*-* | i586-*-* | i686-*-* | i86pc-*-*)
AC_DEFINE(ARCH_X86_32, 1, [architecture is x86])
LIB="../deadbeef-deps/lib-x86-32"
@@ -45,14 +57,6 @@ case "$host" in
APE_USE_YASM=yes
KILLCPPFLAGS="-nostdlib -lsupc++"
;;
- i686-apple-*)
- AC_DEFINE(ARCH_X86_32_OSX, 1, [architecture is x86 on OSX])
- LIB="../deadbeef-deps/lib-x86-32-apple"
- ;;
- x86_64-apple-*)
- AC_DEFINE(ARCH_X86_64_OSX, 1, [architecture is x86_64 on OSX])
- LIB="../deadbeef-deps/lib-x86-64-apple"
- ;;
powerpc-*-* )
AC_DEFINE(ARCH_PPC_32, 1, [architecture is ppc32])
LIB="../deadbeef-deps/lib-ppc-32"
@@ -653,6 +657,7 @@ AS_IF([test "${enable_pltbrowser}" != "no"], [
PLUGINS_DIRS="plugins/lastfm plugins/mpgmad plugins/vorbis plugins/flac plugins/wavpack plugins/sndfile plugins/vfs_curl plugins/cdda plugins/gtkui plugins/alsa plugins/ffmpeg plugins/hotkeys plugins/oss plugins/artwork plugins/adplug plugins/ffap plugins/sid plugins/nullout plugins/supereq plugins/vtx plugins/gme plugins/pulse plugins/notify plugins/musepack plugins/wildmidi plugins/tta plugins/dca plugins/aac plugins/mms plugins/shellexec plugins/dsp_libsrc plugins/m3u plugins/vfs_zip plugins/converter plugins/dumb plugins/shn plugins/ao plugins/mono2stereo plugins/shellexecui plugins/alac plugins/medialib plugins/wma plugins/pltbrowser plugins/coreaudio"
+AM_CONDITIONAL(APE_USE_YASM, test "x$APE_USE_YASM" = "xyes")
AM_CONDITIONAL(HAVE_VORBIS, test "x$HAVE_VORBISPLUGIN" = "xyes")
AM_CONDITIONAL(HAVE_FLAC, test "x$HAVE_FLACPLUGIN" = "xyes")
AM_CONDITIONAL(HAVE_WAVPACK, test "x$HAVE_WAVPACKPLUGIN" = "xyes")
diff --git a/plugins/ffap/Makefile.am b/plugins/ffap/Makefile.am
index 4f6ce038..24cd7909 100644
--- a/plugins/ffap/Makefile.am
+++ b/plugins/ffap/Makefile.am
@@ -8,16 +8,20 @@ EXTRA_DIST = dsputil_yasm.asm x86inc.asm
SUFFIXES = .asm
if HAVE_YASM
+if APE_USE_YASM
INTEL_SRC=dsputil_yasm.asm
ffap_la_DEPENDENCIES=dsputil_yasm.lo
endif
+endif
ffap_la_SOURCES = ffap.c $(INTEL_SRC)
if HAVE_YASM
+if APE_USE_YASM
.asm.lo:
$(LIBTOOL) --tag=CC --mode=compile $(YASM) $(YASM_FLAGS) -o $@ $<
endif
+endif
ffap_la_LDFLAGS = -module -lm
diff --git a/yasmwrapper.sh b/yasmwrapper.sh
index 1d0170f1..021962b6 100755
--- a/yasmwrapper.sh
+++ b/yasmwrapper.sh
@@ -1,8 +1,8 @@
-#!/bin/bash
+#!/bin/sh
ARGS=""
for i in $@ ; do
#if [ "$i" != "-fPIC" ] && [ "$i" != "-DPIC" ]; then
- if [ "$i" != "-fPIC" ]; then
+ if [ "$i" != "-fPIC" -a "$i" != "-fno-common" ]; then
ARGS="$ARGS $i"
fi
done