Skip to content

Commit bc8d04b

Browse files
committed
Stop building PM4 binaries
PM4 was on 8.1 when support ended, so this shouldn't break anything.
1 parent fe8618c commit bc8d04b

File tree

3 files changed

+13
-20
lines changed

3 files changed

+13
-20
lines changed

.github/workflows/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
name: PM${{ matrix.pm-version-major }}
1717
strategy:
1818
matrix:
19-
pm-version-major: [4, 5]
19+
pm-version-major: [5]
2020

2121
uses: ./.github/workflows/main-pm-matrix.yml
2222
with:

compile.sh

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ LIBZIP_VERSION="1.10.1"
1414
SQLITE3_VERSION="3440200" #3.44.2
1515
LIBDEFLATE_VERSION="dd12ff2b36d603dbb7fa8838fe7e7176fcbd4f6f" #1.19
1616

17-
EXT_PTHREADS_VERSION="4.2.2"
1817
EXT_PMMPTHREAD_VERSION="6.0.12"
1918
EXT_YAML_VERSION="2.2.3"
2019
EXT_LEVELDB_VERSION="317fdcd8415e1566fc2835ce2bdb8e19b890f9f3"
@@ -238,6 +237,9 @@ done
238237
if [ "$PM_VERSION_MAJOR" == "" ]; then
239238
write_error "Please specify PocketMine-MP major version target with -P (e.g. -P5)"
240239
exit 1
240+
elif [ "$PM_VERSION_MAJOR" -lt 5 ]; then
241+
write_error "PocketMine-MP 4.x and older are no longer supported"
242+
exit 1
241243
fi
242244

243245
write_out "opt" "Compiling with configuration for PocketMine-MP $PM_VERSION_MAJOR"
@@ -1034,13 +1036,8 @@ function get_pecl_extension {
10341036
cd "$BUILD_DIR/php"
10351037
write_out "PHP" "Downloading additional extensions..."
10361038

1037-
if [ "$PM_VERSION_MAJOR" -ge 5 ]; then
1038-
get_github_extension "pmmpthread" "$EXT_PMMPTHREAD_VERSION" "pmmp" "ext-pmmpthread"
1039-
THREAD_EXT_FLAGS="--enable-pmmpthread"
1040-
else
1041-
get_github_extension "pthreads" "$EXT_PTHREADS_VERSION" "pmmp" "ext-pmmpthread" #"v" needed for release tags because github removes the "v"
1042-
THREAD_EXT_FLAGS="--enable-pthreads"
1043-
fi
1039+
get_github_extension "pmmpthread" "$EXT_PMMPTHREAD_VERSION" "pmmp" "ext-pmmpthread"
1040+
10441041

10451042
get_github_extension "yaml" "$EXT_YAML_VERSION" "php" "pecl-file_formats-yaml"
10461043
#get_pecl_extension "yaml" "$EXT_YAML_VERSION"
@@ -1160,7 +1157,7 @@ $HAS_DEBUG \
11601157
--enable-mbstring \
11611158
--disable-mbregex \
11621159
--enable-calendar \
1163-
$THREAD_EXT_FLAGS \
1160+
--enable-pmmpthread \
11641161
--enable-fileinfo \
11651162
--with-libxml \
11661163
--enable-xml \

windows-compile-vs.bat

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ set PTHREAD_W32_VER=3.0.0
2323
set LEVELDB_MCPE_VER=1c7564468b41610da4f498430e795ca4de0931ff
2424
set LIBDEFLATE_VER=dd12ff2b36d603dbb7fa8838fe7e7176fcbd4f6f
2525

26-
set PHP_PTHREADS_VER=4.2.2
2726
set PHP_PMMPTHREAD_VER=6.0.12
2827
set PHP_YAML_VER=2.2.3
2928
set PHP_CHUNKUTILS2_VER=0.3.5
@@ -76,6 +75,10 @@ if "%PM_VERSION_MAJOR%"=="" (
7675
call :pm-echo-error "Please specify PocketMine-MP major version by setting the PM_VERSION_MAJOR environment variable"
7776
exit 1
7877
)
78+
if "%PM_VERSION_MAJOR%" lss "5" (
79+
call :pm-echo-error "PocketMine-MP 4.x and older are no longer supported"
80+
exit 1
81+
)
7982

8083
call :pm-echo "Compiling with configuration for PocketMine-MP %PM_VERSION_MAJOR%"
8184

@@ -219,14 +222,7 @@ cd /D ..
219222
call :pm-echo "Getting additional PHP extensions..."
220223
cd /D php-src\ext
221224

222-
set THREAD_EXT_FLAGS=""
223-
if "%PM_VERSION_MAJOR%" geq "5" (
224-
call :get-extension-zip-from-github "pmmpthread" "%PHP_PMMPTHREAD_VER%" "pmmp" "ext-pmmpthread" || exit 1
225-
set THREAD_EXT_FLAGS="--with-pmmpthread=shared"
226-
) else (
227-
call :get-extension-zip-from-github "pthreads" "%PHP_PTHREADS_VER%" "pmmp" "ext-pmmpthread" || exit 1
228-
set THREAD_EXT_FLAGS="--with-pthreads=shared"
229-
)
225+
call :get-extension-zip-from-github "pmmpthread" "%PHP_PMMPTHREAD_VER%" "pmmp" "ext-pmmpthread" || exit 1
230226
call :get-extension-zip-from-github "yaml" "%PHP_YAML_VER%" "php" "pecl-file_formats-yaml" || exit 1
231227
call :get-extension-zip-from-github "chunkutils2" "%PHP_CHUNKUTILS2_VER%" "pmmp" "ext-chunkutils2" || exit 1
232228
call :get-extension-zip-from-github "igbinary" "%PHP_IGBINARY_VER%" "igbinary" "igbinary" || exit 1
@@ -304,7 +300,7 @@ call configure^
304300
--with-mysqlnd^
305301
--with-openssl^
306302
--with-pcre-jit^
307-
%THREAD_EXT_FLAGS%^
303+
--with-pmmpthread=shared^
308304
--with-simplexml^
309305
--with-sodium^
310306
--with-sqlite3=shared^

0 commit comments

Comments
 (0)