Skip to content

Commit

Permalink
fixes #205 #492 Added script to generate a clean deb file.
Browse files Browse the repository at this point in the history
To use from the build dir run <src dir>/build_utils/cleanDeb.sh.

Added Copyright block.

Moved script to using deb package name passed in.

Signed-off-by: Philip Schwartz <[email protected]>
  • Loading branch information
pschwartz committed Oct 27, 2011
1 parent cdf7197 commit 4db2721
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions build_utils/cleanDeb.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#!/bin/bash
################################################################################
# Copyright (C) 2011 HPCC Systems.
#
# All rights reserved. This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
################################################################################
#
if [ $# -lt 1 ]; then
echo usage: $0 debfile
exit 1
fi

FNAME=$1
DNAME=$(basename ${FNAME} .deb)
mkdir -p ${DNAME}/DEBIAN
fakeroot dpkg-deb -x ${FNAME} ${DNAME}
fakeroot dpkg-deb -e ${FNAME} ${DNAME}/DEBIAN
rm ${FNAME}
fakeroot dpkg-deb -b ${DNAME} ${FNAME}
rm -rf ${DNAME}

0 comments on commit 4db2721

Please sign in to comment.