fix libFLAC to build PPC asm properly, conditionalized for gas or as
This commit is contained in:
parent
d4b2955854
commit
b990022c95
20
configure.in
20
configure.in
@ -169,12 +169,26 @@ if test -n "$DOCBOOK_TO_MAN" ; then
|
||||
AC_DEFINE(FLAC__HAS_DOCBOOK_TO_MAN)
|
||||
fi
|
||||
|
||||
# only matters for x86
|
||||
AC_CHECK_PROGS(NASM, nasm)
|
||||
AM_CONDITIONAL(FLaC__HAS_NASM, test -n "$NASM")
|
||||
if test -n "$NASM" ; then
|
||||
AC_DEFINE(FLAC__HAS_NASM)
|
||||
fi
|
||||
|
||||
# only matters for PowerPC
|
||||
AC_CHECK_PROGS(AS, as)
|
||||
AC_CHECK_PROGS(GAS, gas)
|
||||
AM_CONDITIONAL(FLaC__HAS_AS, test -n "$AS")
|
||||
AM_CONDITIONAL(FLaC__HAS_GAS, test -n "$GAS")
|
||||
if test -n "$AS" ; then
|
||||
AC_DEFINE(FLAC__HAS_AS)
|
||||
fi
|
||||
if test -n "$GAS" ; then
|
||||
# funniest. macro. ever.
|
||||
AC_DEFINE(FLAC__HAS_GAS)
|
||||
fi
|
||||
|
||||
OUR_CFLAGS_HEAD='-I$(top_builddir) -I$(srcdir)/include -I$(top_srcdir)/include'
|
||||
if test x$debug = xtrue; then
|
||||
OUR_CFLAGS_HEAD="$OUR_CFLAGS_HEAD -g -O0 -DDEBUG"
|
||||
@ -196,7 +210,9 @@ AH_TEMPLATE(FLAC__EXHAUSTIVE_TESTS, [define to run even more tests])
|
||||
AH_TEMPLATE(FLAC__VALGRIND_TESTING, [define to enable use of Valgrind in testers])
|
||||
AH_TEMPLATE(FLAC__HAS_DOXYGEN, [define if you have Doxygen])
|
||||
AH_TEMPLATE(FLAC__HAS_DOCBOOK_TO_MAN, [define if you have docbook-to-man or docbook2man])
|
||||
AH_TEMPLATE(FLAC__HAS_NASM, [define if you have the NASM assembler])
|
||||
AH_TEMPLATE(FLAC__HAS_NASM, [define if you are compiling for x86 and have the NASM assembler])
|
||||
AH_TEMPLATE(FLAC__HAS_AS, [define if you are compiling for PowerPC and have the 'as' assembler])
|
||||
AH_TEMPLATE(FLAC__HAS_GAS, [define if you are compiling for PowerPC and have the 'gas' assembler])
|
||||
AH_TEMPLATE(FLAC__HAS_OGG, [define if you have the ogg library])
|
||||
AH_TEMPLATE(FLAC__NO_ASM, [define to disable use of assembly code])
|
||||
AH_TEMPLATE(FLAC__SSE_OS, [define if your operating system supports SSE instructions])
|
||||
@ -209,6 +225,8 @@ AC_OUTPUT( \
|
||||
src/libFLAC/Makefile \
|
||||
src/libFLAC/ia32/Makefile \
|
||||
src/libFLAC/ppc/Makefile \
|
||||
src/libFLAC/ppc/as/Makefile \
|
||||
src/libFLAC/ppc/gas/Makefile \
|
||||
src/libFLAC/include/Makefile \
|
||||
src/libFLAC/include/private/Makefile \
|
||||
src/libFLAC/include/protected/Makefile \
|
||||
|
@ -44,8 +44,13 @@ endif
|
||||
endif
|
||||
if FLaC__CPU_PPC
|
||||
ARCH_SUBDIRS = ppc
|
||||
#@@@@@@ need to conditionalize this to gas or as depending on configure
|
||||
if FLaC__HAS_AS
|
||||
libFLAC_la_LIBADD = ppc/as/libFLAC-asm.la
|
||||
else
|
||||
if FLaC__HAS_GAS
|
||||
libFLAC_la_LIBADD = ppc/gas/libFLAC-asm.la
|
||||
endif
|
||||
endif
|
||||
LOCAL_EXTRA_LDFLAGS = "-Wl,-read_only_relocs,warning"
|
||||
endif
|
||||
endif
|
||||
|
@ -28,6 +28,4 @@
|
||||
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
#@@@@@@ We actually want to only compile one based on some configuration,
|
||||
#@@@@@@ so we'll eventually have to conditionalize the sub-Makefile.am's
|
||||
SUBDIRS = as gas
|
||||
|
@ -28,6 +28,8 @@
|
||||
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
if FLaC__HAS_AS
|
||||
|
||||
SUFFIXES = .s .lo
|
||||
|
||||
STRIP_NON_ASM = sh $(top_srcdir)/strip_non_asm_libtool_args.sh
|
||||
@ -40,3 +42,10 @@ STRIP_NON_ASM = sh $(top_srcdir)/strip_non_asm_libtool_args.sh
|
||||
noinst_LTLIBRARIES = libFLAC-asm.la
|
||||
libFLAC_asm_la_SOURCES = \
|
||||
lpc_asm.s
|
||||
|
||||
else
|
||||
|
||||
EXTRA_DIST = \
|
||||
lpc_asm.s
|
||||
|
||||
endif
|
||||
|
@ -28,6 +28,8 @@
|
||||
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
if FLaC__HAS_GAS
|
||||
|
||||
SUFFIXES = .s .lo
|
||||
|
||||
STRIP_NON_ASM = sh $(top_srcdir)/strip_non_asm_libtool_args.sh
|
||||
@ -40,3 +42,10 @@ STRIP_NON_ASM = sh $(top_srcdir)/strip_non_asm_libtool_args.sh
|
||||
noinst_LTLIBRARIES = libFLAC-asm.la
|
||||
libFLAC_asm_la_SOURCES = \
|
||||
lpc_asm.s
|
||||
|
||||
else
|
||||
|
||||
EXTRA_DIST = \
|
||||
lpc_asm.s
|
||||
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user