File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,13 @@ declare -A PHP_EXTS_CMD=(
37
37
[" ssh2" ]=" git clone https://github.com/php/pecl-networking-ssh2.git ssh2"
38
38
[" swoole" ]=" git clone https://github.com/swoole/swoole-src.git swoole"
39
39
[" swoole-async-ext" ]=" git clone https://github.com/swoole/async-ext.git swoole-async-ext"
40
- [" xxhash" ]=" git clone https://github.com/Megasaxon/php-xxhash.git --single-branch --branch develop xxhash"
40
+ [" xxhash" ]=" git clone https://github.com/Megasaxon/php-xxhash.git xxhash"
41
+ )
42
+
43
+ # checkout repo to a specific commit before compilation
44
+ declare -A PHP_EXTS_CHECKOUT=(
45
+ [" swoole" ]=" v4.3.1"
46
+ [" xxhash" ]=" origin/develop"
41
47
)
42
48
43
49
declare -A PHP_EXTS_CONFIG=(
@@ -129,6 +135,12 @@ for PHP_EXT_NAME in "${!PHP_EXTS_CMD[@]}"; do
129
135
git submodule update --init
130
136
git submodule foreach --recursive git pull
131
137
138
+ # checkout a specific commit
139
+ commit=${PHP_EXTS_CHECKOUT[${PHP_EXT_NAME}]}
140
+ if [ " ${commit} " != " " ]; then
141
+ git checkout -f " ${commit} "
142
+ fi
143
+
132
144
for PHP_BASE_DIR in " ${PHP_BASE_DIRS[@]} " ; do
133
145
# paths
134
146
phpize=" ${PHP_BASE_DIR} /bin/phpize"
You can’t perform that action at this time.
0 commit comments