This repository has been archived by the owner on Mar 20, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
32 changed files
with
877 additions
and
1,432 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Build all | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: docker-practice/actions-setup-docker@master | ||
- name: Setup Docker Multiarch | ||
run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes | ||
- name: Build ARM | ||
run: | | ||
docker pull arm32v7/buildpack-deps:buster | ||
docker run -v $PWD:$PWD -w $PWD --rm arm32v7/buildpack-deps:buster bash ./ci.sh | ||
- name: Build AArch64 | ||
run: | | ||
docker pull arm64v8/buildpack-deps:buster | ||
docker run -v $PWD:$PWD -w $PWD --rm arm64v8/buildpack-deps:buster bash ./ci.sh | ||
- name: Build x86_64 | ||
run: | | ||
docker pull amd64/buildpack-deps:buster | ||
docker run -v $PWD:$PWD -w $PWD --rm amd64/buildpack-deps:buster bash ./ci.sh | ||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: gmcpil_debs | ||
path: gmcpil_*.deb |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
# Builds | ||
build/ | ||
*.c | ||
*.o | ||
|
||
# Debian | ||
*.deb | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,104 +1,61 @@ | ||
# | ||
# Makefile | ||
# | ||
# Copyright 2021 Alvarito050506 <[email protected]> | ||
# | ||
# This program is free software; you can redistribute it and/or modify | ||
# it under the terms of the GNU General Public License as published by | ||
# the Free Software Foundation; either version 2 of the License, or | ||
# (at your option) any later version. | ||
# | ||
# This program is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU General Public License | ||
# along with this program; if not, write to the Free Software | ||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
# MA 02110-1301, USA. | ||
# | ||
# | ||
VERSION:=0.13.0 | ||
SRCS:=$(patsubst %,./src/%.vala,profile config gui play features servers) | ||
SRCS+=./src/gmcpil.vapi | ||
|
||
ifdef USE_CLANG | ||
ifeq ($(origin CC),default) | ||
CC:=clang | ||
endif | ||
STRIP?=llvm-strip | ||
LDFLAGS:=-fuse-ld=lld | ||
ARCH:=$(shell $(CC) -dumpmachine | grep -Eo "arm|aarch|86|x86_64") | ||
else | ||
ifeq ($(origin CC),default) | ||
CC:=gcc | ||
endif | ||
STRIP?=strip | ||
LDFLAGS:= | ||
ARCH:=$(shell $(CC) -print-multiarch | grep -Eo "arm|aarch|86|x86_64") | ||
PKG_CONFIG?=pkg-config | ||
ifdef CROSS_COMPILE | ||
CC:=$(CROSS_COMPILE)-gcc | ||
PKG_CONFIG:=$(CROSS_COMPILE)-pkg-config | ||
STRIP:=$(CROSS_COMPILE)-strip | ||
endif | ||
|
||
VERSION:=0.12.0 | ||
|
||
OBJS:=$(patsubst %,build/%.o,mcpil config features play servers) | ||
VFLAGS:=--pkg json-glib-1.0 --pkg gio-2.0 --pkg gtk+-3.0 | ||
VFLAGS+=--cc=$(CC) --pkg-config=$(PKG_CONFIG) -X -DGMCPIL_VERSION="\"v$(VERSION)\"" | ||
|
||
CFLAGS+=-DGMCPIL_VERSION=\"v$(VERSION)\" -I./src/include -Wall -Wno-address-of-packed-member -Wno-pointer-to-int-cast -Wno-unused-result | ||
CFLAGS+=$(shell pkg-config --cflags gtk+-3.0 json-glib-1.0) | ||
LDFLAGS+=-Wl,--no-undefined $(shell pkg-config --libs gtk+-3.0 json-glib-1.0) | ||
ARCH:=$(shell $(CC) -dumpmachine | grep -Eo "arm|aarch|86|x86_64") | ||
ifeq ($(ARCH),86) | ||
DEB_ARCH:=i386 | ||
else ifeq ($(ARCH),x86_64) | ||
DEB_ARCH:=amd64 | ||
else ifeq ($(ARCH),aarch) | ||
DEB_ARCH:=arm64 | ||
else | ||
DEB_ARCH:=armhf | ||
endif | ||
|
||
ifdef DEBUG | ||
CFLAGS+=-g -Wextra -Werror | ||
VFLAGS+=-X -g --save-temps --fatal-warnings | ||
else | ||
CFLAGS+=-O3 | ||
VFLAGS+=-X -O3 | ||
endif | ||
|
||
# Some GTK+/GDK-Pixbuf combinations may generate this warning | ||
# for internal functions, so let's "ignore" it. | ||
CFLAGS+=-Wno-error=deprecated-declarations | ||
|
||
.PHONY: ./build/gmcpil | ||
ifndef NO_BUSTER_COMPAT | ||
VFLAGS+=-D BUSTER_COMPAT | ||
endif | ||
|
||
./build/gmcpil: mkdir $(OBJS) | ||
$(CC) -fPIC -fpie $(OBJS) -o $@ $(CFLAGS) $(LDFLAGS) | ||
./build/gmcpil: ./build/ $(SRCS) | ||
valac $(VFLAGS) $(SRCS) -o ./build/gmcpil | ||
ifndef DEBUG | ||
$(STRIP) ./build/gmcpil | ||
endif | ||
|
||
./build/%.o: ./src/%.c ./src/include/*.h | ||
$(CC) -fPIC -fpie -c $< -o $@ $(CFLAGS) | ||
|
||
mkdir: | ||
./build/: | ||
mkdir -p ./build/ | ||
|
||
pack: ./build/gmcpil | ||
mkdir -p ./deb/DEBIAN/ | ||
mkdir -p ./deb/usr/bin/ | ||
mkdir -p ./deb/usr/share/ | ||
cp ./build/gmcpil ./deb/usr/bin/ | ||
cp -r ./res/. ./deb/usr/share/ | ||
cp -r ./res/usr/share/ ./deb/usr/ | ||
chmod a+x ./deb/usr/bin/gmcpil | ||
@echo "Package: gmcpil" > ./deb/DEBIAN/control | ||
@echo "Version: $(VERSION)" >> ./deb/DEBIAN/control | ||
@echo "Priority: optional" >> ./deb/DEBIAN/control | ||
ifeq ($(ARCH),86) | ||
@echo "Architecture: i386" >> ./deb/DEBIAN/control | ||
else ifeq ($(ARCH),x86_64) | ||
@echo "Architecture: amd64" >> ./deb/DEBIAN/control | ||
else ifeq ($(ARCH),aarch) | ||
@echo "Architecture: arm64" >> ./deb/DEBIAN/control | ||
else | ||
@echo "Architecture: armhf" >> ./deb/DEBIAN/control | ||
endif | ||
@echo "Section: contrib/misc" >> ./deb/DEBIAN/control | ||
@echo "Depends: libc6 (>= 2.28), minecraft-pi-reborn-client (>= 2.1.0), libgtk-3-0, libjson-glib-1.0-0" >> ./deb/DEBIAN/control | ||
@echo "Maintainer: Alvarito050506 <[email protected]>" >> ./deb/DEBIAN/control | ||
@echo "Homepage: https://mcpirevival.tk" >> ./deb/DEBIAN/control | ||
@echo "Vcs-Browser: https://github.com/MCPI-Revival/gMCPIL" >> ./deb/DEBIAN/control | ||
@echo "Vcs-Git: https://github.com/MCPI-Revival/gMCPIL.git" >> ./deb/DEBIAN/control | ||
@echo "Description: Simple launcher for Minecraft: Pi Edition - GTK+ Edition." >> ./deb/DEBIAN/control | ||
@echo " Simple GUI launcher for Minecraft: Pi Edition and MCPI-Reborn," >> ./deb/DEBIAN/control | ||
@echo " rewritten in C using GTK+ 3." >> ./deb/DEBIAN/control | ||
fakeroot dpkg-deb -b ./deb/ ./gmcpil_$(VERSION).deb | ||
sed "s/{{ARCH}}/$(DEB_ARCH)/g; s/{{VERSION}}/$(VERSION)/g" ./res/control > ./deb/DEBIAN/control | ||
fakeroot dpkg-deb -b ./deb/ ./gmcpil_$(VERSION)_$(DEB_ARCH).deb | ||
|
||
clean: | ||
rm -rf ./deb/ | ||
rm -rf ./src/*.c | ||
rm -rf ./build/ | ||
|
||
purge: clean | ||
rm -f ./gmcpil_*.deb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
export DEBIAN_FRONTEND="noninteractive" | ||
|
||
echo "deb [trusted=yes] https://deb.debian.org/debian buster-backports main contrib non-free" >> /etc/apt/sources.list | ||
|
||
apt update | ||
apt upgrade -y | ||
apt install -y git make fakeroot dpkg-dev build-essential libgtk-3-dev libjson-glib-dev | ||
apt install -y -t buster-backports valac | ||
apt --fix-broken install | ||
|
||
make pack | ||
make clean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Package: gmcpil | ||
Version: {{VERSION}} | ||
Priority: optional | ||
Architecture: {{ARCH}} | ||
Section: contrib/misc | ||
Depends: libc6 (>= 2.28), minecraft-pi-reborn-client (>= 2.1.0), libgtk-3-0, libjson-glib-1.0-0 | ||
Maintainer: Alvarito050506 <[email protected]> | ||
Homepage: https://mcpirevival.tk | ||
Vcs-Browser: https://github.com/MCPI-Revival/gMCPIL | ||
Vcs-Git: https://github.com/MCPI-Revival/gMCPIL.git | ||
Description: Simple launcher for Minecraft: Pi Edition - GTK+ Edition. | ||
Simple GUI launcher for Minecraft: Pi Edition and MCPI-Reborn, | ||
rewritten in Vala using GTK+ 3. |
File renamed without changes.
5 changes: 5 additions & 0 deletions
5
res/doc/gmcpil/CHANGELOG.txt → res/usr/share/doc/gmcpil/CHANGELOG.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.