aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/check-notmuch.sh
blob: 6b5beb6262fa572d0dcfc7f331bee80f1a2b9ddd (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh

set -e

tmp=$(mktemp -d)
trap "rm -rf $tmp" EXIT

cat > $tmp/src.go <<EOF
package main

// #cgo LDFLAGS: -lnotmuch
// #include <notmuch.h>
import "C"

func main() {
	C.notmuch_status_to_string(C.NOTMUCH_STATUS_SUCCESS)
}
EOF

${GO:-go} build -o $tmp/out $tmp/src.go