The recent patch to devel/readline breaks the build of net/samba419. readline is an unavoidable dependency there. (Python needs it, and Samba needs Python.) [00:01:18] [1683/2606] Compiling libcli/smbreadline/smbreadline.c [00:01:18] runner ['cc', '-D_SAMBA_BUILD_=4', '-DHAVE_CONFIG_H=1', '-O2', '-pipe', '-march=haswell', '-DLIBICONV_PLUG', '-DLDAP_DEPRECATED', '-fno-color-diagnostics', '-fstack-protector-strong', '-isystem', '/usr/local/include', '-fno-strict-aliasing', '-fno-omit-frame-pointer', '-MMD', '-D_GNU_SOURCE=1', '-D_XOPEN_SOURCE_EXTENDED=1', '-DHAVE_CONFIG_H=1', '-fPIC', '-D__STDC_WANT_LIB_EXT1__=1', '-D_REENTRANT', '-fstack-protector-strong', '-fstack-clash-protection', '-DSTATIC_SMBREADLINE_MODULES=NULL', '-DSTATIC_SMBREADLINE_MODULES_PROTO=extern void __SMBREADLINE_dummy_module_proto(void)', '-Ilibcli/smbreadline', '-I../../libcli/smbreadline', '-Iinclude/public', '-I../../include/public', '-Isource4', '-I../../source4', '-Ilib', '-I../../lib', '-Isource4/lib', '-I../../source4/lib', '-Isource4/include', '-I../../source4/include', '-Iinclude', '-I../../include', '-Ilib/replace', '-I../../lib/replace', '-I.', '-I../..', '-I/usr/local/include', '../../libcli/smbreadline/smbreadline.c', '-c', '-o/wrkdirs/usr/ports/net/samba419/work/samba-4.19.8/bin/default/libcli/smbreadline/smbreadline.c.1.o', '-DLIBICONV_PLUG', '-isystem', '/usr/local/include'] [00:01:18] ../../libcli/smbreadline/smbreadline.c:139:38: warning: 'CPPFunction' is deprecated [-Wdeprecated-declarations] [00:01:18] 139 | rl_attempted_completion_function = RL_COMPLETION_CAST completion_fn; [00:01:18] | ^ [00:01:18] ../../lib/replace/system/readline.h:50:31: note: expanded from macro 'RL_COMPLETION_CAST' [00:01:18] 50 | # define RL_COMPLETION_CAST (CPPFunction *) [00:01:18] | ^ [00:01:18] /usr/local/include/readline/rltypedefs.h:38:50: note: 'CPPFunction' has been explicitly marked deprecated here [00:01:18] 38 | typedef char **CPPFunction (void) __attribute__((deprecated)); [00:01:18] | ^ [00:01:18] ../../libcli/smbreadline/smbreadline.c:139:36: error: incompatible function pointer types assigning to 'rl_completion_func_t *' (aka 'char **(*)(const char *, int, int)') from 'CPPFunction *' (aka 'char **(*)(void)') [-Wincompatible-function-pointer-types] [00:01:18] 139 | rl_attempted_completion_function = RL_COMPLETION_CAST completion_fn; [00:01:18] | ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ [00:01:18] 1 warning and 1 error generated. [00:01:18] [00:01:18] Waf: Leaving directory `/wrkdirs/usr/ports/net/samba419/work/samba-4.19.8/bin/default' [00:01:18] Build failed
Thanks for the report!
I could confirm that it breaks net/samba{416,419}.
*** Bug 281789 has been marked as a duplicate of this bug. ***
As workaround add to make.conf: .if ${.CURDIR:M*/net/samba419} CFLAGS+=-D_FUNCTION_DEF .endif
(In reply to Po-Chuan Hsieh from comment #2) Confirm for both (FreeBSD 14.1, Poudriere)
Created attachment 253952 [details] Patch file Fix build after commit ee994524fffd. I confirmed build of net/samba416 and net/samba419 succeeds with poudriere and 14.1-RELEASE amd64 jail.
(In reply to Yasuhiro Kimura from comment #6) I've not looked deep into why -D_FUNCTION_DEF would fix the issue, but if it is working, let's commit that. Reviewed by: 0mp
(In reply to Mateusz Piotrowski from comment #7) It works because readline tries to deprecate parts of its API, but the header setting __attribute__((deprecated)) provides an escape hatch: https://git.savannah.gnu.org/cgit/readline.git/tree/rltypedefs.h#n31. (lines 31 to 44).
*** Bug 281818 has been marked as a duplicate of this bug. ***
If it is only a temporary fix, then let's go for the fix suggested by dim@ in 281818.
Comment on attachment 253952 [details] Patch file Let's commit the patch suggested by dim@ in 281818.
Fixes for samba have been committed: * net/samba416: https://cgit.freebsd.org/ports/commit/?id=48cea5704f4376df85a42c5b145c62f8830c6822 * net/samba419: https://cgit.freebsd.org/ports/commit/?id=c81f658808ee608f60198584a870087946cefc98
Thank you, Dimitry!