Skip to content

Conversation

arnaud-lb
Copy link
Member

@arnaud-lb arnaud-lb commented Oct 24, 2024

Fixes GH-16567

_GNU_SOURCE is always defined by the build system on Linux, so we can simply include sys/mman.h when HAVE_MEMFD_CREATE is defined.

#endif

#ifdef HAVE_MPROTECT
#if defined(HAVE_MPROTECT) || defined(HAVE_MEMFD_CREATE)
Copy link
Member

@devnexen devnexen Oct 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it was because we did not want to enable memfd_create for FreeBSD.
One possible approach would be to do something like here at configure time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

opcache/zend_shared_alloc.c: needed but ineffective pre-processor instructions

2 participants