1
0
Fork 1
forked from suyu/suyu

CI Changes to Alow Building Linux and Android [From FORK]

This commit is contained in:
ddutchie 2024-03-14 21:35:22 +00:00
parent 3037f0b869
commit e29c55dd98
4 changed files with 28 additions and 12 deletions

View file

@ -1,6 +1,6 @@
#!/bin/bash -ex #!/bin/bash -ex
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project & 2024 suyu Emulator Project # SPDX-FileCopyrightText: 2024 suyu Emulator Project
# SPDX-License-Identifier: GPL-2.0-or-later # SPDX-License-Identifier: GPL-2.0-or-later
# Exit on error, rather than continuing with the rest of the script. # Exit on error, rather than continuing with the rest of the script.

2
.gitignore vendored
View file

@ -37,3 +37,5 @@ CMakeSettings.json
# Windows global filetypes # Windows global filetypes
Thumbs.db Thumbs.db
# Local Gitlab CI Runner
.gitlab-ci-local/

28
.gitlab-ci.yml Normal file → Executable file
View file

@ -1,27 +1,41 @@
stages: stages:
- format - format
- build - build
#CLANG FORMAT - CHECKS CODE FOR FORMATTING ISSUES
clang-format: clang-format:
stage: format stage: format
image: suyuemu/cibuild:linux-x64 image: registry.gitlab.com/ddutchie/ci-docker:clangformat
#TODO: SET THIS TO FALSE!!!
allow_failure: true allow_failure: true
variables:
RELEASE_NAME: mainline
script: script:
- git submodule update --init --depth 1 --recursive - git submodule update --init --depth 1 --recursive
- bash .ci/scripts/format/script.sh - bash .ci/scripts/format/script.sh
#LINUX BUILD - BUILDS LINUX APPIMAGE
build-linux: build-linux:
stage: build stage: build
image: suyuemu/cibuild:linux-x64 image: registry.gitlab.com/ddutchie/ci-docker:linux-x64
resource_group: linux-ci resource_group: linux-ci
variables: variables:
GIT_SUBMODULE_STRATEGY: recursive
GIT_SUBMODULE_DEPTH: 1
RELEASE_NAME: mainline RELEASE_NAME: mainline
script: script:
- git submodule update --init --depth 1 --recursive
- bash .ci/scripts/linux/docker.sh - bash .ci/scripts/linux/docker.sh
- bash .ci/scripts/linux/upload.sh - bash .ci/scripts/linux/upload.sh
artifacts: artifacts:
paths: paths:
- artifacts/* - artifacts/*
#ANDROID BUILD - BUILDS APK
android:
stage: build
image: registry.gitlab.com/ddutchie/ci-docker:android-x64
script:
- apt-get update -y
- git submodule update --init --recursive
- export ANDROID_HOME="/usr/lib/android-sdk/"
- echo y | sdkmanager --sdk_root=/usr/lib/android-sdk --licenses
- bash ./.ci/scripts/android/build.sh
- bash ./.ci/scripts/android/upload.sh
artifacts:
paths:
- artifacts/*

View file

@ -217,7 +217,7 @@ bool DecoderContext::OpenContext(const Decoder& decoder) {
return true; return true;
} }
#ifndef ANDROID
// Nasty but allows linux builds to pass. // Nasty but allows linux builds to pass.
// Requires double checks when FFMPEG gets updated. // Requires double checks when FFMPEG gets updated.
// Hopefully a future FFMPEG update will all and expose a solution in the public API. // Hopefully a future FFMPEG update will all and expose a solution in the public API.
@ -376,7 +376,7 @@ static av_always_inline const FFCodec* ffcodec(const AVCodec* codec) {
} }
} // namespace } // namespace
#endif
bool DecoderContext::SendPacket(const Packet& packet) { bool DecoderContext::SendPacket(const Packet& packet) {
m_temp_frame = std::make_shared<Frame>(); m_temp_frame = std::make_shared<Frame>();
m_got_frame = 0; m_got_frame = 0;