mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-12 00:39:45 +00:00
64 lines
2.1 KiB
YAML
64 lines
2.1 KiB
YAML
dist: xenial
|
|
language: php
|
|
php:
|
|
- 7.3
|
|
- 7.4
|
|
|
|
before_script:
|
|
- phpenv config-rm xdebug.ini
|
|
- |
|
|
set -e
|
|
|
|
LEVELDB_VERSION="10f59b56bec1db3ffe42ff265afe22182073e0e2"
|
|
if [ ! -f "./leveldb-mcpe/built_version" ] || [ $(cat "./leveldb-mcpe/built_version") != "$LEVELDB_VERSION" ]; then
|
|
echo "Building new LevelDB"
|
|
rm -rf "./leveldb-mcpe" || true
|
|
mkdir "./leveldb-mcpe"
|
|
|
|
curl -fsSL "https://github.com/pmmp/leveldb-mcpe/archive/$LEVELDB_VERSION.tar.gz" | tar -zx
|
|
mv "./leveldb-mcpe-$LEVELDB_VERSION" leveldb-mcpe-build
|
|
cd leveldb-mcpe-build
|
|
make -j4 sharedlibs
|
|
|
|
#put the artifacts in a separate dir, to avoid bloating travis cache"
|
|
mv out-shared/libleveldb.* ../leveldb-mcpe
|
|
mv include ../leveldb-mcpe
|
|
cd ../leveldb-mcpe
|
|
echo "$LEVELDB_VERSION" > "./built_version"
|
|
cd ..
|
|
else
|
|
echo "Using cached build for LevelDB version $LEVELDB_VERSION"
|
|
fi
|
|
|
|
- git clone https://github.com/reeze/php-leveldb.git leveldb
|
|
- cd leveldb
|
|
- git checkout 9bcae79f71b81a5c3ea6f67e45ae9ae9fb2775a5
|
|
- phpize
|
|
- ./configure --with-leveldb=../leveldb-mcpe && make && make install
|
|
- cd ..
|
|
- git clone https://github.com/pmmp/ext-chunkutils2.git chunkutils
|
|
- cd chunkutils
|
|
- git checkout d8d762a597ac0da6f333f862096d6af0e6286b75
|
|
- phpize
|
|
- ./configure && make && make install
|
|
- cd ..
|
|
# - pecl install channel://pecl.php.net/pthreads-3.1.6
|
|
- echo | pecl install channel://pecl.php.net/yaml-2.1.0
|
|
- pecl install channel://pecl.php.net/crypto-0.3.1
|
|
- pecl install channel://pecl.php.net/ds-1.2.9
|
|
- pecl install channel://pecl.php.net/igbinary-3.1.2
|
|
- git clone https://github.com/pmmp/pthreads.git
|
|
- cd pthreads
|
|
- git checkout e0f514dfde01c5e7e9cf94c43615918af482a45c
|
|
- phpize
|
|
- ./configure
|
|
- make
|
|
- make install
|
|
- cd ..
|
|
- echo "extension=pthreads.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
|
|
- echo "extension=chunkutils2.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
|
|
- echo "extension=leveldb.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
|
|
|
|
cache:
|
|
- leveldb-mcpe
|