Skip to content

Fix Win32 build with -fno-common

Jon Turney requested to merge jturney/libx11:win32-no-common-fix into master

/work/xorg/lib/libX11/src/XlibInt.c:1968: multiple definition of `_Xdebug_p'; .libs/globals.o:globals.c:(.bss+0xc): first defined here

Avoid redundant definition of _Xdebug_p in globals.c (which is under the influence of _Xdebug being #defined to _Xdebug_p.

This appears to be an ancient hack to work around data exports resolving to the address of the import stub, not the import. (See [1]).

(This is probably no longer needed or can be done in a better way, as per the discussion under --enable-auto-import in the ld manpage.)


Signed-off-by: Jon Turney

Merge request reports