From mboxrd@z Thu Jan 1 00:00:00 1970 From: kupcevic@sourceware.org Date: 17 Nov 2006 20:24:47 -0000 Subject: [Cluster-devel] conga Makefile Message-ID: <20061117202447.23705.qmail@sourceware.org> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit CVSROOT: /cvs/cluster Module name: conga Changes by: kupcevic at sourceware.org 2006-11-17 20:24:46 Modified files: . : Makefile Log message: simplify (s)rpms build process Patches: http://sourceware.org/cgi-bin/cvsweb.cgi/conga/Makefile.diff?cvsroot=cluster&r1=1.11&r2=1.12 --- conga/Makefile 2006/08/15 21:33:54 1.11 +++ conga/Makefile 2006/11/17 20:24:46 1.12 @@ -73,9 +73,9 @@ rebuild: clean all -srpms: srpm_conga srpm_clustermon +srpms: conga_srpm clustermon_srpm -srpm_conga: clean +conga_srpm: clean rm -rf ${TMP_DIR}/${CONGA_DIRNAME} cp -r . ${TMP_DIR}/${CONGA_DIRNAME} rm -rf `find ${TMP_DIR}/${CONGA_DIRNAME} -name CVS` @@ -84,20 +84,41 @@ rm -f ${TMP_DIR}/${CONGA_DIRNAME}/*.rpm tar -zcf ${CONGA_DIRNAME}.tar.gz ${TMP_DIR}/${CONGA_DIRNAME} rm -rf ${TMP_DIR}/${CONGA_DIRNAME} - rpmbuild --define "_sourcedir ." --define "_srcrpmdir ." --nodeps -bs conga.spec + if [ -n "${DISTRO}" ] ; then \ + rpmbuild --define "dist .${DISTRO}" --define "_sourcedir ." --define "_srcrpmdir ." --nodeps -bs conga.spec ; \ + else \ + rpmbuild --define "_sourcedir ." --define "_srcrpmdir ." --nodeps -bs conga.spec ; \ + fi -srpm_clustermon: clean +clustermon_srpm: clean rm -rf ${TMP_DIR}/${CLUSTERMON_DIRNAME} cp -r . ${TMP_DIR}/${CLUSTERMON_DIRNAME} rm -rf `find ${TMP_DIR}/${CLUSTERMON_DIRNAME} -name CVS` rm -f ${TMP_DIR}/${CLUSTERMON_DIRNAME}/conga.spec* rm -f ${TMP_DIR}/${CLUSTERMON_DIRNAME}/*gz rm -f ${TMP_DIR}/${CLUSTERMON_DIRNAME}/*.rpm - ./luci/utils/remove_files ${TMP_DIR}/${CLUSTERMON_DIRNAME} ricci/ricci ricci/modules/log ricci/modules/service ricci/modules/rpm ricci/modules/storage luci/site luci/storage luci/cluster luci/homebase luci/plone-custom + ./luci/utils/remove_files ${TMP_DIR}/${CLUSTERMON_DIRNAME} ricci/ricci ricci/modules/log ricci/modules/service ricci/modules/rpm ricci/modules/storage luci/site luci/storage luci/cluster luci/homebase luci/plone-custom luci/docs luci/logs tar -zcf ${CLUSTERMON_DIRNAME}.tar.gz ${TMP_DIR}/${CLUSTERMON_DIRNAME} rm -rf ${TMP_DIR}/${CLUSTERMON_DIRNAME} - rpmbuild --define "_sourcedir ." --define "_srcrpmdir ." --nodeps -bs clustermon.spec + if [ -n "${DISTRO}" ] ; then \ + rpmbuild --define "dist .${DISTRO}" --define "_sourcedir ." --define "_srcrpmdir ." --nodeps -bs clustermon.spec ; \ + else \ + rpmbuild --define "_sourcedir ." --define "_srcrpmdir ." --nodeps -bs clustermon.spec ; \ + fi + +rpms: conga_rpm clustermon_rpm + +conga_rpm: conga_srpm + if [ -n "${DISTRO}" ] ; then \ + rpmbuild --define "dist .${DISTRO}" --rebuild ${CONGA_DIRNAME}-${RELEASE}.${DISTRO}.src.rpm ; \ + else \ + rpmbuild --rebuild ${CONGA_DIRNAME}-${RELEASE}.src.rpm ; \ + fi + +clustermon_rpm: clustermon_srpm + if [ -n "${DISTRO}" ] ; then \ + rpmbuild --define "dist .${DISTRO}" --rebuild ${CLUSTERMON_DIRNAME}-${RELEASE}.${DISTRO}.src.rpm ; \ + else \ + rpmbuild --rebuild ${CLUSTERMON_DIRNAME}-${RELEASE}.src.rpm ; \ + fi -rpms: srpms - rpmbuild --rebuild ${CONGA_DIRNAME}-${RELEASE}.src.rpm - rpmbuild --rebuild ${CLUSTERMON_DIRNAME}-${RELEASE}.src.rpm