Discussion:
[Speex-dev] failure with latest cross compiling
Roger Pack
2016-07-08 22:41:29 UTC
Permalink
As a note, with the latest versions, I get this "new" failure, when
cross compiling for windows using mingw:

CCLD speexdec.exe
speexdec.o:speexdec.c:(.text+0x4af): undefined reference to
`***@0'
speexdec.o:speexdec.c:(.text+0x54d): undefined reference to
`***@24'
speexdec.o:speexdec.c:(.text+0x5aa): undefined reference to
`***@4'
speexdec.o:speexdec.c:(.text+0x7f1): undefined reference to
`***@12'
speexdec.o:speexdec.c:(.text+0x8f2): undefined reference to
`***@12'
speexdec.o:speexdec.c:(.text+0x913): undefined reference to
`***@12'
speexdec.o:speexdec.c:(.text+0xa45): undefined reference to
`***@12'
speexdec.o:speexdec.c:(.text+0xaae): undefined reference to
`***@4'
speexdec.o:speexdec.c:(.text+0xabf): undefined reference to
`***@4'
collect2: error: ld returned 1 exit status
Makefile:445: recipe for target 'speexdec.exe' failed


Cheers!
Tristan Matthews
2016-07-08 22:53:53 UTC
Permalink
Hi,
Post by Roger Pack
As a note, with the latest versions, I get this "new" failure, when
CCLD speexdec.exe
speexdec.o:speexdec.c:(.text+0x4af): undefined reference to
speexdec.o:speexdec.c:(.text+0x54d): undefined reference to
speexdec.o:speexdec.c:(.text+0x5aa): undefined reference to
speexdec.o:speexdec.c:(.text+0x7f1): undefined reference to
speexdec.o:speexdec.c:(.text+0x8f2): undefined reference to
speexdec.o:speexdec.c:(.text+0x913): undefined reference to
speexdec.o:speexdec.c:(.text+0xa45): undefined reference to
speexdec.o:speexdec.c:(.text+0xaae): undefined reference to
speexdec.o:speexdec.c:(.text+0xabf): undefined reference to
collect2: error: ld returned 1 exit status
Makefile:445: recipe for target 'speexdec.exe' failed
These waveOut* functions are MS specific, so for some reason you are
not linking against the appropriate library for audio routines (I'm
guessing the winmm library?)

Can you provide your full config.log and any other pertinent logs?

Best,
Tristan
Tristan Matthews
2016-07-09 21:07:08 UTC
Permalink
This patch should address the current linking failure for speexdec with mingw.

---
configure.ac | 3 +++
src/Makefile.am | 2 +-
2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index c4b357e..1659062 100644
--- a/configure.ac
+++ b/configure.ac
@@ -194,9 +194,12 @@ AC_ARG_ENABLE(blackfin-asm, [ --enable-blackfin-asm Make use of Blackfin asse
[if test "$enableval" = yes; then
AC_DEFINE([BFIN_ASM], , [Make use of Blackfin assembly optimizations])
fi])
+WINMM_LIBS=""
case $host_os in
uclinux) LDFLAGS="-Wl,-elf2flt=-s100000 $LDFLAGS";;
+ *mingw*) WINMM_LIBS="-lwinmm";;
esac
+AC_SUBST(WINMM_LIBS)

AC_ARG_ENABLE(fixed-point-debug, [ --enable-fixed-point-debug Debug fixed-point implementation],
[if test "$enableval" = yes; then
diff --git a/src/Makefile.am b/src/Makefile.am
index 2cac269..ce870ac 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -24,5 +24,5 @@ speexenc_LDADD = $(top_builddir)/libspeex/libspeex.la \

speexdec_SOURCES = speexdec.c wav_io.c
speexdec_LDADD = $(top_builddir)/libspeex/libspeex.la \
- $(OGG_LIBS) @FFT_LIBS@
+ $(OGG_LIBS) @WINMM_LIBS@ @FFT_LIBS@
--
2.8.1
Tristan Matthews
2016-07-11 16:05:45 UTC
Permalink
Hi Roger,
Post by Roger Pack
As a note, with the latest versions, I get this "new" failure, when
CCLD speexdec.exe
speexdec.o:speexdec.c:(.text+0x4af): undefined reference to
speexdec.o:speexdec.c:(.text+0x54d): undefined reference to
speexdec.o:speexdec.c:(.text+0x5aa): undefined reference to
speexdec.o:speexdec.c:(.text+0x7f1): undefined reference to
speexdec.o:speexdec.c:(.text+0x8f2): undefined reference to
speexdec.o:speexdec.c:(.text+0x913): undefined reference to
speexdec.o:speexdec.c:(.text+0xa45): undefined reference to
speexdec.o:speexdec.c:(.text+0xaae): undefined reference to
speexdec.o:speexdec.c:(.text+0xabf): undefined reference to
collect2: error: ld returned 1 exit status
Makefile:445: recipe for target 'speexdec.exe' failed
Should be fixed in master now, let me know if you have any futher issues.[1][2]

Best,
Tristan

[1] https://git.xiph.org/?p=speex.git;a=commit;h=b35c295682a3d257ddef4abb8d76e8c7aeff358c
[2] https://git.xiph.org/?p=speex.git;a=commit;h=497db349f47350a62ba42a91c10d7e203e64d167
Roger Pack
2016-07-12 15:12:59 UTC
Permalink
Post by Tristan Matthews
Hi Roger,
Post by Roger Pack
As a note, with the latest versions, I get this "new" failure, when
CCLD speexdec.exe
speexdec.o:speexdec.c:(.text+0x4af): undefined reference to
speexdec.o:speexdec.c:(.text+0x54d): undefined reference to
speexdec.o:speexdec.c:(.text+0x5aa): undefined reference to
speexdec.o:speexdec.c:(.text+0x7f1): undefined reference to
speexdec.o:speexdec.c:(.text+0x8f2): undefined reference to
speexdec.o:speexdec.c:(.text+0x913): undefined reference to
speexdec.o:speexdec.c:(.text+0xa45): undefined reference to
speexdec.o:speexdec.c:(.text+0xaae): undefined reference to
speexdec.o:speexdec.c:(.text+0xabf): undefined reference to
collect2: error: ld returned 1 exit status
Makefile:445: recipe for target 'speexdec.exe' failed
Should be fixed in master now, let me know if you have any futher issues.[1][2]
Perfect, confirmed working thank you

Loading...