[csw-devel] SF.net SVN: opencsw:[375] gar-wrapper/mgar
skayser at users.sourceforge.net
skayser at users.sourceforge.net
Tue Jul 5 22:31:35 CEST 2011
Revision: 375
http://opencsw.svn.sourceforge.net/opencsw/?rev=375&view=rev
Author: skayser
Date: 2011-07-05 20:31:35 +0000 (Tue, 05 Jul 2011)
Log Message:
-----------
mgar: fix newpkg skeleton generation logic
Modified Paths:
--------------
gar-wrapper/mgar
Modified: gar-wrapper/mgar
===================================================================
--- gar-wrapper/mgar 2011-06-26 21:35:22 UTC (rev 374)
+++ gar-wrapper/mgar 2011-07-05 20:31:35 UTC (rev 375)
@@ -32,12 +32,14 @@
# ----------------------------------------------------------------------------
#
# Todos:
+# * Enable checkout of a specific revision for build recipe + GAR
+# (~/opencsw/.buildsys/vX at YYYY, ~/opencsw/foo/trunk at YYYY)
# * Add template for ~/.garrc (think new users)
# * When packaging mgar, shield mgar up --self so that it won't override
# the package binary, but place it somewhere else.
-# * In commit mode, if (pwd.endswith('trunk') and svn.rev -eq 0) commit ..
# * Recipes: Move from svn:externals to GARTYPE
-# * Improve errors messages when buildsys can't be found
+# * Improve error messages when buildsys can't be found
+# * Improve error messages when pwd != build dir (refer to miss./wrong Makefile)
# * In commit mode: verify that checksums is up to date (DISTFILES listed?)
#
# Bugs:
@@ -423,10 +425,12 @@
echo "Creating package skeleton for ${__pkgname} ${__version}."
svn mkdir --parents ${__pkgname}/trunk/files ${__pkgname}/{branches,tags}
touch ${__pkgname}/trunk/checksums
- perl -p -e "\
- s,%NAME%,${__pkgname},; \
- s,%VERSION%,${__version},; \
- " ${__template} > ${__pkgname}/trunk/Makefile
+ echo -e '%:\n\t$(MAKE) -C trunk $*' > ${__pkgname}/Makefile
+ python -c "from mako.template import Template; \
+ v = { 'name': \"${__pkgname}\", 'version': \"${__version}\" }; \
+ t = Template(filename=\"${__template}\"); \
+ print t.render(**v)" > ${__pkgname}/trunk/Makefile
+ svn add ${__pkgname}/Makefile
svn add ${__pkgname}/trunk/Makefile
svn add ${__pkgname}/trunk/checksums
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the devel
mailing list