common cvs-import.sh,1.1,1.2
Cristian Gafton (gafton)
fedora-extras-commits at redhat.com
Tue Dec 7 23:09:04 UTC 2004
- Previous message (by thread): rpms/xv/devel xv-3.10a-deepcolor.patch, NONE, 1.1 xv-3.10a-gifpatch, NONE, 1.1 xv-3.10a-glibc.patch, NONE, 1.1 xv-3.10a-grabpatch, NONE, 1.1 xv-3.10a-linux.patch, NONE, 1.1 xv-3.10a-longname.patch, NONE, 1.1 xv-3.10a-pdf.patch, NONE, 1.1 xv-3.10a-vdcomp.asp.patch, NONE, 1.1 xv-3.10a.JPEG-patch, NONE, 1.1 xv-3.10a.TIFF-patch, NONE, 1.1 xv.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Next message (by thread): rpms/synce - New directory
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Changeset from: gafton
Update of /cvs/extras/common
In directory cvs.fedora.redhat.com:/tmp/cvs-serv23893
Modified Files:
cvs-import.sh
Log Message:
- accept only srpms (thanks mschwendt)
- it helps to escape shit to avoid soiling the import's Makefile
Index: cvs-import.sh
===================================================================
RCS file: /cvs/extras/common/cvs-import.sh,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- cvs-import.sh 24 Nov 2004 02:55:45 -0000 1.1
+++ cvs-import.sh 7 Dec 2004 23:09:02 -0000 1.2
@@ -79,8 +79,9 @@
exit -2
fi
NVR=$(rpm -qp --qf "%{NAME}-%{VERSION}-%{RELEASE}" $PACKAGE 2>/dev/null)
- if [ -z "$NVR" ] ; then
- echo "ERROR: Package $PACKAGE does not look like an RPM package"
+ SRCRPM=$(rpm -qp --qf "%{SOURCEPACKAGE}" $PACKAGE 2>/dev/null)
+ if [ -z "$NVR" -o "$SRCRPM" != "1" ] ; then
+ echo "ERROR: Package $PACKAGE does not look like a source RPM package"
Usage
exit -3
fi
@@ -197,21 +198,21 @@
SPECFILE = \$(firstword \$(wildcard *.spec))
define find-makefile-common
-for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
+for d in common ../common ../../common ; do if [ -f \$\$d/Makefile.common ] ; then if [ -f \$\$d/CVS/Root -a -w \$\$/Makefile.common ] ; then cd \$\$d ; cvs -Q update ; fi ; echo "\$\$d/Makefile.common" ; break ; fi ; done
endef
-MAKEFILE_COMMON := $(shell $(find-makefile-common))
+MAKEFILE_COMMON := \$(shell \$(find-makefile-common))
-ifeq ($(MAKEFILE_COMMON),)
+ifeq (\$(MAKEFILE_COMMON),)
# attept a checkout
define checkout-makefile-common
-test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
+test -f CVS/Root && { cvs -Q -d \$\$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef
-MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
+MAKEFILE_COMMON := \$(shell \$(checkout-makefile-common))
endif
-include $(MAKEFILE_COMMON)
+include \$(MAKEFILE_COMMON)
EOF
cvs -Q add Makefile sources .cvsignore
# commit all the added stuff
- Previous message (by thread): rpms/xv/devel xv-3.10a-deepcolor.patch, NONE, 1.1 xv-3.10a-gifpatch, NONE, 1.1 xv-3.10a-glibc.patch, NONE, 1.1 xv-3.10a-grabpatch, NONE, 1.1 xv-3.10a-linux.patch, NONE, 1.1 xv-3.10a-longname.patch, NONE, 1.1 xv-3.10a-pdf.patch, NONE, 1.1 xv-3.10a-vdcomp.asp.patch, NONE, 1.1 xv-3.10a.JPEG-patch, NONE, 1.1 xv-3.10a.TIFF-patch, NONE, 1.1 xv.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Next message (by thread): rpms/synce - New directory
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list