|
| 1 | +--- |
| 2 | + |
| 3 | +name: Build on various Operating Systems |
| 4 | + |
| 5 | +on: |
| 6 | + push: |
| 7 | + branches: [devel, master] |
| 8 | + pull_request: |
| 9 | + branches: [devel, master] |
| 10 | + |
| 11 | +env: |
| 12 | + CARLA_BRIDGE_DUMMY: 1 |
| 13 | + CARLA_BRIDGE_TESTING: native |
| 14 | + # FIXME some system library is causing memory leaks, switch to --leak-check=full when fixed |
| 15 | + PLUGIN_METADATA: .build/target/lsp-plugin-fw/plugins.json |
| 16 | + VALGRIND_ARGS: --error-exitcode=255 --leak-check=no --track-origins=yes --suppressions=.github/workflows/valgrind.supp |
| 17 | + VALGRIND_DEBUG_ARGS: --error-exitcode=255 --leak-check=full --track-origins=yes --keep-debuginfo=yes --suppressions=.github/workflows/valgrind.supp |
| 18 | + |
| 19 | +jobs: |
| 20 | + arch_linux: |
| 21 | + runs-on: ubuntu-latest |
| 22 | + container: |
| 23 | + image: archlinux:latest |
| 24 | + steps: |
| 25 | + - name: Add debug repositories |
| 26 | + run: | |
| 27 | + printf "[core-debug]\nInclude = /etc/pacman.d/mirrorlist\n[extra-debug]\nInclude = /etc/pacman.d/mirrorlist\n[multilib-debug]\nInclude = /etc/pacman.d/mirrorlist" >> /etc/pacman.conf |
| 28 | + printf 'Server = https://geo.mirror.pkgbuild.com/$repo/os/$arch\n%s\n' "$(cat /etc/pacman.d/mirrorlist)" > /etc/pacman.d/mirrorlist |
| 29 | + - name: Install dependencies |
| 30 | + run: pacman --noconfirm -Syu alsa-lib base-devel cairo carla git glibc-debug hicolor-icon-theme jack2 jq libglvnd libsndfile libx11 libxrandr lv2lint php valgrind gstreamer gst-plugins-base |
| 31 | + - uses: actions/checkout@v3 |
| 32 | + - name: Configure project |
| 33 | + run: make config STRICT=1 VERBOSE=1 FEATURES='clap doc jack gst ladspa lv2 ui vst2 vst3 xdg' PREFIX=/usr |
| 34 | + - name: Fetch project dependencies |
| 35 | + run: make fetch |
| 36 | + - name: Build project |
| 37 | + run: make VERBOSE=1 |
| 38 | + - name: Install binaries |
| 39 | + run: make install |
| 40 | + - name: System information |
| 41 | + run: lscpu |
| 42 | + - name: Lint LV2 plugins |
| 43 | + run: | |
| 44 | + for _plugin in $(jq -r '.plugins[].lv2_uri | select( . != null )' ${{ env.PLUGIN_METADATA }} ); do \ |
| 45 | + lv2lint -Mpack "${_plugin}"; \ |
| 46 | + done |
| 47 | + - name: Validate LV2 syntax |
| 48 | + run: lv2_validate /usr/lib/lv2/lsp-*.lv2/*.ttl |
| 49 | + - name: LADSPA runtime checks |
| 50 | + run: | |
| 51 | + for _plugin in $(jq -r '.plugins[].ladspa_label | select( . != null )' ${{ env.PLUGIN_METADATA }}); do \ |
| 52 | + valgrind ${{ env.VALGRIND_ARGS }} /usr/lib/carla/carla-bridge-native ladspa /usr/lib/ladspa/lsp-*.so "${_plugin}" 1>/dev/null; \ |
| 53 | + done |
| 54 | + - name: LV2 runtime checks |
| 55 | + run: | |
| 56 | + for _plugin in $(jq -r '.plugins[].lv2_uri | select( . != null )' ${{ env.PLUGIN_METADATA }}); do \ |
| 57 | + valgrind ${{ env.VALGRIND_ARGS }} /usr/lib/carla/carla-bridge-native lv2 "" "${_plugin}" 1>/dev/null; \ |
| 58 | + done |
| 59 | + - name: VST2 runtime checks |
| 60 | + run: | |
| 61 | + for _binary in $(ls /usr/lib/vst/lsp-plugins/*.so | grep -v /liblsp-plugins-); do \ |
| 62 | + valgrind ${{ env.VALGRIND_ARGS }} /usr/lib/carla/carla-bridge-native vst2 "${_binary}" "" 1>/dev/null; \ |
| 63 | + done |
| 64 | +
|
| 65 | + arch_linux_asan: |
| 66 | + runs-on: ubuntu-latest |
| 67 | + container: |
| 68 | + image: archlinux:latest |
| 69 | + steps: |
| 70 | + - name: Add debug repositories |
| 71 | + run: | |
| 72 | + printf "[core-debug]\nInclude = /etc/pacman.d/mirrorlist\n[extra-debug]\nInclude = /etc/pacman.d/mirrorlist\n[multilib-debug]\nInclude = /etc/pacman.d/mirrorlist" >> /etc/pacman.conf |
| 73 | + printf 'Server = https://geo.mirror.pkgbuild.com/$repo/os/$arch\n%s\n' "$(cat /etc/pacman.d/mirrorlist)" > /etc/pacman.d/mirrorlist |
| 74 | + - name: Install dependencies |
| 75 | + run: pacman --noconfirm -Syu alsa-lib base-devel cairo carla git glibc-debug hicolor-icon-theme jack2 jq libglvnd libsndfile libx11 libxrandr php valgrind gstreamer gst-plugins-base |
| 76 | + - uses: actions/checkout@v3 |
| 77 | + - name: Configure project |
| 78 | + run: make config STRICT=1 DEBUG=1 VERBOSE=1 ASAN=1 FEATURES='clap jack gst ladspa ui lv2 vst2 vst3' PREFIX=/usr |
| 79 | + - name: Fetch project dependencies |
| 80 | + run: make fetch |
| 81 | + - name: Build project |
| 82 | + run: make VERBOSE=1 |
| 83 | + - name: Install binaries |
| 84 | + run: make install |
| 85 | + - name: System information |
| 86 | + run: lscpu |
| 87 | + - name: LADSPA runtime checks |
| 88 | + run: | |
| 89 | + for _plugin in $(jq -r '.plugins[].ladspa_label | select( . != null )' ${{ env.PLUGIN_METADATA }}); do \ |
| 90 | + export ASAN_OPTIONS=verify_asan_link_order=0; \ |
| 91 | + /usr/lib/carla/carla-bridge-native ladspa /usr/lib/ladspa/lsp-*.so "${_plugin}" 1>/dev/null; \ |
| 92 | + done |
| 93 | + - name: LV2 runtime checks |
| 94 | + run: | |
| 95 | + for _plugin in $(jq -r '.plugins[].lv2_uri | select( . != null )' ${{ env.PLUGIN_METADATA }}); do \ |
| 96 | + export ASAN_OPTIONS=verify_asan_link_order=0; \ |
| 97 | + /usr/lib/carla/carla-bridge-native lv2 "" "${_plugin}" 1>/dev/null; \ |
| 98 | + done |
| 99 | + - name: VST2 runtime checks |
| 100 | + run: | |
| 101 | + for _binary in $(ls /usr/lib/vst/lsp-plugins/*.so | grep -v /liblsp-plugins-); do \ |
| 102 | + export ASAN_OPTIONS=verify_asan_link_order=0; \ |
| 103 | + /usr/lib/carla/carla-bridge-native vst2 "${_binary}" "" 1>/dev/null; \ |
| 104 | + done |
| 105 | +
|
| 106 | + arch_linux_valgrind: |
| 107 | + runs-on: ubuntu-latest |
| 108 | + container: |
| 109 | + image: archlinux:latest |
| 110 | + steps: |
| 111 | + - name: Add debug repositories |
| 112 | + run: | |
| 113 | + printf "[core-debug]\nInclude = /etc/pacman.d/mirrorlist\n[extra-debug]\nInclude = /etc/pacman.d/mirrorlist\n[multilib-debug]\nInclude = /etc/pacman.d/mirrorlist" >> /etc/pacman.conf |
| 114 | + printf 'Server = https://geo.mirror.pkgbuild.com/$repo/os/$arch\n%s\n' "$(cat /etc/pacman.d/mirrorlist)" > /etc/pacman.d/mirrorlist |
| 115 | + - name: Install dependencies |
| 116 | + run: pacman --noconfirm -Syu alsa-lib base-devel cairo carla git glibc-debug hicolor-icon-theme jack2 jq libglvnd libsndfile libx11 libxrandr php valgrind gstreamer gst-plugins-base |
| 117 | + - uses: actions/checkout@v3 |
| 118 | + - name: Configure project |
| 119 | + run: make config STRICT=1 DEBUG=1 VERBOSE=1 FEATURES='clap jack gst ladspa lv2 ui vst2 vst3' PREFIX=/usr |
| 120 | + - name: Fetch project dependencies |
| 121 | + run: make fetch |
| 122 | + - name: Build project |
| 123 | + run: make VERBOSE=1 |
| 124 | + - name: Install binaries |
| 125 | + run: make install |
| 126 | + - name: System information |
| 127 | + run: lscpu |
| 128 | + - name: LADSPA runtime checks |
| 129 | + run: | |
| 130 | + for _plugin in $(jq -r '.plugins[].ladspa_label | select( . != null )' ${{ env.PLUGIN_METADATA }}); do \ |
| 131 | + valgrind ${{ env.VALGRIND_DEBUG_ARGS }} /usr/lib/carla/carla-bridge-native ladspa /usr/lib/ladspa/lsp-*.so "${_plugin}" 1>/dev/null; \ |
| 132 | + done |
| 133 | + - name: LV2 runtime checks |
| 134 | + run: | |
| 135 | + for _plugin in $(jq -r '.plugins[].lv2_uri | select( . != null )' ${{ env.PLUGIN_METADATA }}); do \ |
| 136 | + valgrind ${{ env.VALGRIND_DEBUG_ARGS }} /usr/lib/carla/carla-bridge-native lv2 "" "${_plugin}" 1>/dev/null; \ |
| 137 | + done |
| 138 | + - name: VST2 runtime checks |
| 139 | + run: | |
| 140 | + for _binary in $(ls /usr/lib/vst/lsp-plugins/*.so | grep -v /liblsp-plugins-); do \ |
| 141 | + valgrind ${{ env.VALGRIND_DEBUG_ARGS }} /usr/lib/carla/carla-bridge-native vst2 "${_binary}" "" 1>/dev/null; \ |
| 142 | + done |
| 143 | +
|
| 144 | + opensuse_leap: |
| 145 | + runs-on: ubuntu-latest |
| 146 | + container: |
| 147 | + image: opensuse/leap:latest |
| 148 | + steps: |
| 149 | + - name: Install dependencies |
| 150 | + run: zypper --non-interactive --no-gpg-checks in tar gzip gcc gcc-c++ git make php valgrind libX11-devel libXrandr-devel Mesa-libGL-devel libjack-devel cairo-devel freetype2-devel libsndfile-devel gstreamer-devel gstreamer-plugins-base-devel |
| 151 | + - uses: actions/checkout@v3 |
| 152 | + - name: Configure project |
| 153 | + run: make config STRICT=1 VERBOSE=1 FEATURES='clap doc jack gst ladspa lv2 ui vst2 vst3 xdg' PREFIX=/usr |
| 154 | + - name: Fetch project dependencies |
| 155 | + run: make fetch |
| 156 | + - name: Build project |
| 157 | + run: make VERBOSE=1 |
| 158 | + - name: Install binaries |
| 159 | + run: make install |
| 160 | + |
| 161 | + opensuse_tumbleweed_clang: |
| 162 | + runs-on: ubuntu-latest |
| 163 | + container: |
| 164 | + image: opensuse/tumbleweed:latest |
| 165 | + steps: |
| 166 | + - name: Install dependencies |
| 167 | + run: zypper --non-interactive --no-gpg-checks in tar gzip gcc gcc-c++ clang lld git make php8-cli valgrind libstdc++-devel libX11-devel libXrandr-devel Mesa-libGL-devel libjack-devel cairo-devel freetype2-devel libsndfile-devel gstreamer-devel gstreamer-plugins-base-devel |
| 168 | + - uses: actions/checkout@v3 |
| 169 | + - name: Configure project |
| 170 | + run: make config CC=clang CXX=clang++ STRICT=1 VERBOSE=1 FEATURES='clap doc jack gst ladspa lv2 ui vst2 vst3 xdg' PREFIX=/usr |
| 171 | + - name: Fetch project dependencies |
| 172 | + run: make fetch |
| 173 | + - name: Build project |
| 174 | + run: make VERBOSE=1 |
| 175 | + - name: Install binaries |
| 176 | + run: make install |
| 177 | + |
| 178 | + debian_stable: |
| 179 | + runs-on: ubuntu-latest |
| 180 | + container: |
| 181 | + image: debian:stable |
| 182 | + steps: |
| 183 | + - name: Update repositories |
| 184 | + run: apt-get update |
| 185 | + - name: Install dependencies |
| 186 | + run: apt-get -y install gcc g++ git make php-cli pkg-config valgrind libx11-dev libxrandr-dev libjack-dev libcairo2-dev libgl-dev libfreetype6-dev libsndfile1-dev libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev |
| 187 | + - uses: actions/checkout@v3 |
| 188 | + - name: Configure project |
| 189 | + run: make config STRICT=1 VERBOSE=1 FEATURES='clap doc jack gst ladspa lv2 ui vst2 vst3 xdg' PREFIX=/usr |
| 190 | + - name: Fetch project dependencies |
| 191 | + run: make fetch |
| 192 | + - name: Build project |
| 193 | + run: make VERBOSE=1 |
| 194 | + - name: Install binaries |
| 195 | + run: make install |
| 196 | + |
| 197 | + windows_mingw64: |
| 198 | + runs-on: windows-2022 |
| 199 | + defaults: |
| 200 | + run: |
| 201 | + shell: msys2 {0} |
| 202 | + steps: |
| 203 | + - name: Setup MSYS2 and install dependencies |
| 204 | + uses: msys2/setup-msys2@v2 |
| 205 | + with: |
| 206 | + msystem: MINGW64 |
| 207 | + release: false |
| 208 | + update: false |
| 209 | + install: >- |
| 210 | + base-devel |
| 211 | + git |
| 212 | + mingw-w64-x86_64-gcc |
| 213 | + - uses: actions/checkout@v3 |
| 214 | + - name: Configure project |
| 215 | + shell: msys2 {0} |
| 216 | + run: make config STRICT=1 VERBOSE=1 FEATURES='clap ladspa lv2 ui vst2 vst3' |
| 217 | + - name: Fetch project dependencies |
| 218 | + shell: msys2 {0} |
| 219 | + run: make fetch |
| 220 | + - name: Build project |
| 221 | + shell: msys2 {0} |
| 222 | + run: make VERBOSE=1 |
| 223 | + |
0 commit comments