From 19c8dd247563f0a725d7d368b39a5544285dc9d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mikael=20Brandstr=C3=B6m?= <mikael@brandstrom.org> Date: Mon, 8 Apr 2002 20:05:17 +0200 Subject: [PATCH] Added a snapshot target to export to Pike-vX.Y-snapshot-yyyymmdd.tar.gz Rev: Makefile:1.61 Rev: README-CVS.txt:1.15 Rev: bin/export.pike:1.46 Rev: src/Makefile.in:1.296 --- Makefile | 7 ++++++- README-CVS.txt | 3 ++- bin/export.pike | 35 ++++++++++++++++++++++++----------- src/Makefile.in | 6 +++++- 4 files changed, 37 insertions(+), 14 deletions(-) diff --git a/Makefile b/Makefile index d5651128a8..c675ac2348 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ # -# $Id: Makefile,v 1.60 2002/03/14 02:11:44 mast Exp $ +# $Id: Makefile,v 1.61 2002/04/08 18:05:16 mikael%unix.pp.se Exp $ # # Meta Makefile # @@ -204,6 +204,11 @@ export: @$(MAKE) "MAKE=$(MAKE)" "CONFIGUREARGS=--disable-binary $(CONFIGUREARGS)" \ "OS=source" "LIMITED_TARGETS=yes" "METATARGET=export" compile +snapshot_export: + @$(MAKE) "MAKE=$(MAKE)" "CONFIGUREARGS=--disable-binary $(CONFIGUREARGS)" \ + "OS=source" "LIMITED_TARGETS=yes" "METATARGET=snapshot_export" compile + +snapshot: snapshot_export autobuild_export: @$(MAKE) "MAKE=$(MAKE)" "CONFIGUREARGS=--disable-binary $(CONFIGUREARGS)" \ diff --git a/README-CVS.txt b/README-CVS.txt index e5ec15d766..4559434910 100644 --- a/README-CVS.txt +++ b/README-CVS.txt @@ -1,4 +1,4 @@ -$Id: README-CVS.txt,v 1.14 2002/04/08 17:02:43 mikael%unix.pp.se Exp $ +$Id: README-CVS.txt,v 1.15 2002/04/08 18:05:16 mikael%unix.pp.se Exp $ HOW TO BUILD PIKE FROM CVS @@ -46,6 +46,7 @@ verify run the testsuite run_hilfe run hilfe without installing pike source prepare the source tree for compiliation without the need for a Pike. +snapshot create a snapshot export tarball. export create a source dist and bump up the build number (if you have cvs write access). Please DO NOT check in the generated files. diff --git a/bin/export.pike b/bin/export.pike index 805d2e6446..b3d0001629 100755 --- a/bin/export.pike +++ b/bin/export.pike @@ -1,6 +1,6 @@ #! /usr/bin/env pike -/* $Id: export.pike,v 1.45 2002/04/08 17:02:43 mikael%unix.pp.se Exp $ */ +/* $Id: export.pike,v 1.46 2002/04/08 18:05:17 mikael%unix.pp.se Exp $ */ multiset except_modules = (<>); string vpath; @@ -114,13 +114,14 @@ int main(int argc, array(string) argv) { array(string) files; object cvs; - int notag; + int notag, snapshot; foreach(Getopt.find_all_options(argv, ({ - ({ "srcdir", Getopt.HAS_ARG, "--srcdir" }), - ({ "rebuild",Getopt.NO_ARG, "--rebuild" }), - ({ "notag", Getopt.NO_ARG, "--notag" }), - ({ "help", Getopt.NO_ARG, "--help" }), + ({ "srcdir", Getopt.HAS_ARG, "--srcdir" }), + ({ "rebuild", Getopt.NO_ARG, "--rebuild"}), + ({ "notag", Getopt.NO_ARG, "--notag" }), + ({ "help", Getopt.NO_ARG, "--help" }), + ({ "snapshot", Getopt.NO_ARG, "--snapshot"}) }) ),array opt) { switch(opt[0]) @@ -141,6 +142,10 @@ int main(int argc, array(string) argv) case "notag": notag=1; break; + + case "snapshot": + snapshot=1; + break; case "help": write(documentation); @@ -178,8 +183,14 @@ int main(int argc, array(string) argv) } else if(notag) { mapping m = gmtime(time()); - vpath = sprintf("%04d%02d%02d_%02d%02d%02d", 1900+m->year, m->mon+1, m->mday, - m->hour, m->min, m->sec); + array(int) version = getversion(); + if(snapshot) + vpath = sprintf("Pike-v%d.%d-snapshot-%02d%02d%02d", + version[0], version[1], + 1900+m->year, m->mon+1, m->mday); + else + vpath = sprintf("%04d%02d%02d_%02d%02d%02d", 1900+m->year, m->mon+1, + m->mday, m->hour, m->min, m->sec); } else { array(int) version = getversion(); @@ -264,7 +275,9 @@ Usage: export.pike --srcdir=<src> <except modules> Creates a pike distribution. Optional arguments: - rebuild - notag - help + rebuild not implemented + notag used for small export (yyyymmdd_hhmmdd.tar.gz) + snapshot modifier to notag to create filename of type + Pike-vX.Y-snapshot-yyyymmdd.tar.gz + help show this text "; diff --git a/src/Makefile.in b/src/Makefile.in index 4aec072248..e305db91cc 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -1,5 +1,5 @@ # -# $Id: Makefile.in,v 1.295 2002/04/08 01:50:14 marcus Exp $ +# $Id: Makefile.in,v 1.296 2002/04/08 18:05:17 mikael%unix.pp.se Exp $ # # This line is needed on some machines. @@ -576,6 +576,10 @@ full_export: source chmod +x $(SRCDIR)/install-sh $(RUNPIKE) $(TMP_BINDIR)/export.pike --srcdir="$(SRCDIR)" +snapshot_export: source + chmod +x $(SRCDIR)/install-sh + $(RUNPIKE) $(TMP_BINDIR)/export.pike --srcdir="$(SRCDIR)" --notag --snapshot + export: full_export all_exports: full_export -- GitLab