diff options
author | Endi S. Dewata <edewata@redhat.com> | 2013-11-25 12:43:03 -0500 |
---|---|---|
committer | Endi S. Dewata <edewata@redhat.com> | 2013-12-06 03:18:23 -0500 |
commit | 8f6de6fd339c156ce3aad13ad5d45b635d194f79 (patch) | |
tree | 3d1b97403808f88a87b9e75aa6afc8e7280e8f8b /scripts/compose_functions | |
parent | 3adfccf442916b1f91177097a1ad318d1a2e7838 (diff) | |
download | pki-8f6de6fd339c156ce3aad13ad5d45b635d194f79.tar.gz pki-8f6de6fd339c156ce3aad13ad5d45b635d194f79.tar.xz pki-8f6de6fd339c156ce3aad13ad5d45b635d194f79.zip |
Added option to build without server packages.
The build scripts have been modified to accept an optional parameter
to build pki-core without the server packages.
Diffstat (limited to 'scripts/compose_functions')
-rw-r--r-- | scripts/compose_functions | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/scripts/compose_functions b/scripts/compose_functions index d5996ae1b..6996c7412 100644 --- a/scripts/compose_functions +++ b/scripts/compose_functions @@ -109,9 +109,10 @@ Usage() printf " ${MESSAGE}\n\n" printf "Options:\n" printf " --without-javadoc do not build Javadoc RPMS\n\n" - printf " --createrepo=<repository_location_details_file> create a \n" - printf " repository with the rpms built." - printf " Provide the configuration file with the details. \n\n" + printf " --without-server do not build server RPMS\n\n" + printf " --createrepo=<repository_config> create a \n" + printf " repository with the rpms built." + printf " Provide the configuration file with the details. \n\n" } @@ -307,7 +308,7 @@ Create_repo_after_build() ## Check for command line argument validity ## -GETOPT=`getopt -o '' -l without-javadoc,work-dir:,createrepo: -n "$0" -- "$@"` +GETOPT=`getopt -o '' -l without-javadoc,without-server,work-dir:,createrepo: -n "$0" -- "$@"` if [ $? != 0 ] ; then Usage @@ -318,7 +319,8 @@ eval set -- "$GETOPT" while true ; do case "$1" in - --without-javadoc) JAVADOC="--without javadoc" ; shift ;; + --without-javadoc) WITHOUT_JAVADOCS="--without javadoc" ; shift ;; + --without-server) WITHOUT_SERVER="--without server" ; shift ;; --work-dir) WORK_DIR="$2" ; shift 2 ;; --createrepo) CREATEREPO="Y" ; REPO_CFG_FILE="$2" ; shift 2 ;; --) shift ; break ;; @@ -331,32 +333,36 @@ if [ $# -ne 1 ] ; then exit 255 fi +OPTIONS="--define \"_topdir \`pwd\`\" $WITHOUT_JAVADOCS $WITHOUT_SERVER" + if [ $1 = "srpm" ] ; then - RPMBUILD_CMD="rpmbuild --define \"_topdir \`pwd\`\" $JAVADOC -bs" + OPTIONS="$OPTIONS -bs" FETCH_SOURCE_TARBALL=0 FETCH_PATCH_FILES=0 elif [ $1 = "hybrid_srpm" ] ; then - RPMBUILD_CMD="rpmbuild --define \"_topdir \`pwd\`\" $JAVADOC -bs" + OPTIONS="$OPTIONS -bs" FETCH_SOURCE_TARBALL=0 FETCH_PATCH_FILES=1 elif [ $1 = "patched_srpm" ] ; then - RPMBUILD_CMD="rpmbuild --define \"_topdir \`pwd\`\" $JAVADOC -bs" + OPTIONS="$OPTIONS -bs" FETCH_SOURCE_TARBALL=1 FETCH_PATCH_FILES=1 elif [ $1 = "rpms" ] ; then - RPMBUILD_CMD="rpmbuild --define \"_topdir \`pwd\`\" $JAVADOC -ba" + OPTIONS="$OPTIONS -ba" FETCH_SOURCE_TARBALL=0 FETCH_PATCH_FILES=0 elif [ $1 = "hybrid_rpms" ] ; then - RPMBUILD_CMD="rpmbuild --define \"_topdir \`pwd\`\" $JAVADOC -ba" + OPTIONS="$OPTIONS -ba" FETCH_SOURCE_TARBALL=0 FETCH_PATCH_FILES=1 elif [ $1 = "patched_rpms" ] ; then - RPMBUILD_CMD="rpmbuild --define \"_topdir \`pwd\`\" $JAVADOC -ba" + OPTIONS="$OPTIONS -ba" FETCH_SOURCE_TARBALL=1 FETCH_PATCH_FILES=1 else Usage exit 255 fi + +RPMBUILD_CMD="rpmbuild $OPTIONS" export RPMBUILD_CMD |