]>
Commit | Line | Data |
---|---|---|
d3c72adc | 1 | #!/bin/bash |
ed9ea08d | 2 | set -e |
02aa35f3 XL |
3 | |
4 | ver="$1" | |
5 | test -n "$ver" || exit 2 | |
6 | ||
501d63d6 | 7 | SUS_WHITELIST=$(find "${PWD}/debian" -name upstream-tarball-unsuspicious.txt -type f) |
02aa35f3 | 8 | |
3d32fa04 XL |
9 | rm -rf rustc-${ver/*~*/beta}-src/ |
10 | tar xf ../rustc_$ver+dfsg1.orig.tar.xz && cd rustc-${ver/*~*/beta}-src/ | |
02aa35f3 | 11 | |
4a099bab XL |
12 | # TODO: remove this code snippet after it gets into our cargo |
13 | # Strip comments & blank lines before testing rust source code - | |
14 | # some authors like to write really long comments | |
15 | find . -name '*.rs' -execdir sed -i -e '\,^\s*//,d' -e '/^\s*$/d' '{}' \; | |
16 | ||
501d63d6 XL |
17 | /usr/share/cargo/scripts/audit-vendor-source \ |
18 | "$SUS_WHITELIST" \ | |
19 | "Files-Excluded: in debian/copyright and run a repack." | |
02aa35f3 XL |
20 | |
21 | echo "Artifacts left in rustc-$ver-src, please remove them yourself." |