diff options
author | mharmsen <mharmsen@c9f7a03b-bd48-0410-a16d-cbbf54688b0b> | 2011-03-24 01:37:42 +0000 |
---|---|---|
committer | mharmsen <mharmsen@c9f7a03b-bd48-0410-a16d-cbbf54688b0b> | 2011-03-24 01:37:42 +0000 |
commit | 41ee494b9d898c8979ebf2bf0942db2701b5c3a1 (patch) | |
tree | 688353db373aaeceb5e7c30ef4ac9f77f1552c5d /pki/scripts | |
parent | 49afe9671fd41ad227bbe209ca58ce8c0eb1984a (diff) | |
download | pki-41ee494b9d898c8979ebf2bf0942db2701b5c3a1.tar.gz pki-41ee494b9d898c8979ebf2bf0942db2701b5c3a1.tar.xz pki-41ee494b9d898c8979ebf2bf0942db2701b5c3a1.zip |
Initial revision.
git-svn-id: svn+ssh://svn.fedorahosted.org/svn/pki/trunk@1918 c9f7a03b-bd48-0410-a16d-cbbf54688b0b
Diffstat (limited to 'pki/scripts')
-rwxr-xr-x | pki/scripts/compose_dogtag_pki_meta_packages | 78 |
1 files changed, 78 insertions, 0 deletions
diff --git a/pki/scripts/compose_dogtag_pki_meta_packages b/pki/scripts/compose_dogtag_pki_meta_packages new file mode 100755 index 000000000..a31532192 --- /dev/null +++ b/pki/scripts/compose_dogtag_pki_meta_packages @@ -0,0 +1,78 @@ +#!/bin/bash +# BEGIN COPYRIGHT BLOCK +# (C) 2010 Red Hat, Inc. +# All rights reserved. +# END COPYRIGHT BLOCK + +## +## Include common 'compose' functions +## + +COMPOSE_PWD=`dirname $0` + + +## Always switch into the base directory three levels +## above this shell script prior to executing it so +## that all of its output is written to this directory + +cd `dirname $0`/../.. + + +## +## Retrieve the name of this base directory +## + +PKI_PWD=`pwd` + +## +## Establish packages directory for 'dogtag-pki' META packages +## + +PKI_PACKAGES="${PKI_PWD}/packages" + + +## +## Specify 'dogtag-pki' META functions +## + +create_packages_directory() +{ + printf "Creating top-level 'packages' directory . . . " + mkdir -p ${PKI_PACKAGES} + printf "done.\n" +} + +create_META_package_directories() +{ + printf "Creating 'dogtag-pki' META package directories . . . " + mkdir -p ${PKI_PACKAGES} + mkdir -p ${PKI_PACKAGES}/BUILD + mkdir -p ${PKI_PACKAGES}/BUILDROOT + mkdir -p ${PKI_PACKAGES}/RPMS + mkdir -p ${PKI_PACKAGES}/SOURCES + mkdir -p ${PKI_PACKAGES}/SPECS + mkdir -p ${PKI_PACKAGES}/SRPMS + printf "done.\n" +} + +build_specified_META_package() +{ + package=$1 + spec_file_path="${PKI_PWD}/pki/specs" + spec_file="${package}.spec" + + printf "BEGIN: Building '${package}' META package . . .\n" + cp ${spec_file_path}/${spec_file} ${PKI_PACKAGES}/SPECS + rpmbuild --define "_topdir ${PKI_PACKAGES}" -ba --clean ${PKI_PACKAGES}/SPECS/${spec_file} > /dev/null 2>&1 + printf "END: Building '${package}' META package.\n" +} + + +## +## Build the 'dogtag-pki' META package +## + +create_packages_directory +create_META_package_directories +build_specified_META_package dogtag-pki + |