It seems some systems like Centos 7 have the SYS_copy_file_range define but fail the syscall when actually being called. The current configure check only compiles the testcode, but it doesn't run it, so this is not detected properly.
This bug was referenced in samba master: 22a58a51846749495613e5b572c31ba4752bc61b 4354823c5146753ef8a3791bc8562379096659b8
Created attachment 16728 [details] Patch for 4.15 cherry-picked from master Patched code is in only in 4.15, so no need for backports to older versions.
Comment on attachment 16728 [details] Patch for 4.15 cherry-picked from master The 2nd patch is actually wrong, we should not do a runtime check at configure time. We should actually revert that one in master. And the first commit is only cosmetic and is not needed in 4.15.
(In reply to Stefan Metzmacher from comment #3) https://bugzilla.samba.org/show_bug.cgi?id=14795 actually implemented a real runtime check.
(In reply to Stefan Metzmacher from comment #3) https://gitlab.com/samba-team/samba/-/merge_requests/2153