Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for tcl 9.0 #1689

Merged
merged 1 commit into from
Oct 9, 2024
Merged

Fix for tcl 9.0 #1689

merged 1 commit into from
Oct 9, 2024

Conversation

michaelortmann
Copy link
Member

Found by: michaelortmann
Patch by: michaelortmann
Fixes:

One-line summary:

Additional description (if needed):

Test cases demonstrating functionality (if applicable):
Fixes the following make error with tcl 9.0:

gcc -fPIC -I/usr/include/python3.12 -I/usr/include/python3.12  -fno-strict-overflow -Wsign-compare -march=x86-64 -mtune=generic -O3 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection         -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -g -ffile-prefix-map=/build/python/src=/usr/src/debug/python -flto=auto -ffat-lto-objects -DNDEBUG -g -O3 -Wall -march=native -O2 -g3 -fsanitize=address,undefined,leak -Wall -DFORTIFY_SOURCE=3 -pipe -Wall -I. -I../../.. -I../../.. -I../../../src/mod  -DHAVE_CONFIG_H -I/home/michael/opt/tcl9.0.0/include -Og -g3 -DDEBUG -DDEBUG_ASSERT -DDEBUG_MEM -DDEBUG_DNS  -DMAKING_MODS -c .././python.mod/python.c && mv -f python.o ../
In file included from .././python.mod/python.c:46:
.././python.mod/pycmds.c: In function ‘py_dir’:
.././python.mod/pycmds.c:390:55: error: passing argument 3 of ‘Tcl_ListObjGetElements’ from incompatible pointer type [-Wincompatible-pointer-types]
  390 |       if (Tcl_ListObjGetElements(tclinterp, tcl_list, &objc, &objv) == TCL_ERROR)
      |                                                       ^~~~~
      |                                                       |
      |                                                       int *
In file included from /home/michael/opt/tcl9.0.0/include/tcl.h:2439,
                 from ../../../lush.h:4,
                 from ../../../src/main.h:42,
                 from ../../../src/mod/module.h:28,
                 from .././python.mod/python.c:29:
/home/michael/opt/tcl9.0.0/include/tclDecls.h:1785:61: note: expected ‘Tcl_Size *’ {aka ‘long int *’} but argument is of type ‘int *’
 1785 |                                 Tcl_Obj *listPtr, Tcl_Size *objcPtr,
      |                                                   ~~~~~~~~~~^~~~~~~
make[2]: *** [Makefile:19: ../python.o] Error 1
make[2]: Leaving directory '/home/michael/projects/eggdrop/src/mod/python.mod'
make[1]: *** [Makefile:60: python.mod_so] Error 2
make[1]: Leaving directory '/home/michael/projects/eggdrop/src/mod'
make: *** [Makefile:251: debug] Error 2

@vanosg vanosg added this to the v1.10.0 milestone Oct 9, 2024
@vanosg vanosg added the Python label Oct 9, 2024
@vanosg vanosg merged commit be78069 into eggheads:develop Oct 9, 2024
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants