mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-03 23:05:41 +08:00
Compare commits
21 Commits
fix/protob
...
2.8.4
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d411fac9a1 | ||
|
|
ddb9e3e7e4 | ||
|
|
fef361225a | ||
|
|
0b2b1d51e1 | ||
|
|
820d77b8b2 | ||
|
|
cd3eb3d41d | ||
|
|
fb8f8d4ef8 | ||
|
|
1a476d0e80 | ||
|
|
e5ad72214c | ||
|
|
c339b900f8 | ||
|
|
3ded9881e1 | ||
|
|
08a6bf38a4 | ||
|
|
cae668a947 | ||
|
|
e592488d7a | ||
|
|
a7184d0411 | ||
|
|
d535e4f102 | ||
|
|
5a5f54bdcd | ||
|
|
8f7897e13b | ||
|
|
daae5f2a7c | ||
|
|
766f7fa34f | ||
|
|
ecf712b2b7 |
@@ -11,7 +11,6 @@
|
|||||||
"require": {
|
"require": {
|
||||||
"php": ">= 8.3",
|
"php": ">= 8.3",
|
||||||
"ext-mbstring": "*",
|
"ext-mbstring": "*",
|
||||||
"ext-simplexml": "*",
|
|
||||||
"ext-zlib": "*",
|
"ext-zlib": "*",
|
||||||
"laravel/prompts": "^0.1.12",
|
"laravel/prompts": "^0.1.12",
|
||||||
"symfony/console": "^5.4 || ^6 || ^7",
|
"symfony/console": "^5.4 || ^6 || ^7",
|
||||||
|
|||||||
@@ -63,7 +63,8 @@
|
|||||||
],
|
],
|
||||||
"ext-depends-windows": [
|
"ext-depends-windows": [
|
||||||
"zlib",
|
"zlib",
|
||||||
"openssl"
|
"openssl",
|
||||||
|
"brotli"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"dba": {
|
"dba": {
|
||||||
|
|||||||
@@ -109,8 +109,7 @@
|
|||||||
"krb5"
|
"krb5"
|
||||||
],
|
],
|
||||||
"lib-suggests-windows": [
|
"lib-suggests-windows": [
|
||||||
"brotli",
|
"brotli"
|
||||||
"zstd"
|
|
||||||
],
|
],
|
||||||
"frameworks": [
|
"frameworks": [
|
||||||
"CoreFoundation",
|
"CoreFoundation",
|
||||||
@@ -494,7 +493,7 @@
|
|||||||
"static-libs-windows": [
|
"static-libs-windows": [
|
||||||
"libjpeg_a.lib"
|
"libjpeg_a.lib"
|
||||||
],
|
],
|
||||||
"lib-suggests-windows": [
|
"lib-depends": [
|
||||||
"zlib"
|
"zlib"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -763,7 +762,6 @@
|
|||||||
"xz"
|
"xz"
|
||||||
],
|
],
|
||||||
"lib-suggests-windows": [
|
"lib-suggests-windows": [
|
||||||
"zstd",
|
|
||||||
"openssl"
|
"openssl"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -1000,6 +998,9 @@
|
|||||||
],
|
],
|
||||||
"headers": [
|
"headers": [
|
||||||
"wtr/watcher-c.h"
|
"wtr/watcher-c.h"
|
||||||
|
],
|
||||||
|
"frameworks": [
|
||||||
|
"CoreServices"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"xz": {
|
"xz": {
|
||||||
|
|||||||
@@ -8,25 +8,30 @@
|
|||||||
"alt": false
|
"alt": false
|
||||||
},
|
},
|
||||||
"amqp": {
|
"amqp": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/amqp",
|
||||||
"path": "php-src/ext/amqp",
|
"path": "php-src/ext/amqp",
|
||||||
|
"filename": "amqp.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"apcu": {
|
"apcu": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
"pecl": "APCu",
|
"url": "https://pecl.php.net/get/APCu",
|
||||||
"path": "php-src/ext/apcu",
|
"path": "php-src/ext/apcu",
|
||||||
|
"filename": "apcu.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ast": {
|
"ast": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/ast",
|
||||||
"path": "php-src/ext/ast",
|
"path": "php-src/ext/ast",
|
||||||
|
"filename": "ast.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -80,16 +85,20 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"dio": {
|
"dio": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/dio",
|
||||||
"path": "php-src/ext/dio",
|
"path": "php-src/ext/dio",
|
||||||
|
"filename": "dio.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ev": {
|
"ev": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/ev",
|
||||||
"path": "php-src/ext/ev",
|
"path": "php-src/ext/ev",
|
||||||
|
"filename": "ev.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -106,8 +115,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-ds": {
|
"ext-ds": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/ds",
|
||||||
"path": "php-src/ext/ds",
|
"path": "php-src/ext/ds",
|
||||||
|
"filename": "ds.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -123,8 +134,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-excimer": {
|
"ext-excimer": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/excimer",
|
||||||
"path": "php-src/ext/excimer",
|
"path": "php-src/ext/excimer",
|
||||||
|
"filename": "excimer.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -149,8 +162,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-grpc": {
|
"ext-grpc": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/grpc",
|
||||||
"path": "php-src/ext/grpc",
|
"path": "php-src/ext/grpc",
|
||||||
|
"filename": "grpc.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": [
|
"path": [
|
||||||
@@ -159,16 +174,20 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-imagick": {
|
"ext-imagick": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/imagick",
|
||||||
"path": "php-src/ext/imagick",
|
"path": "php-src/ext/imagick",
|
||||||
|
"filename": "imagick.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-imap": {
|
"ext-imap": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/imap",
|
||||||
"path": "php-src/ext/imap",
|
"path": "php-src/ext/imap",
|
||||||
|
"filename": "imap.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": [
|
"path": [
|
||||||
@@ -188,15 +207,19 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-maxminddb": {
|
"ext-maxminddb": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/maxminddb",
|
||||||
|
"filename": "ext-maxminddb.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-memcache": {
|
"ext-memcache": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/memcache",
|
||||||
"path": "php-src/ext/memcache",
|
"path": "php-src/ext/memcache",
|
||||||
|
"filename": "memcache.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -212,8 +235,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-simdjson": {
|
"ext-simdjson": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/simdjson",
|
||||||
"path": "php-src/ext/simdjson",
|
"path": "php-src/ext/simdjson",
|
||||||
|
"filename": "simdjson.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -230,32 +255,40 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-ssh2": {
|
"ext-ssh2": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/ssh2",
|
||||||
"path": "php-src/ext/ssh2",
|
"path": "php-src/ext/ssh2",
|
||||||
|
"filename": "ssh2.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-trader": {
|
"ext-trader": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/trader",
|
||||||
"path": "php-src/ext/trader",
|
"path": "php-src/ext/trader",
|
||||||
|
"filename": "trader.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-uuid": {
|
"ext-uuid": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/uuid",
|
||||||
"path": "php-src/ext/uuid",
|
"path": "php-src/ext/uuid",
|
||||||
|
"filename": "uuid.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-uv": {
|
"ext-uv": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/uv",
|
||||||
"path": "php-src/ext/uv",
|
"path": "php-src/ext/uv",
|
||||||
|
"filename": "uv.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -272,7 +305,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ext-zip": {
|
"ext-zip": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/zip",
|
||||||
|
"filename": "ext-zip.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -377,8 +412,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"igbinary": {
|
"igbinary": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/igbinary",
|
||||||
"path": "php-src/ext/igbinary",
|
"path": "php-src/ext/igbinary",
|
||||||
|
"filename": "igbinary.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "COPYING"
|
"path": "COPYING"
|
||||||
@@ -402,8 +439,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"inotify": {
|
"inotify": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/inotify",
|
||||||
"path": "php-src/ext/inotify",
|
"path": "php-src/ext/inotify",
|
||||||
|
"filename": "inotify.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -602,6 +641,7 @@
|
|||||||
"libjpeg": {
|
"libjpeg": {
|
||||||
"type": "ghtar",
|
"type": "ghtar",
|
||||||
"repo": "libjpeg-turbo/libjpeg-turbo",
|
"repo": "libjpeg-turbo/libjpeg-turbo",
|
||||||
|
"prefer-stable": true,
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE.md"
|
"path": "LICENSE.md"
|
||||||
@@ -805,8 +845,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"memcached": {
|
"memcached": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/memcached",
|
||||||
"path": "php-src/ext/memcached",
|
"path": "php-src/ext/memcached",
|
||||||
|
"filename": "memcached.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -844,8 +886,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"msgpack": {
|
"msgpack": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/msgpack",
|
||||||
"path": "php-src/ext/msgpack",
|
"path": "php-src/ext/msgpack",
|
||||||
|
"filename": "msgpack.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -945,31 +989,39 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"opentelemetry": {
|
"opentelemetry": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/opentelemetry",
|
||||||
"path": "php-src/ext/opentelemetry",
|
"path": "php-src/ext/opentelemetry",
|
||||||
|
"filename": "opentelemetry.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"parallel": {
|
"parallel": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/parallel",
|
||||||
"path": "php-src/ext/parallel",
|
"path": "php-src/ext/parallel",
|
||||||
|
"filename": "parallel.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"pcov": {
|
"pcov": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/pcov",
|
||||||
|
"filename": "pcov.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"pdo_sqlsrv": {
|
"pdo_sqlsrv": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/pdo_sqlsrv",
|
||||||
"path": "php-src/ext/pdo_sqlsrv",
|
"path": "php-src/ext/pdo_sqlsrv",
|
||||||
|
"filename": "pdo_sqlsrv.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -1002,8 +1054,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"protobuf": {
|
"protobuf": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/protobuf-5.34.1.tgz",
|
||||||
"path": "php-src/ext/protobuf",
|
"path": "php-src/ext/protobuf",
|
||||||
|
"filename": "protobuf.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -1062,8 +1116,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"redis": {
|
"redis": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/redis",
|
||||||
"path": "php-src/ext/redis",
|
"path": "php-src/ext/redis",
|
||||||
|
"filename": "redis.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": [
|
"path": [
|
||||||
@@ -1100,8 +1156,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"sqlsrv": {
|
"sqlsrv": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/sqlsrv",
|
||||||
"path": "php-src/ext/sqlsrv",
|
"path": "php-src/ext/sqlsrv",
|
||||||
|
"filename": "sqlsrv.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -1164,16 +1222,20 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"xhprof": {
|
"xhprof": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/xhprof",
|
||||||
"path": "php-src/ext/xhprof-src",
|
"path": "php-src/ext/xhprof-src",
|
||||||
|
"filename": "xhprof.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"xlswriter": {
|
"xlswriter": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/xlswriter",
|
||||||
"path": "php-src/ext/xlswriter",
|
"path": "php-src/ext/xlswriter",
|
||||||
|
"filename": "xlswriter.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
@@ -1191,8 +1253,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"yac": {
|
"yac": {
|
||||||
"type": "pecl",
|
"type": "url",
|
||||||
|
"url": "https://pecl.php.net/get/yac",
|
||||||
"path": "php-src/ext/yac",
|
"path": "php-src/ext/yac",
|
||||||
|
"filename": "yac.tgz",
|
||||||
"license": {
|
"license": {
|
||||||
"type": "file",
|
"type": "file",
|
||||||
"path": "LICENSE"
|
"path": "LICENSE"
|
||||||
|
|||||||
@@ -33,4 +33,14 @@ class sqlsrv extends Extension
|
|||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function patchBeforeMake(): bool
|
||||||
|
{
|
||||||
|
$makefile = SOURCE_PATH . '/php-src/Makefile';
|
||||||
|
$makeContent = file_get_contents($makefile);
|
||||||
|
$makeContent = preg_replace('/^(CFLAGS_(?:PDO_)?SQLSRV=.*?)\s+\/W4\b/m', '$1', $makeContent);
|
||||||
|
$makeContent = preg_replace('/^(CFLAGS_(?:PDO_)?SQLSRV=.*?)\s+\/WX\b/m', '$1', $makeContent);
|
||||||
|
file_put_contents($makefile, $makeContent);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ trait libjpeg
|
|||||||
->addConfigureArgs(
|
->addConfigureArgs(
|
||||||
'-DENABLE_STATIC=ON',
|
'-DENABLE_STATIC=ON',
|
||||||
'-DENABLE_SHARED=OFF',
|
'-DENABLE_SHARED=OFF',
|
||||||
|
'-DWITH_SYSTEM_ZLIB=ON'
|
||||||
)
|
)
|
||||||
->build();
|
->build();
|
||||||
// patch pkgconfig
|
// patch pkgconfig
|
||||||
|
|||||||
@@ -28,6 +28,7 @@ class libjpeg extends WindowsLibraryBase
|
|||||||
'-DENABLE_STATIC=ON ' .
|
'-DENABLE_STATIC=ON ' .
|
||||||
'-DBUILD_TESTING=OFF ' .
|
'-DBUILD_TESTING=OFF ' .
|
||||||
'-DWITH_JAVA=OFF ' .
|
'-DWITH_JAVA=OFF ' .
|
||||||
|
'-DWITH_SIMD=OFF ' .
|
||||||
'-DWITH_CRT_DLL=OFF ' .
|
'-DWITH_CRT_DLL=OFF ' .
|
||||||
"-DENABLE_ZLIB_COMPRESSION={$zlib} " .
|
"-DENABLE_ZLIB_COMPRESSION={$zlib} " .
|
||||||
'-DCMAKE_INSTALL_PREFIX=' . BUILD_ROOT_PATH . ' '
|
'-DCMAKE_INSTALL_PREFIX=' . BUILD_ROOT_PATH . ' '
|
||||||
|
|||||||
@@ -29,6 +29,7 @@ class ngtcp2 extends WindowsLibraryBase
|
|||||||
'-DBUILD_SHARED_LIBS=OFF ' .
|
'-DBUILD_SHARED_LIBS=OFF ' .
|
||||||
'-DENABLE_STATIC_CRT=ON ' .
|
'-DENABLE_STATIC_CRT=ON ' .
|
||||||
'-DENABLE_LIB_ONLY=ON ' .
|
'-DENABLE_LIB_ONLY=ON ' .
|
||||||
|
'-DENABLE_OPENSSL=OFF ' .
|
||||||
'-DCMAKE_INSTALL_PREFIX=' . BUILD_ROOT_PATH . ' '
|
'-DCMAKE_INSTALL_PREFIX=' . BUILD_ROOT_PATH . ' '
|
||||||
)
|
)
|
||||||
->execWithWrapper(
|
->execWithWrapper(
|
||||||
|
|||||||
@@ -16,43 +16,6 @@ use SPC\util\SPCTarget;
|
|||||||
*/
|
*/
|
||||||
class Downloader
|
class Downloader
|
||||||
{
|
{
|
||||||
/**
|
|
||||||
* Get latest stable version from PECL
|
|
||||||
*
|
|
||||||
* @param string $name Source name
|
|
||||||
* @param array $source Source meta info: [pecl?]
|
|
||||||
* @return array<int, string> [url, filename]
|
|
||||||
*/
|
|
||||||
public static function getPECLInfo(string $name, array $source): array
|
|
||||||
{
|
|
||||||
$package = $source['pecl'] ?? (str_starts_with($name, 'ext-') ? substr($name, 4) : $name);
|
|
||||||
$lp = strtolower($package);
|
|
||||||
$api_url = "https://pecl.php.net/rest/r/{$lp}/allreleases.xml";
|
|
||||||
logger()->debug("Fetching {$name} source from PECL: {$api_url}");
|
|
||||||
$xml = self::curlExec(
|
|
||||||
url: $api_url,
|
|
||||||
retries: self::getRetryAttempts()
|
|
||||||
);
|
|
||||||
$dom = new \SimpleXMLElement($xml);
|
|
||||||
$version = null;
|
|
||||||
if ($source['prefer-stable'] ?? false) {
|
|
||||||
foreach ($dom->r as $release) {
|
|
||||||
if ((string) $release->s === 'stable') {
|
|
||||||
$version = (string) $release->v;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
$version ??= isset($dom->r[0]) ? (string) $dom->r[0]->v : null;
|
|
||||||
if ($version === null) {
|
|
||||||
throw new DownloaderException("failed to find any release for {$name} on PECL");
|
|
||||||
}
|
|
||||||
$url = "https://pecl.php.net/get/{$package}-{$version}.tgz";
|
|
||||||
$filename = "{$package}-{$version}.tgz";
|
|
||||||
logger()->info("Found {$name} PECL version: {$version}");
|
|
||||||
return [$url, $filename];
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get latest version from PIE config (Packagist)
|
* Get latest version from PIE config (Packagist)
|
||||||
*
|
*
|
||||||
@@ -649,7 +612,6 @@ class Downloader
|
|||||||
* @param array{
|
* @param array{
|
||||||
* url?: string,
|
* url?: string,
|
||||||
* repo?: string,
|
* repo?: string,
|
||||||
* pecl?: string,
|
|
||||||
* rev?: string,
|
* rev?: string,
|
||||||
* path?: string,
|
* path?: string,
|
||||||
* filename?: string,
|
* filename?: string,
|
||||||
@@ -669,10 +631,6 @@ class Downloader
|
|||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
switch ($type) {
|
switch ($type) {
|
||||||
case 'pecl': // PECL (latest stable)
|
|
||||||
[$url, $filename] = self::getPECLInfo($name, $conf);
|
|
||||||
self::downloadFile($name, $url, $filename, $conf['path'] ?? $conf['extract'] ?? null, $download_as);
|
|
||||||
break;
|
|
||||||
case 'pie': // Packagist
|
case 'pie': // Packagist
|
||||||
[$url, $filename] = self::getPIEInfo($name, $conf);
|
[$url, $filename] = self::getPIEInfo($name, $conf);
|
||||||
self::downloadFile($name, $url, $filename, $conf['path'] ?? $conf['extract'] ?? null, $download_as, hooks: [[CurlHook::class, 'setupGithubToken']]);
|
self::downloadFile($name, $url, $filename, $conf['path'] ?? $conf['extract'] ?? null, $download_as, hooks: [[CurlHook::class, 'setupGithubToken']]);
|
||||||
|
|||||||
@@ -152,7 +152,7 @@ class FileSystem
|
|||||||
$src_path = FileSystem::convertPath($from);
|
$src_path = FileSystem::convertPath($from);
|
||||||
switch (PHP_OS_FAMILY) {
|
switch (PHP_OS_FAMILY) {
|
||||||
case 'Windows':
|
case 'Windows':
|
||||||
f_passthru('xcopy "' . $src_path . '" "' . $dst_path . '" /s/e/v/y/i');
|
f_passthru('xcopy "' . $src_path . '" "' . $dst_path . '" /s/e/y/i');
|
||||||
break;
|
break;
|
||||||
case 'Linux':
|
case 'Linux':
|
||||||
case 'Darwin':
|
case 'Darwin':
|
||||||
|
|||||||
@@ -22,9 +22,7 @@ class ConfigValidator
|
|||||||
'regex' => 'string', // regex pattern
|
'regex' => 'string', // regex pattern
|
||||||
'rev' => 'string', // revision/branch
|
'rev' => 'string', // revision/branch
|
||||||
'repo' => 'string', // repository name
|
'repo' => 'string', // repository name
|
||||||
'pecl' => 'string', // PECL package name
|
|
||||||
'match' => 'string', // match pattern (aaa*bbb)
|
'match' => 'string', // match pattern (aaa*bbb)
|
||||||
'query' => 'string', // query string for API requests
|
|
||||||
'filename' => 'string', // filename
|
'filename' => 'string', // filename
|
||||||
'path' => 'string', // copy path
|
'path' => 'string', // copy path
|
||||||
'extract' => 'string', // copy path (alias of path)
|
'extract' => 'string', // copy path (alias of path)
|
||||||
@@ -75,13 +73,12 @@ class ConfigValidator
|
|||||||
private const array SOURCE_TYPE_FIELDS = [
|
private const array SOURCE_TYPE_FIELDS = [
|
||||||
'filelist' => [['url', 'regex'], []],
|
'filelist' => [['url', 'regex'], []],
|
||||||
'git' => [['url', 'rev'], ['path', 'extract', 'submodules']],
|
'git' => [['url', 'rev'], ['path', 'extract', 'submodules']],
|
||||||
'ghtagtar' => [['repo'], ['path', 'extract', 'prefer-stable', 'match', 'query']],
|
'ghtagtar' => [['repo'], ['path', 'extract', 'prefer-stable', 'match']],
|
||||||
'ghtar' => [['repo'], ['path', 'extract', 'prefer-stable', 'match', 'query']],
|
'ghtar' => [['repo'], ['path', 'extract', 'prefer-stable', 'match']],
|
||||||
'ghrel' => [['repo', 'match'], ['path', 'extract', 'prefer-stable']],
|
'ghrel' => [['repo', 'match'], ['path', 'extract', 'prefer-stable']],
|
||||||
'url' => [['url'], ['filename', 'path', 'extract']],
|
'url' => [['url'], ['filename', 'path', 'extract']],
|
||||||
'bitbuckettag' => [['repo'], ['path', 'extract']],
|
'bitbuckettag' => [['repo'], ['path', 'extract']],
|
||||||
'local' => [['dirname'], ['path', 'extract']],
|
'local' => [['dirname'], ['path', 'extract']],
|
||||||
'pecl' => [[], ['pecl', 'path', 'prefer-stable']],
|
|
||||||
'pie' => [['repo'], ['path']],
|
'pie' => [['repo'], ['path']],
|
||||||
'custom' => [[], ['func']],
|
'custom' => [[], ['func']],
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -31,6 +31,6 @@ if (file_exists('/etc/ssl/openssl.cnf')) {
|
|||||||
}
|
}
|
||||||
assert($valid);
|
assert($valid);
|
||||||
}
|
}
|
||||||
if (PHP_VERSION_ID >= 80500 && defined('OPENSSL_VERSION_NUMBER') && OPENSSL_VERSION_NUMBER >= 0x30200000) {
|
if (PHP_VERSION_ID >= 80500 && (!PHP_ZTS || PHP_OS_FAMILY !== 'Windows') && defined('OPENSSL_VERSION_NUMBER') && OPENSSL_VERSION_NUMBER >= 0x30200000) {
|
||||||
assert(function_exists('openssl_password_hash'));
|
assert(function_exists('openssl_password_hash'));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,25 +13,25 @@ declare(strict_types=1);
|
|||||||
|
|
||||||
// test php version (8.1 ~ 8.4 available, multiple for matrix)
|
// test php version (8.1 ~ 8.4 available, multiple for matrix)
|
||||||
$test_php_version = [
|
$test_php_version = [
|
||||||
'8.1',
|
// '8.1',
|
||||||
// '8.2',
|
// '8.2',
|
||||||
// '8.3',
|
// '8.3',
|
||||||
'8.4',
|
// '8.4',
|
||||||
'8.5',
|
'8.5',
|
||||||
// 'git',
|
// 'git',
|
||||||
];
|
];
|
||||||
|
|
||||||
// test os (macos-15-intel, macos-15, ubuntu-latest, windows-latest are available)
|
// test os (macos-15-intel, macos-15, ubuntu-latest, windows-latest are available)
|
||||||
$test_os = [
|
$test_os = [
|
||||||
// 'macos-15-intel', // bin/spc for x86_64
|
'macos-15-intel', // bin/spc for x86_64
|
||||||
// 'macos-15', // bin/spc for arm64
|
'macos-15', // bin/spc for arm64
|
||||||
// 'ubuntu-latest', // bin/spc-alpine-docker for x86_64
|
// 'ubuntu-latest', // bin/spc-alpine-docker for x86_64
|
||||||
// 'ubuntu-22.04', // bin/spc-gnu-docker for x86_64
|
// 'ubuntu-22.04', // bin/spc-gnu-docker for x86_64
|
||||||
// 'ubuntu-24.04', // bin/spc for x86_64
|
// 'ubuntu-24.04', // bin/spc for x86_64
|
||||||
// 'ubuntu-22.04-arm', // bin/spc-gnu-docker for arm64
|
// 'ubuntu-22.04-arm', // bin/spc-gnu-docker for arm64
|
||||||
// 'ubuntu-24.04-arm', // bin/spc for arm64
|
// 'ubuntu-24.04-arm', // bin/spc for arm64
|
||||||
// 'windows-2022', // .\bin\spc.ps1
|
// 'windows-2022', // .\bin\spc.ps1
|
||||||
'windows-2025',
|
// 'windows-2025',
|
||||||
];
|
];
|
||||||
|
|
||||||
// whether enable thread safe
|
// whether enable thread safe
|
||||||
@@ -42,16 +42,16 @@ $no_strip = false;
|
|||||||
// compress with upx
|
// compress with upx
|
||||||
$upx = false;
|
$upx = false;
|
||||||
|
|
||||||
// whether to test frankenphp build, only available for macos and linux
|
// whether to test frankenphp build, only available for macOS and linux
|
||||||
$frankenphp = false;
|
$frankenphp = true;
|
||||||
|
|
||||||
// prefer downloading pre-built packages to speed up the build process
|
// prefer downloading pre-built packages to speed up the build process
|
||||||
$prefer_pre_built = false;
|
$prefer_pre_built = false;
|
||||||
|
|
||||||
// If you want to test your added extensions and libs, add below (comma separated, example `bcmath,openssl`).
|
// If you want to test your added extensions and libs, add below (comma separated, example `bcmath,openssl`).
|
||||||
$extensions = match (PHP_OS_FAMILY) {
|
$extensions = match (PHP_OS_FAMILY) {
|
||||||
'Linux', 'Darwin' => 'pgsql',
|
'Linux', 'Darwin' => 'sqlsrv,pdo_sqlsrv',
|
||||||
'Windows' => 'gd,zlib,mbstring,filter',
|
'Windows' => 'amqp,apcu,bcmath,bz2,calendar,ctype,curl,dba,dom,ds,exif,ffi,fileinfo,filter,ftp,gd,iconv,igbinary,libxml,mbregex,mbstring,mysqli,mysqlnd,opcache,openssl,pdo,pdo_mysql,pdo_sqlite,pdo_sqlsrv,phar,rar,redis,session,shmop,simdjson,simplexml,soap,sockets,sqlite3,sqlsrv,ssh2,sysvshm,tokenizer,xml,xmlreader,xmlwriter,yac,yaml,zip,zlib',
|
||||||
};
|
};
|
||||||
|
|
||||||
// If you want to test shared extensions, add them below (comma separated, example `bcmath,openssl`).
|
// If you want to test shared extensions, add them below (comma separated, example `bcmath,openssl`).
|
||||||
|
|||||||
Reference in New Issue
Block a user