chiark / gitweb /
Test dgit-repos-policy-debian with multiple (identical, as it happens) existing taints.
[dgit.git] / tests / tests / build-modes-sbuild
1 #!/bin/bash
2 set -e
3 . tests/lib
4 . $troot/lib-build-modes
5
6 t-dependencies sbuild
7 t-restrict x-dgit-schroot-build
8
9 arch=$(dpkg-architecture -qDEB_BUILD_ARCH)
10 after-hook () {
11         # sbuild likes to run the package clean target in the chroot,
12         # which isn't necessary in our case.  We don't disable it in
13         # dgit because we want to do what sbuild does, in case there
14         # are packages which don't build unless their clean target was
15         # run.  We know it must be running it in the chroot because we
16         # provide sbuild with the dsc, not the tree, so we simply
17         # ignore all executions of the clean target by schroot.
18         local sblog=../example_1.0_$arch.build
19         if [ -e $sblog ]; then
20                 sed '
21                         s/^EXAMPLE RULES TARGET clean/HOOK SUPPRESSED &/;
22                 ' <$sblog >>$bmlog
23         fi
24 }
25 bm_quirk_after_act=after-hook
26
27 bm-prep
28
29 act="sbuild -c build --no-arch-all"
30 real_act="$act"
31
32 e_source=true
33 e_targets='build-arch binary-arch'
34 bm-act-iterate
35
36 echo ok.