Debian Codegraph @

.github/workflows/buildtest.yml

raw
1 name: Build+Test
2
3 on: [ push, pull_request ]
4
5 jobs:
6 buildtest:
7 runs-on: ubuntu-latest
8 steps:
9 - uses: actions/checkout@v2
10
11 - name: Install stuff
12 run: |
13 sudo apt-get -qqy update
14 sudo apt-get -qqy install wget ca-certificates build-essential bison flex automake autoconf libtool pkg-config
15
16 - name: Set up Go
17 uses: actions/setup-go@v2
18 with:
19 go-version: 1.16
20
21 - name: Show info about build environment
22 run: |
23 pwd
24 env
25 cat /etc/debian_version
26 go version
27 gcc --version
28
29 - name: Build YARA from source
30 run: |
31 YARA_VERSION=4.5.3
32 wget --no-verbose -O- https://github.com/VirusTotal/yara/archive/v${YARA_VERSION}.tar.gz | tar -C .. -xzf -
33 ( cd ../yara-${YARA_VERSION} && ./bootstrap.sh )
34 mkdir -p ../yara-build
35 ( cd ../yara-build && \
36 ../yara-${YARA_VERSION}/configure --disable-shared --prefix=${HOME}/prefix )
37 make -C ../yara-build install
38 find ${HOME}/prefix
39
40 - name: Build/Test
41 run: |
42 export PKG_CONFIG_PATH=${HOME}/prefix/lib/pkgconfig
43 go test -v -tags yara_static ./...