Build file system the right way, using 'make install' and the minetest_game repo
This commit is contained in:
parent
1c5c6db362
commit
c9ad7ed687
1
.gitignore
vendored
1
.gitignore
vendored
@ -11,3 +11,4 @@ sources/zstd
|
|||||||
sources/webshims
|
sources/webshims
|
||||||
sources/minetest
|
sources/minetest
|
||||||
sources/irrlichtmt
|
sources/irrlichtmt
|
||||||
|
sources/minetest_game
|
||||||
|
@ -26,8 +26,10 @@ emcc --clear-cache --clear-ports
|
|||||||
./build_curl.sh # uses webshims, openssl, zlib
|
./build_curl.sh # uses webshims, openssl, zlib
|
||||||
|
|
||||||
# Minetest
|
# Minetest
|
||||||
./build_fsroot.sh
|
|
||||||
./build_minetest.sh
|
./build_minetest.sh
|
||||||
|
|
||||||
|
# Virtual file system
|
||||||
|
./build_fsroot.sh
|
||||||
|
|
||||||
# Finished product
|
# Finished product
|
||||||
./build_www.sh
|
./build_www.sh
|
||||||
|
@ -8,43 +8,42 @@
|
|||||||
|
|
||||||
source common.sh
|
source common.sh
|
||||||
|
|
||||||
# TODO: Use `make package` for this instead.
|
|
||||||
MTDIR="minetest-5.5.1-win64"
|
|
||||||
unpack_source $MTDIR
|
|
||||||
|
|
||||||
pushd "$BUILD_DIR"
|
pushd "$BUILD_DIR"
|
||||||
|
|
||||||
rm -rf fsroot
|
rm -rf fsroot
|
||||||
mkdir fsroot
|
mkdir fsroot
|
||||||
|
cp -a "minetest-install" fsroot/minetest
|
||||||
|
|
||||||
# Copy root certificates for OpenSSL
|
|
||||||
mkdir -p fsroot/etc/ssl/certs
|
|
||||||
# ca-certificates.crt may be a symlink
|
|
||||||
cat /etc/ssl/certs/ca-certificates.crt > fsroot/etc/ssl/certs/ca-certificates.crt
|
|
||||||
|
|
||||||
mv $MTDIR fsroot/minetest
|
|
||||||
|
|
||||||
|
#############################################
|
||||||
pushd fsroot/minetest
|
pushd fsroot/minetest
|
||||||
|
|
||||||
# Don't need the Windows exe/dlls
|
rm -rf bin unix
|
||||||
rm -rf bin
|
|
||||||
|
|
||||||
# Emscripten strips empty directories. But bin/ needs to be present so that
|
# Emscripten strips empty directories. But bin/ needs to be present so that
|
||||||
# realpath() works on relative paths starting with bin/../
|
# realpath() works on relative paths starting with bin/../
|
||||||
mkdir bin
|
mkdir bin
|
||||||
echo "This is here to ensure bin exists" > bin/readme.txt
|
echo "This is here to ensure bin exists" > bin/readme.txt
|
||||||
|
|
||||||
# Replace these directories with the ones from the source directory
|
|
||||||
for I in client builtin clientmods games/devtest textures; do
|
|
||||||
rm -rf "$I"
|
|
||||||
cp -r "$MINETEST_REPO/$I" "$I"
|
|
||||||
done
|
|
||||||
|
|
||||||
# Copy the irrlicht shaders
|
# Copy the irrlicht shaders
|
||||||
cp -r "$IRRLICHT_REPO/media/Shaders" client/shaders/Irrlicht
|
cp -r "$IRRLICHT_REPO/media/Shaders" client/shaders/Irrlicht
|
||||||
|
|
||||||
|
rm -rf games/minetest_game
|
||||||
|
cp -a "$SOURCES_DIR"/minetest_game games
|
||||||
|
cd games/minetest_game
|
||||||
|
rm -rf ".git" ".github"
|
||||||
|
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
|
||||||
|
#############################################
|
||||||
|
# Copy root certificates for OpenSSL
|
||||||
|
pushd fsroot
|
||||||
|
mkdir -p etc/ssl/certs
|
||||||
|
# May be a symlink, use cat to copy contents
|
||||||
|
cat /etc/ssl/certs/ca-certificates.crt > etc/ssl/certs/ca-certificates.crt
|
||||||
|
popd
|
||||||
|
|
||||||
|
|
||||||
# Make fsroot.tar
|
# Make fsroot.tar
|
||||||
rm -f fsroot.tar
|
rm -f fsroot.tar
|
||||||
pushd fsroot
|
pushd fsroot
|
||||||
|
@ -57,8 +57,10 @@ if ! $INCREMENTAL; then
|
|||||||
-DEGL_INCLUDE_DIR="$DUMMY_INCLUDE_DIR" \
|
-DEGL_INCLUDE_DIR="$DUMMY_INCLUDE_DIR" \
|
||||||
-DCURL_LIBRARY="$INSTALL_DIR/lib/libcurl.a" \
|
-DCURL_LIBRARY="$INSTALL_DIR/lib/libcurl.a" \
|
||||||
-DCURL_INCLUDE_DIR="$INSTALL_DIR/include" \
|
-DCURL_INCLUDE_DIR="$INSTALL_DIR/include" \
|
||||||
|
-DCMAKE_INSTALL_PREFIX="$BUILD_DIR/minetest-install" \
|
||||||
-G "Unix Makefiles" \
|
-G "Unix Makefiles" \
|
||||||
"$SOURCES_DIR/minetest"
|
"$SOURCES_DIR/minetest"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
emmake make
|
rm -rf "$BUILD_DIR/minetest-install"
|
||||||
|
emmake make install
|
||||||
|
@ -16,7 +16,6 @@ getsource "https://downloads.xiph.org/releases/vorbis/libvorbis-1.3.7.tar.gz" 0e
|
|||||||
getsource "https://www.sqlite.org/src/tarball/698edb77/SQLite-698edb77.tar.gz" b1568dc5d17788b9dd9575ecd224b3f7985b51764bc2f34f4808d851332840ef
|
getsource "https://www.sqlite.org/src/tarball/698edb77/SQLite-698edb77.tar.gz" b1568dc5d17788b9dd9575ecd224b3f7985b51764bc2f34f4808d851332840ef
|
||||||
getsource "https://www.openssl.org/source/openssl-1.1.1n.tar.gz" 40dceb51a4f6a5275bde0e6bf20ef4b91bfc32ed57c0552e2e8e15463372b17a
|
getsource "https://www.openssl.org/source/openssl-1.1.1n.tar.gz" 40dceb51a4f6a5275bde0e6bf20ef4b91bfc32ed57c0552e2e8e15463372b17a
|
||||||
getsource "https://curl.se/download/curl-7.82.0.tar.bz2" 46d9a0400a33408fd992770b04a44a7434b3036f2e8089ac28b57573d59d371f
|
getsource "https://curl.se/download/curl-7.82.0.tar.bz2" 46d9a0400a33408fd992770b04a44a7434b3036f2e8089ac28b57573d59d371f
|
||||||
getsource "https://github.com/minetest/minetest/releases/download/5.5.1/minetest-5.5.1-win64.zip" 9be48fb4126312b0d8fd048d1ab06d59b3109f6fe037fcd5ab65b99507e68a5f
|
|
||||||
getsource "https://www.libarchive.org/downloads/libarchive-3.6.1.tar.xz" 5a411aceb978f43e626f0c2d1812ddd8807b645ed892453acabd532376c148e6
|
getsource "https://www.libarchive.org/downloads/libarchive-3.6.1.tar.xz" 5a411aceb978f43e626f0c2d1812ddd8807b645ed892453acabd532376c148e6
|
||||||
|
|
||||||
# These are never checked into the repo, since they are separate git repos.
|
# These are never checked into the repo, since they are separate git repos.
|
||||||
@ -27,6 +26,9 @@ getrepo libpng "https://git.code.sf.net/p/libpng/code" a37d4836519517bdce6cb9d95
|
|||||||
getrepo freetype "https://gitlab.freedesktop.org/freetype/freetype.git" a8e4563c3418ed74d39019a6c5e2122d12c8f56f
|
getrepo freetype "https://gitlab.freedesktop.org/freetype/freetype.git" a8e4563c3418ed74d39019a6c5e2122d12c8f56f
|
||||||
getrepo zstd "https://github.com/facebook/zstd.git" e47e674cd09583ff0503f0f6defd6d23d8b718d3
|
getrepo zstd "https://github.com/facebook/zstd.git" e47e674cd09583ff0503f0f6defd6d23d8b718d3
|
||||||
|
|
||||||
|
# Minetest Game
|
||||||
|
getrepo minetest_game "https://github.com/minetest/minetest_game.git" 99a719309559b632af65756f380496aa269d4b4a
|
||||||
|
|
||||||
# These repos are part of the fork
|
# These repos are part of the fork
|
||||||
getrepo webshims "https://github.com/paradust7/webshims.git" 91c3fe85d2cb7f85cc8e19d3f53dc8f252a69ff7
|
getrepo webshims "https://github.com/paradust7/webshims.git" 91c3fe85d2cb7f85cc8e19d3f53dc8f252a69ff7
|
||||||
getrepo minetest "https://github.com/paradust7/minetest.git" 4f32398cdf2b245bd8661f1ff8b0efc74c148cc9
|
getrepo minetest "https://github.com/paradust7/minetest.git" 4f32398cdf2b245bd8661f1ff8b0efc74c148cc9
|
||||||
|
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user