lol

vala: work around clang 16 function pointer errors

Clang 16 makes casting function pointers between incompatible types an
error, which causes Vala to fail to build things using glib-2.0.vapi.

`-Wno-incompatible-function-pointer-types` is set unconditionally
because it is supported by all versions of clang and GCC in nixpkgs.

See https://gitlab.gnome.org/GNOME/vala/-/issues/1413.

+9
+9
pkgs/development/compilers/vala/setup-hook.sh
··· 7 7 8 8 addEnvHooks "$hostOffset" make_vala_find_vapi_files 9 9 10 + disable_incompabile_pointer_conversion_warning() { 11 + # Work around incompatible function pointer conversion errors with clang 16 12 + # by setting ``-Wno-incompatible-function-pointer-types` in an env hook. 13 + # See https://gitlab.gnome.org/GNOME/vala/-/issues/1413. 14 + NIX_CFLAGS_COMPILE+=" -Wno-incompatible-function-pointer-types" 15 + } 16 + 17 + addEnvHooks "$hostOffset" disable_incompabile_pointer_conversion_warning 18 + 10 19 _multioutMoveVapiDirs() { 11 20 moveToOutput share/vala/vapi "${!outputDev}" 12 21 moveToOutput share/vala-@apiVersion@/vapi "${!outputDev}"