You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

563 lines
24KB

  1. name: build
  2. on:
  3. push:
  4. branches:
  5. - '*'
  6. pull_request:
  7. branches:
  8. - '*'
  9. env:
  10. CACHE_VERSION: 6
  11. DEBIAN_FRONTEND: noninteractive
  12. HOMEBREW_NO_AUTO_UPDATE: 1
  13. LIBGL_ALWAYS_SOFTWARE: 'true'
  14. jobs:
  15. linux-arm64:
  16. runs-on: ubuntu-20.04
  17. steps:
  18. - uses: actions/checkout@v2
  19. with:
  20. submodules: recursive
  21. - name: Set up cache
  22. uses: actions/cache@v2
  23. with:
  24. path: |
  25. ~/PawPawBuilds
  26. key: linux-arm64-v${{ env.CACHE_VERSION }}
  27. - name: Fix GitHub's mess
  28. run: |
  29. sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
  30. sudo apt-get update -qq
  31. sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
  32. - name: Set up dependencies
  33. run: |
  34. sudo dpkg --add-architecture arm64
  35. sudo sed -i "s/deb http/deb [arch=amd64] http/" /etc/apt/sources.list
  36. echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main restricted universe multiverse" | sudo tee /etc/apt/sources.list.d/ports-arm64.list
  37. echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-updates main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-arm64.list
  38. echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-backports main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-arm64.list
  39. sudo apt-get update -qq
  40. sudo apt-get install -yqq g++-aarch64-linux-gnu libdbus-1-dev:arm64 libgl1-mesa-dev:arm64 libglib2.0-dev:arm64 libx11-dev:arm64 libxcursor-dev:arm64 libxext-dev:arm64 libxrandr-dev:arm64 qemu-user-static
  41. - name: Build extra dependencies
  42. env:
  43. PKG_CONFIG_PATH: /usr/lib/aarch64-linux-gnu/pkgconfig
  44. run: |
  45. ./deps/PawPaw/bootstrap-cardinal.sh linux-aarch64
  46. - name: Build linux arm64 cross-compiled
  47. run: |
  48. pushd deps/PawPaw; source local.env linux-aarch64; popd
  49. make features
  50. make NOOPT=true SKIP_RTAUDIO_FALLBACK=true WITH_LTO=true -j $(nproc)
  51. make unzipfx
  52. - name: Set sha8
  53. id: slug
  54. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  55. - name: Pack binaries
  56. run: |
  57. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-linux-arm64-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep -e lv2 -e vst) ../Cardinal
  58. - uses: actions/upload-artifact@v2
  59. with:
  60. name: ${{ github.event.repository.name }}-linux-arm64-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  61. path: |
  62. *.tar.gz
  63. linux-armhf:
  64. runs-on: ubuntu-20.04
  65. steps:
  66. - uses: actions/checkout@v2
  67. with:
  68. submodules: recursive
  69. - name: Set up cache
  70. uses: actions/cache@v2
  71. with:
  72. path: |
  73. ~/PawPawBuilds
  74. key: linux-armhf-v${{ env.CACHE_VERSION }}
  75. - name: Fix GitHub's mess
  76. run: |
  77. sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
  78. sudo apt-get update -qq
  79. sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
  80. - name: Set up dependencies
  81. run: |
  82. sudo dpkg --add-architecture armhf
  83. sudo sed -i "s/deb http/deb [arch=amd64] http/" /etc/apt/sources.list
  84. echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main restricted universe multiverse" | sudo tee /etc/apt/sources.list.d/ports-armhf.list
  85. echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal-updates main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-armhf.list
  86. echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal-backports main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-armhf.list
  87. sudo apt-get update -qq
  88. sudo apt-get install -yqq g++-arm-linux-gnueabihf libdbus-1-dev:armhf libgl1-mesa-dev:armhf libglib2.0-dev:armhf libx11-dev:armhf libxcursor-dev:armhf libxext-dev:armhf libxrandr-dev:armhf qemu-user-static
  89. - name: Build extra dependencies
  90. env:
  91. PKG_CONFIG_PATH: /usr/lib/arm-linux-gnueabihf/pkgconfig
  92. run: |
  93. ./deps/PawPaw/bootstrap-cardinal.sh linux-armhf
  94. - name: Build linux armhf cross-compiled
  95. run: |
  96. pushd deps/PawPaw; source local.env linux-armhf; popd
  97. make features
  98. make NOOPT=true SKIP_RTAUDIO_FALLBACK=true WITH_LTO=true -j $(nproc)
  99. make unzipfx
  100. - name: Set sha8
  101. id: slug
  102. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  103. - name: Pack binaries
  104. run: |
  105. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-linux-armhf-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep -e lv2 -e vst) ../Cardinal
  106. - uses: actions/upload-artifact@v2
  107. with:
  108. name: ${{ github.event.repository.name }}-linux-armhf-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  109. path: |
  110. *.tar.gz
  111. linux-i686:
  112. runs-on: ubuntu-20.04
  113. steps:
  114. - uses: actions/checkout@v2
  115. with:
  116. submodules: recursive
  117. - name: Set up cache
  118. uses: actions/cache@v2
  119. with:
  120. path: |
  121. ~/PawPawBuilds
  122. key: linux-i686-v${{ env.CACHE_VERSION }}
  123. - name: Fix GitHub's mess
  124. run: |
  125. sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
  126. sudo apt-get update -qq
  127. sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
  128. - name: Set up dependencies
  129. run: |
  130. sudo dpkg --add-architecture i386
  131. sudo apt-get update -qq
  132. sudo apt-get install -yqq g++-multilib libdbus-1-dev:i386 libgl1-mesa-dev:i386 libglib2.0-dev:i386 libx11-dev:i386 libxcursor-dev:i386 libxext-dev:i386 libxrandr-dev:i386
  133. - name: Build extra dependencies
  134. env:
  135. PKG_CONFIG_PATH: /usr/lib/i386-linux-gnu/pkgconfig
  136. run: |
  137. ./deps/PawPaw/bootstrap-cardinal.sh linux-i686
  138. - name: Build linux i686
  139. run: |
  140. pushd deps/PawPaw; source local.env linux-i686; popd
  141. make features
  142. make NOOPT=true SKIP_RTAUDIO_FALLBACK=true WITH_LTO=true -j $(nproc)
  143. make unzipfx
  144. - name: Set sha8
  145. id: slug
  146. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  147. - name: Pack binaries
  148. run: |
  149. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-linux-i686-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep -e lv2 -e vst) ../Cardinal
  150. - uses: actions/upload-artifact@v2
  151. with:
  152. name: ${{ github.event.repository.name }}-linux-i686-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  153. path: |
  154. *.tar.gz
  155. linux-x86_64:
  156. runs-on: ubuntu-20.04
  157. steps:
  158. - uses: actions/checkout@v2
  159. with:
  160. submodules: recursive
  161. - name: Set up cache
  162. uses: actions/cache@v2
  163. with:
  164. path: |
  165. ~/PawPawBuilds
  166. key: linux-x86_64-v${{ env.CACHE_VERSION }}
  167. - name: Set up dependencies
  168. run: |
  169. sudo apt-get update -qq
  170. sudo apt-get install -yqq libdbus-1-dev libgl1-mesa-dev libglib2.0-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev
  171. - name: Build extra dependencies
  172. run: |
  173. ./deps/PawPaw/bootstrap-cardinal.sh linux
  174. - name: Build linux x86_64
  175. run: |
  176. pushd deps/PawPaw; source local.env linux; popd
  177. make features
  178. make NOOPT=true SKIP_RTAUDIO_FALLBACK=true WITH_LTO=true -j $(nproc)
  179. make unzipfx
  180. - name: Set sha8
  181. id: slug
  182. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  183. - name: Pack binaries
  184. run: |
  185. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-linux-x86_64-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep -e lv2 -e vst) ../Cardinal
  186. - uses: actions/upload-artifact@v2
  187. with:
  188. name: ${{ github.event.repository.name }}-linux-x86_64-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  189. path: |
  190. *.tar.gz
  191. linux-x86_64-debug:
  192. runs-on: ubuntu-20.04
  193. steps:
  194. - uses: actions/checkout@v2
  195. with:
  196. submodules: recursive
  197. - name: Set up dependencies
  198. run: |
  199. sudo apt-get update -qq
  200. sudo apt-get install -yqq libdbus-1-dev libgl1-mesa-dev liblo-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev
  201. - name: Build linux x86_64 (debug)
  202. env:
  203. LDFLAGS: -static-libgcc -static-libstdc++
  204. run: |
  205. make features
  206. make DEBUG=true -j $(nproc)
  207. - name: Set sha8
  208. id: slug
  209. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  210. - name: Pack binaries
  211. run: |
  212. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-linux-x86_64-debug-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep -e lv2 -e vst)
  213. - uses: actions/upload-artifact@v2
  214. with:
  215. name: ${{ github.event.repository.name }}-linux-x86_64-debug-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  216. path: |
  217. *.tar.gz
  218. linux-x86_64-headless:
  219. runs-on: ubuntu-20.04
  220. steps:
  221. - uses: actions/checkout@v2
  222. with:
  223. submodules: recursive
  224. - name: Set up dependencies
  225. run: |
  226. sudo apt-get update -qq
  227. sudo apt-get remove -yqq libcairo2-dev libx11-dev libx11-dev libxext-dev
  228. sudo apt-get install -yqq liblo-dev
  229. - name: Build linux x86_64 (headless)
  230. run: |
  231. make HEADLESS=true features
  232. make HEADLESS=true -j $(nproc)
  233. linux-x86_64-sysdeps:
  234. runs-on: ubuntu-20.04
  235. steps:
  236. - uses: actions/checkout@v2
  237. with:
  238. submodules: recursive
  239. - name: Set up dependencies
  240. run: |
  241. sudo apt-get update -qq
  242. sudo apt-get install -yqq libdbus-1-dev libgl1-mesa-dev liblo-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev libarchive-dev libjansson-dev libsamplerate0-dev libsndfile1-dev libspeexdsp-dev
  243. - name: Build linux x86_64 (sysdeps)
  244. run: |
  245. make features
  246. make SYSDEPS=true -j $(nproc)
  247. macos-universal:
  248. runs-on: macos-10.15
  249. steps:
  250. - uses: actions/checkout@v2
  251. with:
  252. submodules: recursive
  253. - name: Set up cache
  254. uses: actions/cache@v2
  255. with:
  256. path: |
  257. ~/PawPawBuilds
  258. key: macos-universal-v${{ env.CACHE_VERSION }}
  259. - name: Fix up Xcode
  260. run: |
  261. sudo rm -Rf /Library/Developer/CommandLineTools/SDKs/*
  262. sudo xcode-select -s "/Applications/Xcode_12.3.app"
  263. - name: Build extra dependencies
  264. run: |
  265. ./deps/PawPaw/bootstrap-cardinal.sh macos-universal
  266. - name: Build macOS universal
  267. run: |
  268. pushd deps/PawPaw; source local.env macos-universal; popd
  269. make features
  270. make NOOPT=true WITH_LTO=true -j $(sysctl -n hw.logicalcpu)
  271. ./dpf/utils/package-osx-bundles.sh
  272. - name: Set sha8
  273. id: slug
  274. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  275. - uses: actions/upload-artifact@v2
  276. with:
  277. name: ${{ github.event.repository.name }}-macOS-universal-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  278. path: |
  279. *-macOS.pkg
  280. modduo:
  281. runs-on: ubuntu-20.04
  282. steps:
  283. - uses: actions/checkout@v2
  284. with:
  285. submodules: recursive
  286. - name: Set up cache
  287. uses: actions/cache@v2
  288. id: mpb-cache
  289. with:
  290. path: |
  291. ~/mod-workdir
  292. key: modduo-static-v${{ env.CACHE_VERSION }}
  293. - name: Set up dependencies
  294. run: |
  295. sudo apt-get update -qq
  296. sudo apt-get install -yqq acl bc curl cvs git mercurial rsync subversion wget bison bzip2 flex gawk gperf gzip help2man nano perl patch tar texinfo unzip automake binutils build-essential cpio libtool libncurses-dev pkg-config python libtool-bin liblo-dev qemu-user-static
  297. - name: Bootstrap toolchain
  298. if: steps.mpb-cache.outputs.cache-hit != 'true'
  299. run: |
  300. git clone --depth=1 https://github.com/moddevices/mod-plugin-builder.git deps/mod-plugin-builder
  301. sed -i "s/CT_LOG_PROGRESS_BAR=y/CT_LOG_PROGRESS_BAR=n/" deps/mod-plugin-builder/toolchain/*.config
  302. $(pwd)/deps/mod-plugin-builder/bootstrap.sh modduo-static minimal && $(pwd)/deps/mod-plugin-builder/.clean-install.sh modduo-static
  303. - name: Build for modduo
  304. run: |
  305. make modduo HEADLESS=true WITH_LTO=true -j $(nproc)
  306. - name: Set sha8
  307. id: slug
  308. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  309. - name: Pack binaries
  310. run: |
  311. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-modduo-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep lv2)
  312. - uses: actions/upload-artifact@v2
  313. with:
  314. name: ${{ github.event.repository.name }}-modduo-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  315. path: |
  316. *.tar.gz
  317. modduox:
  318. runs-on: ubuntu-20.04
  319. steps:
  320. - uses: actions/checkout@v2
  321. with:
  322. submodules: recursive
  323. - name: Set up cache
  324. uses: actions/cache@v2
  325. id: mpb-cache
  326. with:
  327. path: |
  328. ~/mod-workdir
  329. key: modduox-v${{ env.CACHE_VERSION }}
  330. - name: Set up dependencies
  331. run: |
  332. sudo apt-get update -qq
  333. sudo apt-get install -yqq acl bc curl cvs git mercurial rsync subversion wget bison bzip2 flex gawk gperf gzip help2man nano perl patch tar texinfo unzip automake binutils build-essential cpio libtool libncurses-dev pkg-config python libtool-bin liblo-dev qemu-user-static
  334. - name: Bootstrap toolchain
  335. if: steps.mpb-cache.outputs.cache-hit != 'true'
  336. run: |
  337. git clone --depth=1 https://github.com/moddevices/mod-plugin-builder.git deps/mod-plugin-builder
  338. sed -i "s/CT_LOG_PROGRESS_BAR=y/CT_LOG_PROGRESS_BAR=n/" deps/mod-plugin-builder/toolchain/*.config
  339. $(pwd)/deps/mod-plugin-builder/bootstrap.sh modduox-static minimal && $(pwd)/deps/mod-plugin-builder/.clean-install.sh modduox-static
  340. - name: Build for modduox
  341. run: |
  342. make modduox HEADLESS=true WITH_LTO=true -j $(nproc)
  343. - name: Set sha8
  344. id: slug
  345. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  346. - name: Pack binaries
  347. run: |
  348. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-modduox-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep lv2)
  349. - uses: actions/upload-artifact@v2
  350. with:
  351. name: ${{ github.event.repository.name }}-modduox-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  352. path: |
  353. *.tar.gz
  354. moddwarf:
  355. runs-on: ubuntu-20.04
  356. steps:
  357. - uses: actions/checkout@v2
  358. with:
  359. submodules: recursive
  360. - name: Set up cache
  361. uses: actions/cache@v2
  362. id: mpb-cache
  363. with:
  364. path: |
  365. ~/mod-workdir
  366. key: moddwarf-v${{ env.CACHE_VERSION }}
  367. - name: Set up dependencies
  368. run: |
  369. sudo apt-get update -qq
  370. sudo apt-get install -yqq acl bc curl cvs git mercurial rsync subversion wget bison bzip2 flex gawk gperf gzip help2man nano perl patch tar texinfo unzip automake binutils build-essential cpio libtool libncurses-dev pkg-config python libtool-bin liblo-dev qemu-user-static
  371. - name: Bootstrap toolchain
  372. if: steps.mpb-cache.outputs.cache-hit != 'true'
  373. run: |
  374. git clone --depth=1 https://github.com/moddevices/mod-plugin-builder.git deps/mod-plugin-builder
  375. sed -i "s/CT_LOG_PROGRESS_BAR=y/CT_LOG_PROGRESS_BAR=n/" deps/mod-plugin-builder/toolchain/*.config
  376. $(pwd)/deps/mod-plugin-builder/bootstrap.sh moddwarf minimal && $(pwd)/deps/mod-plugin-builder/.clean-install.sh moddwarf
  377. - name: Build for moddwarf
  378. run: |
  379. make moddwarf HEADLESS=true WITH_LTO=true -j $(nproc)
  380. - name: Set sha8
  381. id: slug
  382. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  383. - name: Pack binaries
  384. run: |
  385. tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-moddwarf-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep lv2)
  386. - uses: actions/upload-artifact@v2
  387. with:
  388. name: ${{ github.event.repository.name }}-moddwarf-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  389. path: |
  390. *.tar.gz
  391. win32:
  392. runs-on: ubuntu-20.04
  393. steps:
  394. - uses: actions/checkout@v2
  395. with:
  396. submodules: recursive
  397. - name: Set up cache
  398. uses: actions/cache@v2
  399. with:
  400. path: |
  401. ~/PawPawBuilds
  402. key: win32-v${{ env.CACHE_VERSION }}
  403. - name: Fix GitHub's mess
  404. run: |
  405. sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
  406. sudo apt-get update -qq
  407. sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
  408. - name: Set up dependencies
  409. run: |
  410. sudo dpkg --add-architecture i386
  411. sudo apt-get update -qq
  412. sudo apt-get install -yqq binutils-mingw-w64-i686 g++-mingw-w64-i686 mingw-w64 wine-stable:i386
  413. - name: Build extra dependencies
  414. run: |
  415. ./deps/PawPaw/bootstrap-cardinal.sh win32
  416. - name: Build win32 cross-compiled
  417. run: |
  418. pushd deps/PawPaw; source local.env win32; popd
  419. make features
  420. make NOOPT=true WITH_LTO=true -j $(nproc)
  421. - name: Set sha8
  422. id: slug
  423. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  424. - name: Pack binaries
  425. run: |
  426. cd bin; zip -r -9 ../${{ github.event.repository.name }}-win32-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.zip $(ls | grep -e lv2 -e vst)
  427. - uses: actions/upload-artifact@v2
  428. with:
  429. name: ${{ github.event.repository.name }}-win32-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  430. path: |
  431. *.zip
  432. win64:
  433. runs-on: ubuntu-20.04
  434. steps:
  435. - uses: actions/checkout@v2
  436. with:
  437. submodules: recursive
  438. - name: Set up cache
  439. uses: actions/cache@v2
  440. with:
  441. path: |
  442. ~/PawPawBuilds
  443. key: win64-v${{ env.CACHE_VERSION }}
  444. - name: Fix GitHub's mess
  445. run: |
  446. sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
  447. sudo apt-get update -qq
  448. sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
  449. - name: Set up dependencies
  450. run: |
  451. sudo apt-get update -qq
  452. sudo apt-get install -yqq binutils-mingw-w64-x86-64 g++-mingw-w64-x86-64 mingw-w64 wine-stable
  453. - name: Build extra dependencies
  454. run: |
  455. ./deps/PawPaw/bootstrap-cardinal.sh win64
  456. - name: Build win64 cross-compiled
  457. run: |
  458. pushd deps/PawPaw; source local.env win64; popd
  459. make features
  460. make NOOPT=true WITH_LTO=true -j $(nproc)
  461. - name: Set sha8
  462. id: slug
  463. run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)"
  464. - name: Pack binaries
  465. run: |
  466. cd bin; zip -r -9 ../${{ github.event.repository.name }}-win64-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.zip $(ls | grep -e lv2 -e vst)
  467. - uses: actions/upload-artifact@v2
  468. with:
  469. name: ${{ github.event.repository.name }}-win64-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}
  470. path: |
  471. *.zip
  472. plugin-validation:
  473. runs-on: ubuntu-20.04
  474. steps:
  475. - uses: actions/checkout@v2
  476. with:
  477. submodules: recursive
  478. - name: Set up dependencies
  479. run: |
  480. # custom repos
  481. wget https://launchpad.net/~kxstudio-debian/+archive/kxstudio/+files/kxstudio-repos_10.0.3_all.deb
  482. sudo dpkg -i kxstudio-repos_10.0.3_all.deb
  483. sudo apt-get update -qq
  484. # build-deps
  485. sudo apt-get install -yqq libgl1-mesa-dev liblo-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev
  486. # runtime testing
  487. sudo apt-get install -yqq carla-git lilv-utils lv2-dev lv2lint valgrind
  488. - name: Build plugins
  489. env:
  490. CFLAGS: -g
  491. CXXFLAGS: -g -DDPF_ABORT_ON_ERROR
  492. LDFLAGS: -static-libgcc -static-libstdc++
  493. run: |
  494. make features
  495. make NOOPT=true SKIP_STRIPPING=true -j $(nproc)
  496. - name: Validate LV2 ttl syntax
  497. run: |
  498. lv2_validate \
  499. /usr/lib/lv2/mod.lv2/*.ttl \
  500. /usr/lib/lv2/kx-meta/*.ttl \
  501. /usr/lib/lv2/kx-control-input-port-change-request.lv2/*.ttl \
  502. /usr/lib/lv2/kx-programs.lv2/*.ttl \
  503. ./bin/*.lv2/*.ttl
  504. #- name: Validate LV2 metadata and binaries
  505. #run: |
  506. #export LV2_PATH=/tmp/lv2-path
  507. #mkdir ${LV2_PATH}
  508. #cp -r bin/*.lv2 \
  509. #/usr/lib/lv2/{atom,buf-size,core,data-access,kx-control-input-port-change-request,kx-programs,instance-access,midi,parameters,port-groups,port-props,options,patch,presets,resize-port,state,time,ui,units,urid,worker}.lv2 \
  510. #${LV2_PATH}
  511. #lv2lint -s lv2_generate_ttl -l ld-linux-x86-64.so.2 -M nopack $(lv2ls)
  512. - name: Test LV2 plugin
  513. run: |
  514. export LV2_PATH=/tmp/lv2-path
  515. for p in $(lv2ls); do \
  516. env CARLA_BRIDGE_DUMMY=1 CARLA_BRIDGE_TESTING=native \
  517. valgrind \
  518. --error-exitcode=255 \
  519. --leak-check=no \
  520. --track-origins=yes \
  521. --suppressions=./dpf/utils/valgrind-dpf.supp \
  522. /usr/lib/carla/carla-bridge-native lv2 "" ${p} 1>/dev/null; \
  523. done
  524. # - name: Test VST2 plugin
  525. # env:
  526. # CARLA_DO_NOT_USE_JUCE_FOR_VST2: 1
  527. # run: |
  528. # for p in $(ls bin/*.vst/*.so); do \
  529. # env CARLA_BRIDGE_DUMMY=1 CARLA_BRIDGE_TESTING=native \
  530. # valgrind \
  531. # --error-exitcode=255 \
  532. # --leak-check=no \
  533. # --track-origins=yes \
  534. # --suppressions=./dpf/utils/valgrind-dpf.supp \
  535. # /usr/lib/carla/carla-bridge-native vst2 ./${p} "" 1>/dev/null; \
  536. # done
  537. # - name: Test VST3 plugin
  538. # run: |
  539. # for p in $(ls bin/ | grep vst3); do \
  540. # env CARLA_BRIDGE_DUMMY=1 CARLA_BRIDGE_TESTING=native \
  541. # valgrind \
  542. # --error-exitcode=255 \
  543. # --leak-check=no \
  544. # --track-origins=yes \
  545. # --suppressions=./dpf/utils/valgrind-dpf.supp \
  546. # /usr/lib/carla/carla-bridge-native vst3 ./bin/${p} "" 1>/dev/null; \
  547. # done