RTimothyEdwards / magic

Magic VLSI Layout Tool
Other
498 stars 103 forks source link

Build fails on GCC 14: `CmdTZ.c:984:21: error: assignment to ‘CellUse *’ {aka ‘struct celluse *’} from ‘ClientData’ {aka ‘long unsigned int’} makes pointer from integer without a cast [-Wint-conversion]` #323

Open Zopolis4 opened 3 months ago

Zopolis4 commented 3 months ago

Cloned from git, checked out tag 8.3.489, configured with ./configure:

...
config.status: creating makedbh

-----------------------------------------------------------
Configuration Summary (principle requirements):

X11:          yes
Python3:      yes
OpenGL:       yes
Vector fonts: yes
Cairo:        yes
Tcl/Tk:       no

  Without Tcl/Tk, you cannot run the enhanced version of magic
  with the toolbar and menus, and a number of other functions
  are disabled.  If you did not specifically disable Tcl/Tk on
  the configure command line, then getting this message means
  that you do not have Tcl/Tk headers and or libraries installed,
  or they are not in a standard path.  Try using configure options
  --with-tcl=<DIR> and --with-tk=<DIR>.

-----------------------------------------------------------

Use 'make' to compile and 'make install' to install.

-----------------------------------------------------------

chronos@a2737da53b73 ~/magic $ make
...
--- compiling commands/CmdTZ.o
rm -f CmdTZ.o
gcc -g -m64 -fPIC -Werror=implicit-function-declaration   -I. -I..  -DCAD_DIR=\"/usr/local/lib\" -DBIN_DIR=\"/usr/local/bin\"  -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DSIZEOF_VOID_P=8 -DSIZEOF_UNSIGNED_INT=4 -DSIZEOF_UNSIGNED_LONG=8 -DSIZEOF_UNSIGNED_LONG_LONG=8 -DSTDC_HEADERS=1 -DHAVE_SETENV=1 -DHAVE_PUTENV=1 -DHAVE_SYS_MMAN_H=1 -DHAVE_DIRENT_H=1 -DHAVE_LIMITS_H=1 -DHAVE_PATHS_H=1 -DHAVE_VA_COPY=1 -DHAVE___VA_COPY=1 -DHAVE_ZLIB=1 -DFILE_LOCKS=1 -DCALMA_MODULE=1 -DCIF_MODULE=1 -DPLOT_MODULE=1 -DLEF_MODULE=1 -DUSE_READLINE=1 -DHAVE_LIBREADLINE=1 -DHAVE_LIBREADLINE=1 -DHAVE_LIBREADLINE=1 -DHAVE_LIBREADLINE=1 -DHAVE_READLINE=1 -DHAVE_PTHREADS=1 -DROUTE_MODULE=1 -DRSIM_MODULE=1 -DUSE_NEW_MACROS=1 -DHAVE_LIBGL=1 -DHAVE_LIBGLU=1 -DVECTOR_FONTS=1 -DHAVE_LIBCAIRO=1 -Dlinux=1 -DSYSV=1 -DISC=1 -DMAGIC_VERSION=\"`cat ../VERSION | cut -d. -f1-2`\" -DMAGIC_REVISION=\"`cat ../VERSION | cut -d. -f3`\" -DMAGIC_COMMIT=\"`git rev-parse HEAD`\" -DGCORE=\"no\" -DSHDLIB_EXT=\"\" -DNDEBUG  -c CmdTZ.c
CmdTZ.c: In function ‘CmdWhat’:
CmdTZ.c:984:21: error: assignment to ‘CellUse *’ {aka ‘struct celluse *’} from ‘ClientData’ {aka ‘long unsigned int’} makes pointer from integer without a cast [-Wint-conversion]
  984 |         EditCellUse = w->w_surfaceID;
      |                     ^
make[2]: *** [../rules.mak:25: CmdTZ.o] Error 1
make[2]: Leaving directory '/home/chronos/user/magic/commands'
make[1]: *** [Makefile:52: modules] Error 1
make[1]: Leaving directory '/home/chronos/user/magic'
make: *** [Makefile:22: standard] Error 2