QT5 - SSE3 Compilar y Empaquetar AppImage #14
This file contains hidden or 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
| name: Compilar y Empaquetar AppImage | |
| on: | |
| workflow_dispatch: | |
| jobs: | |
| build-and-package: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Trinity (Repositorio Principal) | |
| uses: actions/checkout@v4 | |
| with: | |
| path: 'trinity' | |
| - name: Clonar Dependencias Externas | |
| run: | | |
| # Clonar con submodulos recursivos usando git directamente | |
| git clone --recursive -b ng https://github.com/minecraft-linux/mcpelauncher-manifest.git mcpelauncher | |
| git clone --recursive https://github.com/minecraft-linux/msa-manifest.git msa | |
| git clone https://codeberg.org/javiercplus/mcpe-extract.git | |
| git clone https://github.com/minecraft-linux/mcpelauncher-linux-bin.git linux-bin | |
| - name: Instalar Dependencias del Sistema | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y --no-install-recommends \ | |
| ca-certificates build-essential git curl cmake clang ninja-build \ | |
| qt6-base-dev qt6-base-dev-tools qt6-declarative-dev qt6-svg-dev qt6-tools-dev \ | |
| qtbase5-dev qtdeclarative5-dev libqt5svg5-dev \ | |
| libcurl4-openssl-dev libssl-dev libasound2-dev libpulse-dev \ | |
| libx11-dev libxi-dev libxcursor-dev libxrandr-dev libgl1-mesa-dev \ | |
| libevdev-dev libusb-1.0-0-dev libdbus-1-dev libpng-dev libzip-dev \ | |
| libfuse2 wget file python3 | |
| - name: Compilar MSA (64 bits) | |
| run: | | |
| export CC=clang CXX=clang++ | |
| # Forzamos a que encuentre Qt5 y desactivamos errores de desarrollo de CMake | |
| cmake -S msa -B msa/build -G Ninja \ | |
| -DCMAKE_BUILD_TYPE=Release \ | |
| -DENABLE_MSA_QT_UI=ON \ | |
| -Wno-dev | |
| ninja -C msa/build | |
| - name: Compilar MCPELauncher (No GUI) | |
| run: | | |
| export CC=clang CXX=clang++ | |
| cmake -S mcpelauncher -B mcpelauncher/build -G Ninja \ | |
| -DCMAKE_BUILD_TYPE=Release \ | |
| -DBUILD_WEBVIEW=OFF \ | |
| -DBUILD_UI=OFF \ | |
| -Wno-dev | |
| ninja -C mcpelauncher/build | |
| - name: Compilar Trinity Launcher | |
| run: | | |
| cd trinity | |
| chmod +x build.sh | |
| ./build.sh --deps | |
| ./build.sh --release | |
| - name: Preparar AppDir y Empaquetar con LinuxDeploy | |
| env: | |
| ARCH: x86_64 | |
| run: | | |
| # 1. Descargar herramientas | |
| wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage | |
| wget https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage | |
| chmod +x linuxdeploy*.AppImage | |
| # 2. Crear estructura inicial | |
| mkdir -p AppDir/usr/bin | |
| mkdir -p AppDir/usr/share/mcpelauncher | |
| # 3. Copiar binarios y recursos | |
| cp mcpelauncher/build/mcpelauncher-client/mcpelauncher-client AppDir/usr/bin/ | |
| cp mcpe-extract/build/mcpelauncher-extract AppDir/usr/bin/ | |
| cp trinity/build/app/trinity AppDir/usr/bin/ | |
| find msa/build -type f -name "msa-daemon" -exec cp {} AppDir/usr/bin/ \; | |
| find msa/build -type f -name "msa-ui-qt" -exec cp {} AppDir/usr/bin/ \; | |
| cp -r linux-bin/* AppDir/usr/share/mcpelauncher/ | |
| # 4. Inyectar dependencias externas (32-bit y librerías críticas) | |
| wget https://github.com/javiercplus/my-dockers-setup/releases/download/unstable/mcpelauncher-cli-32bit.AppImage -O AppDir/usr/bin/mcpelauncher-cli-32bit.AppImage | |
| ln -rs AppDir/usr/bin/mcpelauncher-cli-32bit.AppImage AppDir/usr/bin/mcpelauncher-client86 | |
| mkdir -p AppDir/usr/lib | |
| wget https://huggingface.co/datasets/ccoffee20/PEPE/resolve/main/libevdev.so.2 -O AppDir/usr/lib/libevdev.so.2 | |
| cp $(find /usr/lib/x86_64-linux-gnu -name "libzip.so*" -type f | head -n 1) AppDir/usr/lib/libzip.so.5 | |
| # 5. Ejecutar linuxdeploy puro | |
| # Esto generará el AppRun, gestionará Qt y creará el AppImage final | |
| ./linuxdeploy-x86_64.AppImage --appimage-extract-and-run \ | |
| --appdir AppDir \ | |
| -e AppDir/usr/bin/trinity \ | |
| -d trinity/resources/shortcuts/com.trench.trinity.launcher.desktop \ | |
| -i trinity/resources/branding/com.trench.trinity.launcher.svg \ | |
| --plugin qt \ | |
| --output appimage | |
| - name: Subir AppImage | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: Trinity-Launcher-Final | |
| path: "*.AppImage" |