diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 1b9155740..0dbb56074 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -75,3 +75,20 @@ jobs: with: name: artifacts path: ./out/artifacts + + build-freebsd: + runs-on: macos-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Build + id: test + uses: vmactions/freebsd-vm@v0.1.4 + with: + usesh: true + mem: 8192 + prepare: | + pkg install -y git gtar python3 glib meson pkgconf gobject-introspection \ + json-glib gnutls gtk-doc vala sqlite3 curl gcab libarchive libelf \ + gettext-tools gnutls usbids polkit + run: ./contrib/ci/build_freebsd.sh diff --git a/contrib/ci/build_freebsd.sh b/contrib/ci/build_freebsd.sh new file mode 100755 index 000000000..6c59efaba --- /dev/null +++ b/contrib/ci/build_freebsd.sh @@ -0,0 +1,27 @@ +#!/bin/sh +set -e +export LC_ALL=C.UTF-8 +mkdir -p build && cd build +rm -rf * +meson .. \ + -Dgtkdoc=true \ + -Dtests=true \ + -Dgudev=false \ + -Dlibjcat:gpg=false \ + -Dgusb:usb_ids=/usr/local/share/usbids/usb.ids \ + -Dplugin_altos=false \ + -Dplugin_amt=false \ + -Dplugin_dell=false \ + -Dplugin_emmc=false \ + -Dplugin_nvme=false \ + -Dplugin_synaptics_mst=false \ + -Dplugin_synaptics_rmi=false \ + -Dplugin_thunderbolt=false \ + -Dplugin_tpm=false \ + -Dplugin_uefi_capsule=false \ + -Dsystemd=false \ + $@ +ninja -v || sh +ninja test -v +DESTDIR=/tmp/install-ninja ninja install +cd ..