mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-26 09:46:09 +00:00
graphics/ocaml-lablgl: fix build with clang 16
Clang 16 has a new error about incompatible function types, which shows up when building graphics/ocaml-lablgl: togl.c:820:26: error: incompatible function pointer types assigning to 'void (*)(Tk_Window, Tk_ClassProcs *, ClientData)' (aka 'void (*)(struct Tk_Window_ *, struct Tk_ClassProcs *, void *)') from 'void (Tk_Window, const Tk_ClassProcs *, ClientData)' (aka 'void (struct Tk_Window_ *, const struct Tk_ClassProcs *, void *)') [-Wincompatible-function-pointer-types] SetClassProcsPtr = Tk_SetClassProcs; ^ ~~~~~~~~~~~~~~~~ This is because Tk_SetClassProcs() now takes a const Tk_ClassProcs pointer as its second parameter. Fix the SetClassProcsPtr declaration to match. PR: 272019 Approved by: fernape MFH: 2023Q2
This commit is contained in:
parent
9a521a21bc
commit
0e77cfcef8
11
graphics/ocaml-lablgl/files/patch-Togl_src_Togl_togl.c
Normal file
11
graphics/ocaml-lablgl/files/patch-Togl_src_Togl_togl.c
Normal file
@ -0,0 +1,11 @@
|
||||
--- Togl/src/Togl/togl.c.orig 2013-09-20 10:50:36 UTC
|
||||
+++ Togl/src/Togl/togl.c
|
||||
@@ -96,7 +96,7 @@ static void (*SetClassProcsPtr)
|
||||
/* pointer to Tk_SetClassProcs function in the stub table */
|
||||
|
||||
static void (*SetClassProcsPtr)
|
||||
- _ANSI_ARGS_((Tk_Window, Tk_ClassProcs *, ClientData));
|
||||
+ _ANSI_ARGS_((Tk_Window, const Tk_ClassProcs *, ClientData));
|
||||
#endif
|
||||
|
||||
/*
|
Loading…
Reference in New Issue
Block a user