From 0dc71e0c3e90cd732f149fefc601a65f6ef530a1 Mon Sep 17 00:00:00 2001 From: Michael Roitzsch Date: Fri, 16 May 2003 11:34:37 +0000 Subject: fix compilation problem with "make debug": the CFLAGS would be overridden in the wrong order, when doing a "make debug" from outside src/libw32dll/wine (DEBUG_CFLAGS is set in src/libw32dll/wine's Makefile, but the CFLAGS given on the command line take precedence, therefore WIN32_PATH would be undefined) I hope I have not broken wine stuff. (Yes, the warning is frightening me...) I have checked using some Windows DLLs and the Quicktime SVQ3 DLL and they worked fine. Could everyone double check, if the win32-DLLs still work? CVS patchset: 4864 CVS date: 2003/05/16 11:34:37 --- src/libw32dll/wine/Makefile.am | 15 ++++++--------- src/libw32dll/wine/driver.c | 3 ++- src/libw32dll/wine/win32.c | 2 +- 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/src/libw32dll/wine/Makefile.am b/src/libw32dll/wine/Makefile.am index 2aab68888..db55e0e71 100644 --- a/src/libw32dll/wine/Makefile.am +++ b/src/libw32dll/wine/Makefile.am @@ -6,18 +6,15 @@ EXTRA_DIST = stubs.s wrapper.S noinst_LTLIBRARIES = $(wine_lib) -# WARNING: DO NOT USE AM_CFLAGS HERE UNLESS YOU UNDERSTAND THE PROBLEM WITH -# DEFAULT XINE FLAGS AND KNOW HOW TO FIX IT. -CFLAGS = $(X_CFLAGS) -fno-omit-frame-pointer \ +AM_CFLAGS = $(X_CFLAGS) -fno-omit-frame-pointer \ -Wmissing-prototypes -Wimplicit-function-declaration \ - -DWIN32_PATH="@w32_path@" -I$(srcdir)/.. -D__WINE__ \ + -DWIN32_PATH=\"@w32_path@\" -I$(srcdir)/.. -D__WINE__ \ -Ddbg_printf=__vprintf -DTRACE=__vprintf -DEBUG_CFLAGS = @DEBUG_CFLAGS@ $(X_CFLAGS) -fno-omit-frame-pointer \ - -Wmissing-prototypes -Wimplicit-function-declaration \ - -DWIN32_PATH="@w32_path@" -I$(srcdir)/.. -D__WINE__ \ - -Ddbg_printf=__vprintf -DTRACE=__vprintf - +# CFLAGS is here to filter out -fomit-frame-pointer because it causes bad +# behavior of wine +CFLAGS = `echo @CFLAGS@ | sed -e 's/-fomit-frame-pointer//g'` + if HAVE_W32DLL wine_lib = libwine.la endif diff --git a/src/libw32dll/wine/driver.c b/src/libw32dll/wine/driver.c index 6ef5d7500..7720a4975 100644 --- a/src/libw32dll/wine/driver.c +++ b/src/libw32dll/wine/driver.c @@ -18,6 +18,7 @@ extern char* win32_def_path; + #if 1 /* @@ -57,7 +58,7 @@ void SetCodecPath(const char* path) if(needs_free)free(win32_def_path); if(path==0) { - win32_def_path="WIN32_PATH"; + win32_def_path=WIN32_PATH; needs_free=0; return; } diff --git a/src/libw32dll/wine/win32.c b/src/libw32dll/wine/win32.c index 66e1d11b8..88766dcc8 100644 --- a/src/libw32dll/wine/win32.c +++ b/src/libw32dll/wine/win32.c @@ -78,7 +78,7 @@ static int vsscanf( const char *str, const char *format, va_list ap) } #endif -char* win32_def_path = "WIN32_PATH"; +char* win32_def_path = WIN32_PATH; static void do_cpuid(unsigned int ax, unsigned int *regs) { -- cgit v1.2.3