Initial Commit

This commit is contained in:
TheBrokenRail 2020-12-21 10:58:10 -05:00
commit a4376f1442
8 changed files with 122 additions and 0 deletions

.gitignore vendored Normal file
View File

@ -0,0 +1 @@

DEBIAN/control Normal file
View File

@ -0,0 +1,7 @@
Package: minetest
Version: ${VERSION}
Maintainer: TheBrokenRail <>
Description: A free open-source voxel game engine with easy modding and game creation.
Architecture: arm64
Depends: libc6, libstdc++6, libxxf86vm1, libgles1, libegl1, libsqlite3-0, libogg0, libvorbis0a, libopenal1, libcurl3-gnutls, libfreetype6, zlib1g, libgmp10, libjsoncpp1

Dockerfile Normal file
View File

@ -0,0 +1,15 @@
FROM debian:bullseye
ENV DEBIAN_FRONTEND noninteractive
RUN mkdir /app
ADD ./ /app/
RUN ./
ADD ./ /app/
RUN ./
ADD ./ /app/

2 Normal file
View File

@ -0,0 +1,2 @@
# Minetest For The PinePhone
This is a repository containing scripts to build a version of Minetest for the PinePhone. Just run ``./`` in a Terminal on a system with Docker installed, and a DEB will be produced in the ``out`` directory. This requires a x86_64 processor to run.

29 Executable file
View File

@ -0,0 +1,29 @@
set -e
git clone --depth 1 -b ogl-es
cd irrlicht
dos2unix source/Irrlicht/CIrrDeviceLinux.cpp
dos2unix source/Irrlicht/Makefile
dos2unix include/IrrCompileConfig.h
curl -L | patch -p1
disable_feature() {
sed -i "s/^#define $1.*$//g" include/IrrCompileConfig.h
enable_feature() {
sed -i "s/^\/\/#define $1.*$/#define $1/g" include/IrrCompileConfig.h
disable_feature _IRR_COMPILE_WITH_OPENGL_
disable_feature _IRR_COMPILE_WITH_OGLES2_
disable_feature _IRR_COMPILE_WITH_WEBGL1_
enable_feature _IRR_COMPILE_WITH_OGLES1_
enable_feature _IRR_LINUX_X11_XINPUT2_
cd source/Irrlicht
make NDEBUG=1 CC=aarch64-linux-gnu-gcc CXX=aarch64-linux-gnu-g++ -j$(nproc)

49 Executable file
View File

@ -0,0 +1,49 @@
set -e
git clone -b desktop-touch
cd minetest
DEB_VERSION="$(git describe --tags --dirty)"
git clone --depth 1 games/minetest_game
mkdir build-dir
cd build-dir
# Prepare Build
cmake \
-DCMAKE_C_COMPILER=aarch64-linux-gnu-gcc \
-DCMAKE_CXX_COMPILER=aarch64-linux-gnu-g++ \
-DIRRLICHT_LIBRARY=../../irrlicht/lib/Linux/libIrrlicht.a \
-DIRRLICHT_INCLUDE_DIR=../../irrlicht/include \
# Build
make -j$(nproc)
# Clean Up
rm -rf tmp
mkdir tmp
rm -rf /out/*
# Install Files
make install DESTDIR="$(pwd)/tmp"
# Prepare Debian
cp -r ../../DEBIAN tmp/DEBIAN
sed -i 's/${VERSION}/'"${DEB_VERSION}"'/g' tmp/DEBIAN/control
# Make DEB
dpkg -b tmp /out
# Clean Up
rm -rf tmp

8 Executable file
View File

@ -0,0 +1,8 @@
set -e
dpkg --add-architecture arm64
apt-get update
apt-get dist-upgrade -y
apt-get install -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu make libc6-dev:arm64 cmake libbz2-dev:arm64 libpng-dev:arm64 libjpeg-dev:arm64 libxxf86vm-dev:arm64 libglvnd-dev:arm64 libsqlite3-dev:arm64 libogg-dev:arm64 libvorbis-dev:arm64 libopenal-dev:arm64 libcurl4-gnutls-dev:arm64 libfreetype6-dev:arm64 zlib1g-dev:arm64 libgmp-dev:arm64 libjsoncpp-dev:arm64 git libxi-dev:arm64 dos2unix dpkg-dev

11 Executable file
View File

@ -0,0 +1,11 @@
set -e
# Build Dependencies
docker build --tag minetest-dev .
# Extract
rm -rf out
mkdir out
docker run --rm -v "$(pwd)/out:/out" minetest-dev ./