Add missing platforms.

No iOs for now.
This commit is contained in:
Matthieu Gautier 2020-01-21 10:10:45 +01:00
parent f73e0b2abf
commit 1b7a2c812e
4 changed files with 59 additions and 17 deletions

View File

@ -10,6 +10,11 @@ from kiwixbuild.versions import base_deps_versions
PLATFORM_TARGET = _environ["PLATFORM_TARGET"]
if PLATFORM_TARGET == "native_desktop":
PLATFORM_TARGET = "native_dyn"
DESKTOP = True
else:
DESKTOP = False
OS_NAME = _environ["OS_NAME"]
HOME = Path(os.path.expanduser("~"))

View File

@ -8,12 +8,11 @@ from common import (
upload,
OS_NAME,
PLATFORM_TARGET,
DESKTOP,
KIWIX_DESKTOP_ONLY,
)
if PLATFORM_TARGET == "android":
TARGETS = ("kiwix-lib-app",)
elif PLATFORM_TARGET.startswith("android_"):
if PLATFORM_TARGET.startswith("android_"):
TARGETS = ("libzim", "kiwix-lib")
elif PLATFORM_TARGET.startswith("iOS"):
TARGETS = ("libzim", "kiwix-lib")
@ -21,20 +20,17 @@ elif PLATFORM_TARGET.startswith("native_"):
if OS_NAME == "osx":
TARGETS = ("libzim", "zimwriterfs", "zim-tools", "kiwix-lib")
else:
if PLATFORM_TARGET == "native_dyn" and KIWIX_DESKTOP_ONLY:
if DESKTOP:
TARGETS = ("kiwix-desktop",)
elif PLATFORM_TARGET == "native_mixed":
TARGETS = ("libzim",)
else:
TARGETS = ("libzim", "zimwriterfs", "zim-tools", "kiwix-lib", "kiwix-tools")
elif PLATFORM_TARGET == "flatpak":
TARGETS = ("kiwix-desktop",)
else:
TARGETS = ("libzim", "zim-tools", "kiwix-lib", "kiwix-tools")
for target in TARGETS:
if PLATFORM_TARGET not in ("android", "flatpak"):
run_kiwix_build(target, platform=PLATFORM_TARGET, build_deps_only=True)
archive_file = make_deps_archive(target=target)
upload(archive_file, "ci@tmp.kiwix.org", "/data/tmp/ci")
os.remove(str(archive_file))
run_kiwix_build(target, platform=PLATFORM_TARGET, build_deps_only=True)
archive_file = make_deps_archive(target=target)
upload(archive_file, "ci@tmp.kiwix.org", "/data/tmp/ci")
os.remove(str(archive_file))

View File

@ -18,7 +18,6 @@ from common import (
MAKE_RELEASE,
)
def download_base_archive(base_name):
url = "http://tmp.kiwix.org/ci/{}".format(base_name)
file_path = str(HOME / base_name)

View File

@ -33,10 +33,18 @@ jobs:
target:
- native_static
- native_dyn
- android_arm
- android_arm64
- native_mixed
- native_desktop
- armhf_static
- armhf_dyn
- win32_static
- win32_dyn
- i586_static
- i586_dyn
- android_arm
- android_arm64
- android_x86
- android_x86_64
include:
- target: native_static
image_variant: xenial
@ -44,10 +52,16 @@ jobs:
- target: native_dyn
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: android_arm
- target: native_mixed
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: android_arm64
- target: native_desktop
image_variant: bionic
lib_postfix: '/x86_64-linux-gnu'
- target: armhf_static
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: armhf_dyn
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: win32_static
@ -56,6 +70,24 @@ jobs:
- target: win32_dyn
image_variant: f30
lib_postfix: '64'
- target: i586_static
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: i586_dyn
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: android_arm
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: android_arm64
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: android_x86
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
- target: android_x86_64
image_variant: xenial
lib_postfix: '/x86_64-linux-gnu'
env:
HOME: /home/runner
SSH_KEY: /tmp/id_rsa
@ -99,11 +131,15 @@ jobs:
Macos:
strategy:
fail-fast: false
matrix:
target:
- native_dyn
runs-on: macos-latest
env:
SSH_KEY: /tmp/id_rsa
OS_NAME: osx
PLATFORM_TARGET: native_dyn
steps:
- name: Checkout code
uses: actions/checkout@v1
@ -129,11 +165,17 @@ jobs:
run: |
cd $HOME
$GITHUB_WORKSPACE/.github/scripts/ensure_base_deps.py
env:
PLATFORM_TARGET: ${{matrix.target}}
- name: Compile all deps
shell: bash
run: |
cd $HOME
$GITHUB_WORKSPACE/.github/scripts/compile_all_deps.py
env:
PLATFORM_TARGET: ${{matrix.target}}
- name: Upload failure logs
if: failure()
run: $GITHUB_WORKSPACE/.github/scripts/upload_failure_logs.sh
env:
PLATFORM_TARGET: ${{matrix.target}}