Skip to content

Commit

Permalink
Add debian builder script that is versioned
Browse files Browse the repository at this point in the history
* This script can be run by buildbot to generate the debian files
e.g.: PARALLEL=4 scripts/build-deb.sh

Signed-off-by: Brenden Blanco <[email protected]>
  • Loading branch information
Brenden Blanco committed Sep 2, 2015
1 parent 4a36a54 commit c234344
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 0 deletions.
22 changes: 22 additions & 0 deletions scripts/build-deb.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash

set -x
set -e

PARALLEL=${PARALLEL:-1}
TMP=$(mktemp -d /tmp/debuild.XXXXXX)

function cleanup() {
[[ -d $TMP ]] && rm -rf $TMP
}
trap cleanup EXIT

mkdir $TMP/bcc
cp -a * $TMP/bcc
pushd $TMP
tar zcf bcc_0.1.6.orig.tar.gz bcc/
cd bcc
DEB_BUILD_OPTIONS="nocheck parallel=${PARALLEL}" debuild -us -uc
popd

cp $TMP/*.deb .
22 changes: 22 additions & 0 deletions scripts/build-deb.sh.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash

set -x
set -e

PARALLEL=${PARALLEL:-1}
TMP=$(mktemp -d /tmp/debuild.XXXXXX)

function cleanup() {
[[ -d $TMP ]] && rm -rf $TMP
}
trap cleanup EXIT

mkdir $TMP/bcc
cp -a * $TMP/bcc
pushd $TMP
tar zcf bcc_@[email protected] bcc/
cd bcc
DEB_BUILD_OPTIONS="nocheck parallel=${PARALLEL}" debuild -us -uc
popd

cp $TMP/*.deb .
1 change: 1 addition & 0 deletions scripts/bump_version.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ configure_file(SPECS/Dockerfile.f22.in SPECS/Dockerfile.f22 @ONLY)
configure_file(SPECS/bcc.el6.spec.in SPECS/bcc.el6.spec @ONLY)
configure_file(SPECS/bcc.el7.spec.in SPECS/bcc.el7.spec @ONLY)
configure_file(SPECS/bcc.f22.spec.in SPECS/bcc.f22.spec @ONLY)
configure_file(scripts/build-deb.sh.in scripts/build-deb.sh @ONLY)

0 comments on commit c234344

Please sign in to comment.