Browse Source

feat(static): add ftp, gettext, gmp, imagick, mbregex, parallel, protobuf, shmop, soap, ssh2, sysmsg, sysvshm, tidy, xlswriter, yaml and zstd extensions (#773)

Kévin Dunglas 10 months ago
parent
commit
3dbb3fd48d
3 changed files with 5 additions and 2 deletions
  1. 1 0
      .github/workflows/static.yaml
  2. 1 1
      build-static.sh
  3. 3 1
      static-builder.Dockerfile

+ 1 - 0
.github/workflows/static.yaml

@@ -127,6 +127,7 @@ jobs:
           set: |
             ${{ matrix.debug && 'static-builder.args.DEBUG_SYMBOLS=1' || '' }}
             ${{ matrix.mimalloc && 'static-builder.args.MIMALLOC=1' || '' }}
+            ${{ matrix.platform == 'linux/arm64' && 'static-builder.args.NO_COMPRESS=1' || '' }}
             *.tags=
             *.platform=${{ matrix.platform }}
             *.cache-from=type=gha,scope=${{ needs.prepare.outputs.ref || github.ref }}-static-builder${{ matrix.debug && '-debug' || '' }}${{ matrix.mimalloc && '-mimalloc' || '' }}

+ 1 - 1
build-static.sh

@@ -29,7 +29,7 @@ if [ -z "${PHP_EXTENSIONS}" ]; then
         export PHP_EXTENSIONS
         cd -
     else
-        export PHP_EXTENSIONS="apcu,bcmath,bz2,calendar,ctype,curl,dba,dom,exif,fileinfo,filter,gd,iconv,igbinary,intl,ldap,mbregex,mbstring,mysqli,mysqlnd,opcache,openssl,pcntl,pdo,pdo_mysql,pdo_pgsql,pdo_sqlite,pgsql,phar,posix,readline,redis,session,simplexml,sockets,sodium,sqlite3,sysvsem,tokenizer,xml,xmlreader,xmlwriter,zip,zlib"
+        export PHP_EXTENSIONS="apcu,bcmath,bz2,calendar,ctype,curl,dba,dom,exif,fileinfo,filter,ftp,gd,gmp,gettext,iconv,igbinary,imagick,intl,ldap,mbregex,mbstring,mysqli,mysqlnd,opcache,openssl,parallel,pcntl,pdo,pdo_mysql,pdo_pgsql,pdo_sqlite,pgsql,phar,posix,protobuf,readline,redis,session,shmop,simplexml,soap,sockets,sodium,sqlite3,ssh2,sysvmsg,sysvsem,sysvshm,tidy,tokenizer,xlswriter,xml,xmlreader,xmlwriter,zip,zlib,yaml,zstd"
     fi
 fi
 

+ 3 - 1
static-builder.Dockerfile

@@ -13,6 +13,7 @@ ARG CLEAN=''
 ARG EMBED=''
 ARG DEBUG_SYMBOLS=''
 ARG MIMALLOC=''
+ARG NO_COMPRESS=''
 
 SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
 
@@ -84,4 +85,5 @@ COPY *.* ./
 COPY caddy caddy
 COPY C-Thread-Pool C-Thread-Pool
 
-RUN --mount=type=secret,id=github-token GITHUB_TOKEN=$(cat /run/secrets/github-token) ./build-static.sh
+RUN --mount=type=secret,id=github-token GITHUB_TOKEN=$(cat /run/secrets/github-token) ./build-static.sh && \
+	rm -Rf dist/static-php-cli/source/*