~ubuntu-branches/ubuntu/precise/telepathy-mission-control-5/precise

« back to all changes in this revision

Viewing changes to test/twisted/tools/exec-with-log.sh.in

  • Committer: Bazaar Package Importer
  • Author(s): Jonny Lamb
  • Date: 2011-01-27 17:54:12 UTC
  • mto: (0.12.1 upstream) (7.1.4 maverick)
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20110127175412-cijhp5z0763s11cy
Tags: upstream-5.7.2
ImportĀ upstreamĀ versionĀ 5.7.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/bin/sh
2
 
 
3
 
# Copyright (C) 2009 Nokia Corporation
4
 
# Copyright (C) 2009 Collabora Ltd.
5
 
#
6
 
# This library is free software; you can redistribute it and/or
7
 
# modify it under the terms of the GNU Lesser General Public
8
 
# License as published by the Free Software Foundation; either
9
 
# version 2.1 of the License, or (at your option) any later version.
10
 
#
11
 
# This library is distributed in the hope that it will be useful, but
12
 
# WITHOUT ANY WARRANTY; without even the implied warranty of
13
 
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14
 
# Lesser General Public License for more details.
15
 
#
16
 
# You should have received a copy of the GNU Lesser General Public
17
 
# License along with this library; if not, write to the Free Software
18
 
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
19
 
# 02110-1301 USA
20
 
 
21
 
cd "@abs_top_builddir@/test/twisted/tools"
22
 
 
23
 
ulimit -c unlimited
24
 
exec > missioncontrol-$$.log 2>&1
25
 
ln -f missioncontrol-$$.log missioncontrol.log
26
 
 
27
 
if test -z "$MC_ACCOUNT_DIR"; then
28
 
        echo "MC_ACCOUNT_DIR must be set"
29
 
        exit 1
30
 
fi
31
 
 
32
 
if test -n "$MISSIONCONTROL_TEST_VALGRIND"; then
33
 
        G_DEBUG="$G_DEBUG,gc-friendly"
34
 
        export G_DEBUG
35
 
        G_SLICE=always-malloc
36
 
        export G_SLICE
37
 
        MISSIONCONTROL_WRAPPER="valgrind --leak-check=full --num-callers=20"
38
 
        MISSIONCONTROL_WRAPPER="$MISSIONCONTROL_WRAPPER --track-origins=yes"
39
 
        MISSIONCONTROL_WRAPPER="$MISSIONCONTROL_WRAPPER -v"
40
 
        MISSIONCONTROL_WRAPPER="$MISSIONCONTROL_WRAPPER --suppressions=@abs_top_srcdir@/test/twisted/tools/valgrind.supp"
41
 
        MISSIONCONTROL_WRAPPER="$MISSIONCONTROL_WRAPPER --gen-suppressions=all"
42
 
        MISSIONCONTROL_WRAPPER="$MISSIONCONTROL_WRAPPER --show-reachable=yes"
43
 
elif test -n "$MISSIONCONTROL_TEST_REFDBG"; then
44
 
        if test -z "$REFDBG_OPTIONS" ; then
45
 
                REFDBG_OPTIONS="btnum=10"
46
 
                export REFDBG_OPTIONS
47
 
        fi
48
 
        if test -z "$MISSIONCONTROL_WRAPPER" ; then
49
 
                MISSIONCONTROL_WRAPPER="refdbg"
50
 
        fi
51
 
fi
52
 
 
53
 
if test "z$MC_EXECUTABLE" = z; then
54
 
        MC_EXECUTABLE=@abs_top_builddir@/test/twisted/mc-debug-server
55
 
fi
56
 
 
57
 
if test -f "$MC_ACCOUNT_DIR/gnome-keyring-env"; then
58
 
        cat "$MC_ACCOUNT_DIR/gnome-keyring-env"
59
 
        . "$MC_ACCOUNT_DIR/gnome-keyring-env"
60
 
        export GNOME_KEYRING_CONTROL GNOME_KEYRING_PID MC_KEYRING_NAME SSH_AUTH_SOCK
61
 
fi
62
 
 
63
 
exec @abs_top_builddir@/libtool --mode=execute \
64
 
        $MISSIONCONTROL_WRAPPER \
65
 
        $MC_EXECUTABLE