Skip to content

Commit

Permalink
php72-swoole, php73-swoole: Fix arm build
Browse files Browse the repository at this point in the history
  • Loading branch information
ryandesign committed Mar 20, 2022
1 parent b6d4b81 commit cd9e090
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions php/php-swoole/Portfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ if {[vercmp ${php.branch} 7.2] >= 0} {
checksums rmd160 16b6ae49390c789ab963c5426163a43869090447 \
sha256 ca888cb886c883092ebe8788253d600bc52c384e74e27110f97b04ecea6b6fda \
size 1851160
patchfiles-append arm.patch
patchfiles-append timer.patch
} elseif {[vercmp ${php.branch} 7.1] >= 0} {
version 4.5.11
Expand Down
15 changes: 15 additions & 0 deletions php/php-swoole/files/arm.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
Do not add -latomic ever; macOS does not have it, not even on ARM.
Reverts https://github.com/swoole/swoole-src/commit/741ace2990c5f22f098af9f874bebbdf74a342a5
--- config.m4.orig 2022-03-16 09:37:42.000000000 -0500
+++ config.m4 2022-03-19 19:34:44.000000000 -0500
@@ -784,10 +784,6 @@
CXXFLAGS="$CXXFLAGS -std=c++11"
fi

- if test "$SW_CPU" = "arm"; then
- PHP_ADD_LIBRARY(atomic, 1, SWOOLE_SHARED_LIBADD)
- fi
-
PHP_ADD_BUILD_DIR($ext_builddir/ext-src)
PHP_ADD_BUILD_DIR($ext_builddir/src/core)
PHP_ADD_BUILD_DIR($ext_builddir/src/memory)

0 comments on commit cd9e090

Please sign in to comment.