aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/obs/data/build_deb.sh
blob: 11eb36ff1367b92d475268bf86bb83ef226b7691 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh -ex

apt_get="apt-get"
if [ -n "$INSIDE_DOCKER" ]; then
	export DEBIAN_FRONTEND=noninteractive
	apt_get="apt-get -y"
fi

su "$BUILDUSER" -c "tar -C _temp/binpkgs -xvf _temp/srcpkgs/$PACKAGE/*.tar.*"
cd _temp/binpkgs/*

$apt_get update
$apt_get build-dep .
su "$BUILDUSER" -c "dpkg-buildpackage -us -uc -j$JOBS"

# Show contents
cd ..
for i in *.deb; do
	dpkg -c "$i"
done