Add i686 support and dockerfile
This commit is contained in:
parent
70b8ce85a5
commit
d646163384
5 changed files with 43 additions and 17 deletions
|
@ -1,16 +1,17 @@
|
|||
#!/bin/bash
|
||||
|
||||
CURRENT_APPIMAGEKIT_RELEASE=9
|
||||
|
||||
set -eo >/dev/null
|
||||
|
||||
CURRENT_APPIMAGEKIT_RELEASE=9
|
||||
ARCH="$(uname -m)"
|
||||
|
||||
if [[ $# -lt 1 ]]; then
|
||||
echo "Usage: $0 <version>"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
VERSION="$1"
|
||||
if ! test -f ../tarball/love-${VERSION}-amd64.tar.gz; then
|
||||
if ! test -f ../tarball/love-${VERSION}-${ARCH}.tar.gz; then
|
||||
echo "No tarball found for $VERSION"
|
||||
exit 1
|
||||
fi
|
||||
|
@ -26,19 +27,19 @@ download_if_needed() {
|
|||
fi
|
||||
}
|
||||
|
||||
download_if_needed appimagetool-x86_64.AppImage
|
||||
download_if_needed AppRun-x86_64
|
||||
download_if_needed appimagetool-${ARCH}.AppImage
|
||||
download_if_needed AppRun-${ARCH}
|
||||
|
||||
# Extract the tarball build into a folder
|
||||
rm -rf love-prepared
|
||||
mkdir love-prepared
|
||||
tar xf ../tarball/love-${VERSION}-amd64.tar.gz -C love-prepared --strip-components=1
|
||||
tar xf ../tarball/love-${VERSION}-${ARCH}.tar.gz -C love-prepared --strip-components=1
|
||||
|
||||
cd love-prepared
|
||||
|
||||
# Add our small wrapper script (yay, more wrappers), and AppRun
|
||||
cp ../wrapper usr/bin/wrapper-love
|
||||
cp ../AppRun-x86_64 AppRun
|
||||
cp ../AppRun-${ARCH} AppRun
|
||||
|
||||
# Add our desktop file
|
||||
sed -e 's/%BINPREFIX%/wrapper-/' -e 's/%ICONPREFIX%//' love.desktop.in > love.desktop
|
||||
|
@ -51,5 +52,5 @@ cp love.svg .DirIcon
|
|||
cd ..
|
||||
|
||||
# Work around missing FUSE/docker
|
||||
./appimagetool-x86_64.AppImage --appimage-extract
|
||||
./squashfs-root/AppRun love-prepared love-${VERSION}-x86_64.AppImage
|
||||
./appimagetool-${ARCH}.AppImage --appimage-extract
|
||||
./squashfs-root/AppRun love-prepared love-${VERSION}-${ARCH}.AppImage
|
||||
|
|
22
docker/Dockerfile-32bit
Normal file
22
docker/Dockerfile-32bit
Normal file
|
@ -0,0 +1,22 @@
|
|||
FROM i386/debian:wheezy
|
||||
|
||||
# Install all sdl, love (build) deps and love-linux-builder deps
|
||||
RUN apt-get update && apt-get install -y build-essential libgl1-mesa-glx libgles2-mesa-dev libxrandr-dev libdbus-1-dev libxi-dev libxcursor-dev libxinerama-dev libgl1-mesa-dev libibus-1.0-dev libasound2-dev libpulse-dev libwayland-dev libfreetype6-dev libopenal-dev libmodplug-dev libvorbis-dev libtheora-dev libphysfs-dev libmpg123-dev squashfs-tools curl mercurial libfuse2 autotools-dev automake libtool pkg-config
|
||||
|
||||
# Now build sdl
|
||||
ADD SDL2-2.0.5.tar.gz /tmp/
|
||||
RUN cd /tmp/SDL2-2.0.5 && ./configure --prefix=/usr && make all install
|
||||
|
||||
# And build luajit
|
||||
ADD LuaJIT-2.0.5.tar.gz /tmp/
|
||||
RUN cd /tmp/LuaJIT-2.0.5 && make all install
|
||||
|
||||
# Add the build script
|
||||
ADD build.sh /build/
|
||||
|
||||
# Add the volumes, the first the love-linux-builder (mandatory), the second the love source (optional)
|
||||
RUN mkdir -p /build/love-linux-builder /build/love
|
||||
VOLUME /build/love-linux-builder /build/love
|
||||
|
||||
# Finally, set the build script as entrypoint
|
||||
ENTRYPOINT ["/usr/bin/setarch", "i686", "/build/build.sh"]
|
|
@ -6,8 +6,7 @@ if [ $# -lt 1 ]; then
|
|||
fi
|
||||
|
||||
VERSION="$1"
|
||||
#ARCH="$(uname -m)"
|
||||
ARCH="amd64"
|
||||
ARCH="$(uname -m)"
|
||||
|
||||
cd /build/love-linux-builder
|
||||
|
||||
|
|
|
@ -2,13 +2,15 @@
|
|||
|
||||
set -eo >/dev/null
|
||||
|
||||
ARCH="$(uname -m)"
|
||||
|
||||
if [[ $# -lt 1 ]]; then
|
||||
echo "Usage: $0 <version>"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
VERSION="$1"
|
||||
if ! test -f ../tarball/love-${VERSION}-amd64.tar.gz; then
|
||||
if ! test -f ../tarball/love-${VERSION}-${ARCH}.tar.gz; then
|
||||
echo "No tarball found for $VERSION"
|
||||
exit 1
|
||||
fi
|
||||
|
@ -21,7 +23,7 @@ fi
|
|||
# Extract the tarball build into a folder
|
||||
rm -rf files
|
||||
mkdir files
|
||||
tar xf ../tarball/love-${VERSION}-amd64.tar.gz -C files --strip-components=1
|
||||
tar xf ../tarball/love-${VERSION}-${ARCH}.tar.gz -C files --strip-components=1
|
||||
|
||||
cd files
|
||||
|
||||
|
@ -43,4 +45,4 @@ mkdir -p lib/GL
|
|||
cd ..
|
||||
#rm -rf repo
|
||||
flatpak build-export repo . ${VERSION}
|
||||
flatpak build-bundle repo love-${VERSION}-x86_64.flatpak org.love2d.love $VERSION
|
||||
flatpak build-bundle repo love-${VERSION}-${ARCH}.flatpak org.love2d.love $VERSION
|
||||
|
|
|
@ -2,13 +2,15 @@
|
|||
|
||||
set -eo >/dev/null
|
||||
|
||||
ARCH="$(uname -m)"
|
||||
|
||||
if [[ $# -lt 1 ]]; then
|
||||
echo "Usage: $0 <version>"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
VERSION="$1"
|
||||
if ! test -f ../tarball/love-${VERSION}-amd64.tar.gz; then
|
||||
if ! test -f ../tarball/love-${VERSION}-${ARCH}.tar.gz; then
|
||||
echo "No tarball found for $VERSION"
|
||||
exit 1
|
||||
fi
|
||||
|
@ -16,7 +18,7 @@ fi
|
|||
# Extract the tarball build into a folder
|
||||
rm -rf love-prepared
|
||||
mkdir love-prepared
|
||||
tar xf ../tarball/love-${VERSION}-amd64.tar.gz -C love-prepared --strip-components=1
|
||||
tar xf ../tarball/love-${VERSION}-${ARCH}.tar.gz -C love-prepared --strip-components=1
|
||||
|
||||
cd love-prepared
|
||||
|
||||
|
@ -32,4 +34,4 @@ sed -e "s/%VERSION%/$VERSION/" ../snap.yaml > meta/snap.yaml
|
|||
cp ../command-love.wrapper .
|
||||
|
||||
# Finally, build it!
|
||||
mksquashfs . ../love_${VERSION}_amd64.snap -noappend
|
||||
mksquashfs . ../love_${VERSION}_${ARCH}.snap -noappend
|
||||
|
|
Loading…
Reference in a new issue