Artifacts Associated With Ticket dc1db1588e4c6c36
Ticket change [ce054a0614] (rid 195124) by dkf on 2021-07-03 11:40:53:
- assignee initialized to: "nobody"
- closer initialized to: "nobody"
- cmimetype initialized to: "text/html"
- comment initialized to:
In the current <code>core-8-branch</code> there are lots of warnings when building the notifier. The following is from <code>tclKqueueNotfy.c</code>, but equivalent ones are also produced by <code>tclEpollNotfy.c</code>. <pre style="overflow-x:scroll;"> In file included from /Users/dkf/tcl/unix/tclKqueueNotfy.c:1: /Users/dkf/tcl/generic/tclInt.h:5208:52: warning: uninitialized 'const TclUnusedFile_unix_tclKqueueNotfy_c' is invalid in C++ [-Wc++-compat] 5208 | static __attribute__((used)) const void *const TclUnusedFile_ ## name; \ | ^~~~~~~~~~~~~~ /Users/dkf/tcl/unix/tclKqueueNotfy.c:766:1: note: in expansion of macro 'TCL_MAC_EMPTY_FILE' 766 | TCL_MAC_EMPTY_FILE(unix_tclKqueueNotfy_c) | ^~~~~~~~~~~~~~~~~~ /Users/dkf/tcl/generic/tclInt.h:5209:30: warning: duplicate declaration of 'TclUnusedFile_unix_tclKqueueNotfy_c' is invalid in C++ [-Wc++-compat] 5209 | static const void *const TclUnusedFile_ ## name = NULL; | ^~~~~~~~~~~~~~ /Users/dkf/tcl/unix/tclKqueueNotfy.c:766:1: note: in expansion of macro 'TCL_MAC_EMPTY_FILE' 766 | TCL_MAC_EMPTY_FILE(unix_tclKqueueNotfy_c) | ^~~~~~~~~~~~~~~~~~ /Users/dkf/tcl/generic/tclInt.h:5208:52: note: previous declaration of 'TclUnusedFile_unix_tclKqueueNotfy_c' was here 5208 | static __attribute__((used)) const void *const TclUnusedFile_ ## name; \ | ^~~~~~~~~~~~~~ /Users/dkf/tcl/unix/tclKqueueNotfy.c:766:1: note: in expansion of macro 'TCL_MAC_EMPTY_FILE' 766 | TCL_MAC_EMPTY_FILE(unix_tclKqueueNotfy_c) | ^~~~~~~~~~~~~~~~~~ </pre> The problem is that deleting the symbol makes the macOS linker complain about an empty file. My preferred fix is simple: don't use the <code>-Wc++-compat</code> flag as these files simply do not ever need to build as C++. Alternatively, we could find some other way of making a symbol that exists so that file is non-empty but gets elided during linking, but frankly I'd just drop TIP 557 support in these implementation files as it has proved to not be a win (but supporting it for our <em>headers</em> is fine). It's equivalent (in my mind) to how some of Tk's implementation on some platforms is in Objective C, but Tk's API is not. - is_private initialized to: "0"
- login: "dkf"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- severity initialized to: "Minor"
- status initialized to: "Open"
- submitter initialized to: "dkf"
- subsystem initialized to: "01. Notifier"
- title initialized to: "warnings when building on macOS"
- type initialized to: "Bug"
Ticket change [30a81dfbbb] (rid 195679) by jan.nijtmans on 2021-09-22 08:27:18:
- closedate changed to: "2459479.85230257"
- closer changed to: "jan.nijtmans"
- icomment: "Fixed [b46c4d3d9cac5dbf|here]"
- login: "jan.nijtmans"
- mimetype: "text/x-fossil-wiki"
- resolution changed to: "Fixed"
- status changed to: "Closed"
Ticket change [4dbfab9bf7] (rid 195680) by jan.nijtmans on 2021-09-22 08:27:36:
- assignee changed to: "jan.nijtmans"
- closedate changed to: "2459479.85251127"
- login: "jan.nijtmans"
- mimetype: "text/plain"