Skip to content

Commit

Permalink
Fix ZTS OPcache build on Cygwin
Browse files Browse the repository at this point in the history
`configure --enable-opcache --disable-opcache-jit --enable-zts` won't
compile on Cygwin.  We fix this, but that does not imply that OPcache
properly works in this environment, let alone that JIT would be
functional.

Closes GH-16920.
  • Loading branch information
cmb69 committed Nov 24, 2024
1 parent b0b876d commit 32ff46b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ PHP NEWS
- Intl:
. Bumped ICU requirement to ICU >= 57.1. (cmb)

- OPcache:
. Fixed ZTS OPcache build on Cygwin. (cmb)

- Output:
. Fixed calculation of aligned buffer size. (cmb)

Expand Down
4 changes: 2 additions & 2 deletions TSRM/TSRM.c
Original file line number Diff line number Diff line change
Expand Up @@ -778,15 +778,15 @@ TSRM_API size_t tsrm_get_ls_cache_tcb_offset(void)
return 0;
#elif defined(__x86_64__) && defined(__GNUC__) && !defined(__FreeBSD__) && \
!defined(__NetBSD__) && !defined(__OpenBSD__) && !defined(__MUSL__) && \
!defined(__HAIKU__)
!defined(__HAIKU__) && !defined(__CYGWIN__)
size_t ret;

asm ("movq _tsrm_ls_cache@gottpoff(%%rip),%0"
: "=r" (ret));
return ret;
#elif defined(__i386__) && defined(__GNUC__) && !defined(__FreeBSD__) && \
!defined(__NetBSD__) && !defined(__OpenBSD__) && !defined(__MUSL__) && \
!defined(__HAIKU__)
!defined(__HAIKU__) && !defined(__CYGWIN__)
size_t ret;

asm ("leal _tsrm_ls_cache@ntpoff,%0"
Expand Down

0 comments on commit 32ff46b

Please sign in to comment.