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.

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