.gitlab-ci.yml 3.47 KB
Newer Older
1 2 3
cache:
    paths:
        - .gradle/
4
        - gradle-5.4.1/
5 6 7 8
        - gradle/
        - gradlew

.build-all-base:
9
    image: registry.videolan.org:5000/vlc-debian-android:20190507015459
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
    tags:
        - debian 
        - android
    stage: build
    script:
        - ./compile.sh ${EXTRA_BUILD_PARAM} -a ${ARCH}
    variables:
        MAKEFLAGS: -j8

# Rebuilds libvlc JNI
.build-libvlc-base:
    extends: .build-all-base
    only:
        refs:
            - master
25
            - merge_requests
26
        changes:
27
            - libvlc/**/*
28 29 30
            - build-common
            - compile.sh
            - compile-libvlc.sh
31 32
    except:
        - schedules
33 34 35 36 37 38 39 40 41
    variables:
        EXTRA_BUILD_PARAM: -l

# rebuild the medialibrary JNI component
# This implies rebuilding VLC beforehand
.build-ml-base:
    extends: .build-all-base
    only:
        refs:
42
            - master
43
            - merge_requests
44
        changes:
45
            - medialibrary/**/*
46 47 48 49
            - compile.sh
            - build-common
            - compile-libvlc.sh
            - compile-medialibrary.sh
50 51
    except:
        - schedules
52 53 54 55 56 57 58 59 60 61
    variables:
        EXTRA_BUILD_PARAM: -ml

# vlc-android app only: don't rebuild everything but use a published artifact
continuous-app-build:
    extends: .build-all-base
    script:
        - ./compile.sh --init
        - ./gradlew assembleDebug
    only:
62 63 64
        refs:
            - master
            - merge_requests
65
        changes:
66 67
            - vlc-android/**/*
            - assets/**/*
68 69
            - .gitlab-ci.yml
    except:
70 71 72 73 74 75
        refs:
            - schedules
        changes:
            - build-common
            - compile-libvlc.sh
            - compile-medialibrary.sh
76 77 78
            - compile.sh
            - libvlc/**/*
            - medialibrary/**/*
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168

#################################
# Template config instantiation #
#################################

build-libvlc-arm64:
    extends: .build-libvlc-base
    variables:
        ARCH: arm64

build-libvlc-armv7:
    extends: .build-libvlc-base
    variables:
        ARCH: arm

build-libvlc-x86:
    extends: .build-libvlc-base
    variables:
        ARCH: x86

build-libvlc-x86_64:
    extends: .build-libvlc-base
    variables:
        ARCH: x86_64

build-ml-arm64:
    extends: .build-ml-base
    variables:
        ARCH: arm64

build-ml-armv7:
    extends: .build-ml-base
    variables:
        ARCH: arm

build-ml-x86:
    extends: .build-ml-base
    variables:
        ARCH: x86

build-ml-x86_64:
    extends: .build-ml-base
    variables:
        ARCH: x86_64

# Nightly builds: build native & app code, and ship the APK as artifact
nightly-arm64:
    extends: .build-all-base
    only: 
        - schedules
    variables:
        ARCH: arm64
    artifacts:
        paths:
            - vlc-android/build/outputs/apk/dev/VLC-Android-*.apk
        expire_in: 2 weeks

nightly-armv7:
    extends: .build-all-base
    only: 
        - schedules
    variables:
        ARCH: arm
    artifacts:
        paths:
            - vlc-android/build/outputs/apk/dev/VLC-Android-*.apk
        expire_in: 2 weeks

nightly-x86:
    extends: .build-all-base
    only: 
        - schedules
    variables:
        ARCH: x86
    artifacts:
        paths:
            - vlc-android/build/outputs/apk/dev/VLC-Android-*.apk
        expire_in: 2 weeks

nightly-x86_64:
    extends: .build-all-base
    only: 
        - schedules
    variables:
        ARCH: x86_64
    artifacts:
        paths:
            - vlc-android/build/outputs/apk/dev/VLC-Android-*.apk
        expire_in: 2 weeks