Build failure on current git

Eric Pouech eric.pouech at
Mon Aug 24 15:29:10 CDT 2009

Stefan Leichter a écrit :
> Hello,
> building current git fails for me with:
> make: Entering directory `/usr/src/wine/wine-build/dlls/winemp3.acm'
> ../../tools/winegcc/winegcc  -B../../tools/winebuild --sysroot=../.. -shared ../../../wine-git/dlls/winemp3.acm/winemp3.acm.spec    
> mpegl3.o        -o 
>  -lwinmm -luser32 -lkernel32  ../../libs/port/libwine_port.a -lmpg123
> mpegl3.o: In function `mp3_horse':
> /usr/src/wine/wine-build/dlls/winemp3.acm/../../../wine-git/dlls/winemp3.acm/mpegl3.c:153: 
> undefined reference to `mpg123_feed'
> collect2: ld returned 1 exit status
> winegcc: ccache failed
> make: *** [] Fehler 2
> make: Leaving directory `/usr/src/wine/wine-build/dlls/winemp3.acm'
> sle at sle3:/usr/src/wine/wine-build$ dpkg --list | grep mpg123
> ii  libmpg123-0		1.4.3-4		MPEG layer 1/2/3 audio decoder -- runtime li
> ii  libmpg123-dev	1.4.3-4		MPEG layer 1/2/3 audio decoder -- developmen
> ii  mpg321	mpg123 clone that doesn't use floating point
I get as well several problems on Mandriva

from what I see (in my mpg123.h) file

the libmpg123 lib can either be configured with FILE_OFFSET_BITS to 32 or 64
if the later, then most of the symbols exported from the library get a 
_64 suffix

prompt> string /usr/ | grep seek
should tell. I get


moreover, in my case, the header/lib check in configure fails because of 
the following code in mpg123.h

    /#ifndef MPG123_NO_CONFIGURE /* Enable use of this file without
    configure. */
    #include <stdlib.h>
    #include <sys/types.h>

    #if 1 /* If we need trickery for large file support. */

    /* Check for compiling programs agains this libmpg123. */
    #if (defined _FILE_OFFSET_BITS) && (_FILE_OFFSET_BITS+0 == 64)
    /* ...all is fine, having enabled large file support and also the
    correct sort of which. */
    #error "Mismatch in large file setup! Enable/disable large file
    support appropriately to use libmpg123."

as  a temporary hack, something like this seems to help
diff --git a/ b/
index 4b37e5f..3945157 100644
--- a/
+++ b/
@@ -278,6 +278,8 @@ case $host_cpu in

 dnl **** Check for some libraries ****

 dnl Check for -li386 for NetBSD and OpenBSD
diff --git a/dlls/winemp3.acm/mpegl3.c b/dlls/winemp3.acm/mpegl3.c
index 9b4e2ac..4602a42 100644
--- a/dlls/winemp3.acm/mpegl3.c
+++ b/dlls/winemp3.acm/mpegl3.c
@@ -25,6 +25,7 @@
 #include <assert.h>
 #include <stdarg.h>
 #include <string.h>
+#include <unistd.h>
 #include "windef.h"
 #include "winbase.h"
 #include "wingdi.h"
@@ -35,6 +36,8 @@
 #include "msacm.h"
 #include "msacmdrv.h"

+#define _FILE_OFFSET_BITS      64
 #ifdef HAVE_MPG123_H
 #include <mpg123.h>

one still needs to properly handle the definition of _FILE_OFFSET_BITS 
in mpegl3.c from the configuration bits before this patch gets ready for 
time to stop for tonight, more on this tomorrow


Eric Pouech
"The problem with designing something completely foolproof is to underestimate the ingenuity of a complete idiot." (Douglas Adams)

More information about the wine-devel mailing list