C99 code compat when configured with no TCL support

This commit is contained in:
Alessandro De Laurenzis 2022-10-28 07:50:29 +02:00
parent 1c343584e9
commit 68cecd5382
19 changed files with 64 additions and 7 deletions

View File

@ -243,6 +243,7 @@ extern void DBWHLRedrawPrepWindow();
extern void CmdInit();
extern void DBWinit();
extern int DBWTechParseStyle();
extern void dbwButtonSetCursor();
/* Random procedures used internally to this module. None of these
* should ever need to be called by the outside world.

View File

@ -37,6 +37,9 @@
#include "select/select.h"
#include "utils/malloc.h"
/* C99 compat */
#include "extract/extract.h"
/* Forward declarations */
int antennacheckArgs();
int antennacheckVisit();

View File

@ -38,6 +38,7 @@ static char rcsid[] __attribute__ ((unused)) = "$Header: /usr/cvsroot/magic-8.0/
/* C99 compat */
#include "textio/textio.h"
#include "utils/pathvisit.h"
#define atoCap(s) ((EFCapValue)atof(s))

View File

@ -94,7 +94,6 @@ extern int ExtGetGateTypesMask();
extern int ExtGetDiffTypesMask();
#ifdef MAGIC_WRAPPER
extern bool ExtGetDevInfo();
extern bool ExtCompareStyle();
#endif
@ -143,5 +142,6 @@ extern void extSubtree();
extern int extUniqueCell();
extern void ExtLabelOneRegion();
extern void ExtInit();
extern bool ExtGetDevInfo();
#endif /* _EXTRACT_H */

View File

@ -30,6 +30,11 @@
#include "grOGLInt.h"
#include "utils/paths.h"
/* C99 compat */
#include "dbwind/dbwind.h"
#include "utils/main.h"
#include "utils/malloc.h"
GLubyte **grOGLStipples;
HashTable grOGLWindowTable;
Display *grXdpy;

View File

@ -38,6 +38,9 @@
#include "database/fonts.h"
#include "grOGLInt.h"
/* C99 compat */
#include "utils/malloc.h"
extern Display *grXdpy;
static XFontStruct *grXFonts[4];

View File

@ -45,6 +45,11 @@
#include "grX11Int.h"
#include "utils/paths.h"
/* C99 compat */
#include "utils/main.h"
#include "utils/malloc.h"
#include "dbwind/dbwind.h"
extern char *DBWStyleType;
Display *grXdpy;

View File

@ -33,6 +33,9 @@
#include "graphics/graphicsInt.h"
#include "grX11Int.h"
/* C99 compat */
#include "utils/main.h"
extern char *DBWStyleType;
extern unsigned long grPlanes[256];
extern unsigned long grPixels[256];

View File

@ -23,6 +23,9 @@
#include <math.h>
#include <X11/Xlib.h>
/* C99 compat */
#include <X11/Xutil.h>
#include "utils/magic.h"
#include "utils/geometry.h"
#include "graphics/graphics.h"
@ -36,6 +39,9 @@
#include "database/fonts.h"
#include "grX11Int.h"
/* C99 compat */
#include "utils/malloc.h"
/* locals */
static XFontStruct *grXFonts[4];

View File

@ -15,6 +15,10 @@
#include <X11/keysym.h>
#include <pthread.h>
/* C99 compat */
#include <stdlib.h>
#include <unistd.h>
#include "utils/magic.h"
#include "utils/geometry.h"
#include "graphics/graphics.h"

View File

@ -93,5 +93,11 @@ extern void grInformDriver();
extern bool GrReadGlyphs();
extern bool GrBoxOutline();
extern bool grtcairoLoadFont();
extern int xloop_create();
extern bool groglLoadFont();
extern void GrX11Close();
extern bool grx11LoadFont();
extern void xloop_end();
extern bool groglPreLoadFont();
#endif /* _GRAPHICSINT_H */

View File

@ -27,6 +27,7 @@
#include <ctype.h>
#include <signal.h>
#include <unistd.h>
#include <errno.h>
#include <sys/types.h>
#include <sys/stat.h>
@ -45,7 +46,9 @@
#include "windows/windows.h"
#include "dbwind/dbwind.h"
#include "sim/sim.h"
#include <errno.h>
/* C99 compat */
#include "textio/textio.h"
static bool InitRsim();

View File

@ -37,5 +37,10 @@ extern int SimSrConnect();
extern void SimTreeCopyConnect();
extern int SimTreeSrNMTiles();
extern int SimTreeSrTiles();
extern bool SimStartRsim();
extern void SimConnectRsim();
extern bool SimSelection();
extern void SimRsimMouse();
extern int SimFillBuffer();
#endif /* _SIM_H */

View File

@ -55,13 +55,12 @@ extern bool TxGetInputEvent();
extern void txFprintfBasic(FILE *, ...);
/* C99 compat */
int Tcl_printf();
void txCommandsInit();
int Tcl_printf();
int Tcl_printf();
int Tcl_printf();
int Tcl_printf();
int TranslateChar();
char *TxGetLineWPrompt();
#ifdef MAGIC_WRAPPER
int Tcl_printf();
#endif
#endif /* _TEXTIOINT_H */

View File

@ -52,6 +52,7 @@ static char rcsid[] __attribute__ ((unused)) ="$Header: /usr/cvsroot/magic-8.0/t
/* C99 compat */
#include "windows/windows.h"
#include "utils/main.h"
/* Turning this flag on prints out input events and commands as they
* are processed.

View File

@ -49,6 +49,9 @@ static char rcsid[] __attribute__ ((unused)) = "$Header: /usr/cvsroot/magic-8.0/
#include "cif/CIFint.h"
#include "cif/CIFread.h"
/* C99 compat */
#include "utils/malloc.h"
#ifdef USE_READLINE
#ifdef HAVE_READLINE
#include <readline/readline.h>

View File

@ -37,6 +37,9 @@ static char rcsid[] __attribute__ ((unused)) = "$Header: /usr/cvsroot/magic-8.0/
#include "database/database.h"
#include "dbwind/dbwind.h"
/* C99 compat */
#include "utils/malloc.h"
/* Global variables that indicate if we are reading or writing to a tty.
*/
global bool TxStdinIsatty;

View File

@ -41,4 +41,9 @@ typedef struct
PaVisit *PaVisitInit();
/* C99 compat */
extern void PaVisitAddClient();
extern int PaVisitFiles();
extern void PaVisitFree();
#endif /* _PATHVISIT_H */

View File

@ -74,6 +74,7 @@ extern int PaEnum();
extern int paVisitProcess();
extern void SetNoisyInt();
extern void SetNoisyDI();
extern bool ParsSplit();
#ifdef HAVE_ZLIB
extern gzFile PaZOpen(char *, char *, char *, char *, char *, char **);