File: build_coverity.sh

package info (click to toggle)
xmlsec1 1.3.7-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 19,916 kB
  • sloc: ansic: 100,493; xml: 19,156; sh: 8,079; makefile: 1,186; javascript: 438; perl: 199
file content (37 lines) | stat: -rwxr-xr-x 752 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/bin/sh

# input
cov_token=$1
version=$2
if [ "x$version" = "x" ]; then
    echo "Usage: $0 <token> <version>"
    exit 1
fi

# config
cov_url="https://scan.coverity.com/builds?project=xmlsec"
cov_email="aleksey@aleksey.com"
cur_pwd=`pwd`
today=`date +%F-%H-%M-%S`
tar_file="xmlsec1-$version-$today.tar.gz"

echo "============= Building xmlsec"
make clean
rm -rf cov-int/
cov-build --dir cov-int make -j4
tar czvf "$tar_file" cov-int

echo "============== Uploading to Coverity"
curl \
    --form token="$cov_token" \
    --form email="$cov_email" \
    --form file=@"$tar_file"  \
    --form version="$version" \
    --form description="$version built on $today" \
    "$cov_url"

echo "============== Cleanup"
cd "$cur_pwd"
#rm -rf "$build_root"