Hi Aaron,

On Mon, Dec 08, 2025 at 08:48:54PM -0500, Aaron Merey wrote:
> Currently we check for openat2 RESOLVE_IN_ROOT support using
> AC_LINK_IFELSE.  HAVE_OPENAT2_RESOLVE_IN_ROOT is defined when
> AC_LINK_IFELSE succeeds.
> 
> It is possible for openat2 and RESOLVE_IN_ROOT to be
> present in headers but the kernel does not implement it.  In this case
> AC_LINK_IFELSE succeeds and HAVE_OPENAT2_RESOLVE_IN_ROOT is defined,
> but openat2 calls using RESOLVE_IN_ROOT always fail with ENOSYS for
> instance.
> 
> Fix this by using AC_RUN_IFELSE instead of AC_LINK_IFELSE when
> determining whether to define HAVE_OPENAT2_RESOLVE_IN_ROOT.

I agree with Arnout in the other thread that this is probably not
needed here. There is already fallback code in both link_map and
dwfl_segment_report_module there is a check for enosys to then use
reguar open. Is that not working as intended?

Cheers,

Mark

Reply via email to