graphics: multiple definition of `various_x11_symbols'

Solution is to make the grX11thread.c and grX11su1[5].c versions
the official location.  Another solution maybe to split them into
their own file grX11common.c that would be shared.

Multiple configurations tested, tested configurations assume X11
is available.  The configuration wording indicates X11 must be
available for all graphics enabled build configurations.

Affected symbols appear to have multiple definitions:
grCursors
grXdpy
grXscrn
pipeRead
pipeWrite
Xhelper
grVisual

GCC14 and linker will not link the final executable due to this.

GCC14 --without-tk --without-tcl
Related issue: https://github.com/RTimothyEdwards/magic/issues/323
This commit is contained in:
Darryl L. Miles 2024-10-02 06:59:00 +01:00 committed by Tim Edwards
parent e5c3e703c3
commit 54f49829f2
3 changed files with 7 additions and 7 deletions

View File

@ -37,12 +37,12 @@
GLubyte **grOGLStipples;
HashTable grOGLWindowTable;
Display *grXdpy;
extern Display *grXdpy; /* grX11thread.c */
GLXContext grXcontext;
int grXscrn;
int pipeRead, pipeWrite;
int Xhelper;
Visual *grVisual;
extern int grXscrn; /* grX11su1.c */
extern int pipeRead, pipeWrite; /* grX11su1.c */
extern int Xhelper; /* grX11su1.c */
extern Visual *grVisual; /* grX11su1.c */
#ifdef HAVE_PTHREADS
extern int writePipe;

View File

@ -36,7 +36,7 @@ extern HashTable grOGLWindowTable;
extern Display *grXdpy;
extern int grXscrn;
Cursor grCursors[MAX_CURSORS];
extern Cursor grCursors[MAX_CURSORS]; /* grX11su5.c */
/*

View File

@ -52,7 +52,7 @@
extern char *DBWStyleType;
Display *grXdpy;
extern Display *grXdpy; /* grX11thread.c */
int grXscrn;
Colormap grXcmap;
Visual *grVisual;