~ubuntu-branches/ubuntu/maverick/evolution-data-server/maverick-proposed

« back to all changes in this revision

Viewing changes to libdb/test/scr021/chk.flags

  • Committer: Bazaar Package Importer
  • Author(s): Didier Roche
  • Date: 2010-05-17 17:02:06 UTC
  • mfrom: (1.1.79 upstream) (1.6.12 experimental)
  • Revision ID: james.westby@ubuntu.com-20100517170206-4ufr52vwrhh26yh0
Tags: 2.30.1-1ubuntu1
* Merge from debian experimental. Remaining change:
  (LP: #42199, #229669, #173703, #360344, #508494)
  + debian/control:
    - add Vcs-Bzr tag
    - don't use libgnome
    - Use Breaks instead of Conflicts against evolution 2.25 and earlier.
  + debian/evolution-data-server.install,
    debian/patches/45_libcamel_providers_version.patch:
    - use the upstream versioning, not a Debian-specific one 
  + debian/libedata-book1.2-dev.install, debian/libebackend-1.2-dev.install,
    debian/libcamel1.2-dev.install, debian/libedataserverui1.2-dev.install:
    - install html documentation
  + debian/rules:
    - don't build documentation it's shipped with the tarball

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/bin/sh -
2
 
#
3
 
# $Id$
4
 
#
5
 
# Check flag name-spaces.
6
 
 
7
 
d=../..
8
 
 
9
 
t1=__1
10
 
 
11
 
# Check for DB_ENV flags.
12
 
(grep 'F_ISSET([^ ]*dbenv,' $d/*/*.[chys];
13
 
 grep 'F_SET([^ ]*dbenv,' $d/*/*.[chys];
14
 
 grep 'F_CLR([^ ]*dbenv,' $d/*/*.[chys]) |
15
 
 sed -e '/DB_ENV_/d' -e '/F_SET([^ ]*dbenv, db_env_reset)/d' > $t1
16
 
[ -s $t1 ] && {
17
 
        cat $t1
18
 
        exit 1
19
 
}
20
 
 
21
 
grep 'DB_ENV_' $d/*/*.c |
22
 
sed -e '/F_.*dbenv,/d' \
23
 
    -e '/DB_ENV_TEST_RECOVERY(.*DB_TEST_/d' \
24
 
    -e '/\/libdb_java\//d' > $t1
25
 
[ -s $t1 ] && {
26
 
        cat $t1
27
 
        exit 1
28
 
}
29
 
 
30
 
# Check for DB flags.
31
 
(grep 'F_ISSET([^ ]*dbp,' $d/*/*.[chys];
32
 
 grep 'F_SET([^ ]*dbp,' $d/*/*.[chys];
33
 
 grep 'F_CLR([^ ]*dbp,' $d/*/*.[chys]) |
34
 
 sed -e '/DB_AM_/d' \
35
 
     -e '/db.c:.*F_SET.*F_ISSET(subdbp,/d' > $t1
36
 
[ -s $t1 ] && {
37
 
        cat $t1
38
 
        exit 1
39
 
}
40
 
 
41
 
grep 'DB_AM_' $d/*/*.c |
42
 
sed -e '/F_.*dbp/d' \
43
 
    -e '/"DB->open", dbp->flags, DB_AM_DUP,/d' \
44
 
    -e '/"DB_NODUPDATA" behavior for databases with/d' \
45
 
    -e '/If DB_AM_OPEN_CALLED is not set, then we/d' \
46
 
    -e '/This was checked in set_flags when DB_AM_ENCRYPT/d' \
47
 
    -e '/XA_ABORT, we can safely set DB_AM_RECOVER/d' \
48
 
    -e '/ DB_AM_RECNUM\./d' \
49
 
    -e '/ DB_AM_RECOVER set\./d' \
50
 
    -e '/isdup = dbp->flags & DB_AM_DUP/d' \
51
 
    -e '/otherwise we simply do/d' \
52
 
    -e '/pginfo/d' \
53
 
    -e '/setting DB_AM_RECOVER, we guarantee that we don/d' \
54
 
    -e '/:[      {]*DB_AM_/d' > $t1
55
 
[ -s $t1 ] && {
56
 
        cat $t1
57
 
        exit 1
58
 
}
59
 
 
60
 
# Check for DBC flags.
61
 
(grep 'F_ISSET([^ ]*dbc,' $d/*/*.[chys];
62
 
 grep 'F_SET([^ ]*dbc,' $d/*/*.[chys];
63
 
 grep 'F_CLR([^ ]*dbc,' $d/*/*.[chys]) |
64
 
 sed -e '/DBC_/d' > $t1
65
 
[ -s $t1 ] && {
66
 
        cat $t1
67
 
        exit 1
68
 
}
69
 
 
70
 
grep 'DBC_' $d/*/*.c |
71
 
sed -e '/F_.*dbc/d' \
72
 
    -e '/DBC_INTERNAL/d' \
73
 
    -e '/DBC_LOGGING/d' \
74
 
    -e '/Do the actual get.  Set DBC_TRANSIENT/d' \
75
 
    -e '/If DBC_WRITEDUP is set, the cursor is an in/d' \
76
 
    -e '/The DBC_TRANSIENT flag indicates that we/d' \
77
 
    -e '/This function replaces the DBC_CONTINUE and DBC_KEYSET/d' \
78
 
    -e '/db_cam.c:.*F_CLR(opd, DBC_ACTIVE);/d' \
79
 
    -e '/{ DBC_/d' > $t1
80
 
[ -s $t1 ] && {
81
 
        cat $t1
82
 
        exit 1
83
 
}
84
 
 
85
 
# Check for bad use of macros.
86
 
egrep 'case .*F_SET\(|case .*F_CLR\(' $d/*/*.c > $t1
87
 
egrep 'for .*F_SET\(|for .*F_CLR\(' $d/*/*.c >> $t1
88
 
egrep 'if .*F_SET\(|if .*F_CLR\(' $d/*/*.c >> $t1
89
 
egrep 'switch .*F_SET\(|switch .*F_CLR\(' $d/*/*.c >> $t1
90
 
egrep 'while .*F_SET\(|while .*F_CLR\(' $d/*/*.c >> $t1
91
 
[ -s $t1 ] && {
92
 
        echo 'if statement followed by non-test macro'
93
 
        cat $t1
94
 
        exit 1
95
 
}
96
 
 
97
 
exit 0