summaryrefslogtreecommitdiff
path: root/scripts/gstcvstest.sh
blob: 57cb9e9040874506598de366f320c5ba1880211f (plain)
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
#!/bin/bash
# gstreamer auto-builder
# 0.1.0
# thomas@apestaart.org
# check out fresh gstreamer cvs code anonymously, configure, build

# FIXME :
# * check out source twice, compare, to make sure we don't get code
#   in between commits
# * add rpm building if allowed
# * maybe change dir where stuff gets built ?


BR=/tmp		# build root
export DISPLAY=:0.0 # gtk-scandoc needs an X server

# delete logs
rm -rf $BR/*.log

echo -n "+ Starting on "
date
echo -n "+ "
uname -a
# delete gstreamer dir if it exists
if test -e $BR/gstreamer
then
  echo "+ Deleting $BR/gstreamer"
  chmod u+rwx -R /tmp/gstreamer
  rm -rf $BR/gstreamer
fi

cd $BR

# check out
echo "+ Checking out source code"
cvs -z3 -d:pserver:anonymous@cvs.gstreamer.sourceforge.net:/cvsroot/gstreamer co gstreamer > cvs.log 2>&1

# do your thing
cd gstreamer

# autogen
echo "+ Running ./autogen.sh"
./autogen.sh  > ../autogen.log 2>&1
if test $? -ne 0
then
  echo "- Problem while running autogen.sh"
  echo "- Dumping end of log ..."
  echo
  tail -n 20 ../autogen.log
  exit
fi

echo "+ Running ./configure --enable-docs-build=no"
./configure --enable-docs-build=no > ../configure.log 2>&1
if test $? -ne 0
then
  echo "- Problem while running configure"
  echo "- Dumping end of log ..."
  echo
  tail -n 20 ../configure.log
  exit
fi

# make
echo "+ Running make"
make > ../make.log 2>&1
if test $? -ne 0
then
  echo "- Problem while running make"
  echo "- Dumping end of log ..."
  echo
  grep -v "pasting would not give a valid" ../make.log > ../make.scrubbed.log
  tail -n 20 ../make.scrubbed.log
  exit
fi

echo "+ Running BUILD_DOCS= make distcheck"
BUILD_DOCS= make distcheck > ../makedistcheck.log 2>&1
if test $? -ne 0
then
  echo "- Problem while running make distcheck"
  echo "- Dumping end of log ..."
  echo
  tail -n 20 ../makedistcheck.log
  exit
fi

echo -n "+ Ending successful build cycle on "
date