]> git.proxmox.com Git - rustc.git/blame - debian/check-orig-suspicious.sh
Update files for importing 1.46.0~beta.2
[rustc.git] / debian / check-orig-suspicious.sh
CommitLineData
d3c72adc 1#!/bin/bash
ed9ea08d 2set -e
02aa35f3
XL
3
4ver="$1"
5test -n "$ver" || exit 2
6
501d63d6 7SUS_WHITELIST=$(find "${PWD}/debian" -name upstream-tarball-unsuspicious.txt -type f)
02aa35f3 8
3d32fa04
XL
9rm -rf rustc-${ver/*~*/beta}-src/
10tar 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
15find . -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
21echo "Artifacts left in rustc-$ver-src, please remove them yourself."