Signed-off-by: Fabian Maurer dark.shadow4@web.de
-- v3: wmphoto: Define ansi flag for JXRGlue to avoid typedef redefinitions (gcc 4.3) libs/jxr: Compile with ansi flag to avoid typedef redefinitions (gcc 4.3)
From: Fabian Maurer dark.shadow4@web.de
Signed-off-by: Fabian Maurer dark.shadow4@web.de --- libs/jxr/Makefile.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libs/jxr/Makefile.in b/libs/jxr/Makefile.in index 3162cfca263..be124c2563b 100644 --- a/libs/jxr/Makefile.in +++ b/libs/jxr/Makefile.in @@ -1,6 +1,6 @@ EXTLIB = libjxr.a EXTRAINCL = $(JXR_PE_CFLAGS) -EXTRADEFS = -DDISABLE_PERF_MEASUREMENT +EXTRADEFS = -DDISABLE_PERF_MEASUREMENT -D__ANSI__ -D__LP64__
C_SRCS = \ image/decode/JXRTranscode.c \
From: Fabian Maurer dark.shadow4@web.de
Signed-off-by: Fabian Maurer dark.shadow4@web.de --- dlls/wmphoto/jxrlib.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/dlls/wmphoto/jxrlib.c b/dlls/wmphoto/jxrlib.c index d4ac02e5918..4071a568162 100644 --- a/dlls/wmphoto/jxrlib.c +++ b/dlls/wmphoto/jxrlib.c @@ -28,7 +28,10 @@ #include "winbase.h" #include "objbase.h" #define ERR JXR_ERR +#define __ANSI__ +#define __LP64__ #include "JXRGlue.h" +#undef __ANSI__ #undef ERR
#include "wincodecs_private.h"
Sorry, this is broken. Currently don't know how to handle this best...
On Tue Jun 13 22:31:42 2023 +0000, Fabian Maurer wrote:
Sorry, this is broken. Currently don't know how to handle this best...
Only the jxrgluelib files must be compiled with __ANSI__, the others break if you try.
Suggestions how to do that without editing the lib/ files itself? Because AFAIK I'm not supposed to edit those. Maybe nested Makefiles? But I don't know if or how that works.
On Tue Jun 13 22:31:42 2023 +0000, Fabian Maurer wrote:
Only the jxrgluelib files must be compiled with __ANSI__, the others break if you try. Suggestions how to do that without editing the lib/ files itself? Because AFAIK I'm not supposed to edit those. Maybe nested Makefiles? But I don't know if or how that works.
As far as I can tell, jxrlib is abandonware, and C89/C99 conformance isn't the only problem with it (scan-build identified others). My guess is that at some point Wine is just going to have to fork jxrlib, but I don't think it's worth it to fork just for the sake of GCC 4.3. If you have to compile Wine with GCC 4.3, I suggest running `./configure --disable-wmphoto`.