From f983234f46bd49df1605b17c373dca160dd1946d Mon Sep 17 00:00:00 2001 From: bsd Date: Thu, 6 Feb 2003 05:45:06 +0000 Subject: [PATCH] Get rid of the verbose printing of individual file CVS version ids. This was intended to be used for identifying code in the field for incoming bug reports, but I've never really found it all that useful. git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@171 81a1dc3b-b13d-400b-aceb-764788c761c2 --- avr.c | 4 +- avr.h | 2 +- config.c | 4 +- config.h | 2 +- config_gram.y | 2 +- fileio.c | 4 +- fileio.h | 2 +- lexer.l | 2 +- lists.c | 4 +- lists.h | 2 +- main.c | 142 ++------------------------------------------------ pgm.c | 4 +- pgm.h | 2 +- pindefs.h | 2 +- ppi.c | 7 +-- ppi.h | 2 +- stk500.c | 4 +- stk500.h | 2 +- term.c | 4 +- term.h | 2 +- 20 files changed, 24 insertions(+), 175 deletions(-) diff --git a/avr.c b/avr.c index 45b661b7..3cac7704 100644 --- a/avr.c +++ b/avr.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -48,8 +48,6 @@ extern char progbuf[]; extern PROGRAMMER * pgm; -char * avr_version = "$Id$"; - extern int do_cycles; diff --git a/avr.h b/avr.h index 7e7ac16d..eac30546 100644 --- a/avr.h +++ b/avr.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/config.c b/config.c index aeaf307f..bbd89e38 100644 --- a/config.c +++ b/config.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -54,8 +54,6 @@ char * infile = NULL; #define DEBUG 0 -char * config_version = "$Id$"; - int init_config(void) { diff --git a/config.h b/config.h index 544a1677..43d6eae2 100644 --- a/config.h +++ b/config.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/config_gram.y b/config_gram.y index 21020f18..1c26424c 100644 --- a/config_gram.y +++ b/config_gram.y @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/fileio.c b/fileio.c index 3b9dff6a..4a3cfccd 100644 --- a/fileio.c +++ b/fileio.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -57,8 +57,6 @@ struct ihexrec { extern char * progname; extern char progbuf[]; -char * fileio_version = "$Id$"; - int b2ihex(unsigned char * inbuf, int bufsize, int recsize, int startaddr, char * outfile, FILE * outf); diff --git a/fileio.h b/fileio.h index 05f57ae7..e4b9347b 100644 --- a/fileio.h +++ b/fileio.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/lexer.l b/lexer.l index 3e491247..dad77094 100644 --- a/lexer.l +++ b/lexer.l @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/lists.c b/lists.c index b743d862..07c6fd3e 100644 --- a/lists.c +++ b/lists.c @@ -1,6 +1,6 @@ /* * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, - * 1998, 1999, 2000, 2001, 2002 Brian S. Dean + * 1998, 1999, 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -51,8 +51,6 @@ #include "lists.h" -char * lists_version = "$Id$"; - #define MAGIC 0xb05b05b0 #define CHECK_MAGIC 0 /* set to 1 to enable memory overwrite detection */ diff --git a/lists.h b/lists.h index f9544db5..7a872013 100644 --- a/lists.h +++ b/lists.h @@ -1,6 +1,6 @@ /* * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, - * 1998, 1999, 2000, 2001, 2002 Brian S. Dean + * 1998, 1999, 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/main.c b/main.c index 39bc6f48..1f33e59b 100644 --- a/main.c +++ b/main.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -96,33 +96,7 @@ #define DEFAULT_PARALLEL "/dev/ppi0" #define DEFAULT_SERIAL "/dev/cuaa0" -extern char * avr_version; -extern char * config_version; -extern char * fileio_version; -extern char * lists_version; -extern char * main_version; -extern char * pgm_version; -extern char * ppi_version; -extern char * stk500_version; -extern char * term_version; - -#define N_MODULES 9 - -char ** modules[N_MODULES] = { - &avr_version, - &config_version, - &fileio_version, - &lists_version, - &main_version, - &pgm_version, - &ppi_version, - &stk500_version, - &term_version -}; - -char * version = "3.0.0"; - -char * main_version = "$Id$"; +char * version = "3.1.0"; char * progname; char progbuf[PATH_MAX]; /* temporary buffer of spaces the same @@ -187,105 +161,6 @@ int getexitspecs(char *s, int *set, int *clr) } -int parse_cvsid(char * cvsid, char * name, char * rev, char * datetime) -{ - int i, j; - - if (strncmp(cvsid,"$Id: ", 5) != 0) - return -1; - - name[0] = 0; - rev[0] = 0; - datetime[0] = 0; - - i = 0; - j = 5; - while (cvsid[j] && cvsid[j] != ',') - name[i++] = cvsid[j++]; - name[i] = 0; - - while (cvsid[j] && cvsid[j] != ' ') - j++; - - if (cvsid[j]) - j++; - - i = 0; - while (cvsid[j] && cvsid[j] != ' ') - rev[i++] = cvsid[j++]; - rev[i] = 0; - - if (cvsid[j]) - j++; - - i = 0; - while (cvsid[j] && cvsid[j] != ' ') - datetime[i++] = cvsid[j++]; - if (cvsid[j] == ' ') { - datetime[i++] = cvsid[j++]; - while (cvsid[j] && cvsid[j] != ' ') - datetime[i++] = cvsid[j++]; - } - datetime[i] = 0; - - return 0; -} - - -int print_module_versions(FILE * outf, char * timestamp) -{ - char name[64], rev[16], datetime[64]; - int y, m, d, h, min, s; - int i; - int rc; - int maxtime; - struct tm t; - time_t now; - - maxtime = 0; - for (i=0; i maxtime) { - maxtime = now; - strcpy(timestamp, datetime); - strcat(timestamp, " GMT"); - } - } - if (outf) - fprintf(outf, " %-10s %-5s %s\n", name, rev, datetime); - } - - if (outf) - fprintf(outf, "\n"); - -#if 0 - gmtime_r(&maxtime, &t); - fprintf(stderr, "Latest revision date is %04d/%02d/%02d %02d:%02d:%02d\n", - t.tm_year+1900, t.tm_mon, t.tm_mday, - t.tm_hour, t.tm_min, t.tm_sec); -#endif - - if (outf) - fprintf(outf, "\n"); - - return 0; -} - - int read_config(char * file) { @@ -409,7 +284,6 @@ int main(int argc, char * argv []) int readorwrite; /* true if a chip read/write op was selected */ int ppidata; /* cached value of the ppi data register */ int vsize=-1; /* number of bytes to verify */ - char timestamp[64]; AVRMEM * sig; /* signature data */ /* options / operating mode variables */ @@ -496,8 +370,6 @@ int main(int argc, char * argv []) progbuf[i] = ' '; progbuf[i] = 0; - print_module_versions(NULL, timestamp); - /* * check for no arguments */ @@ -663,13 +535,9 @@ int main(int argc, char * argv []) * they are running */ fprintf(stderr, - "\n%s: Copyright (c) 2000-2002 Brian Dean, bsd@bsdhome.com\n" - "%sVersion %s Revision Timestamp %s\n\n", - progname, progbuf, version, timestamp); - - if (verbose > 1) { - print_module_versions(stderr, NULL); - } + "\n%s: Version %s\n" + "%sCopyright (c) 2000-2003 Brian Dean, bsd@bsdhome.com\n\n", + progname, version, progbuf); } rc = read_config(configfile); diff --git a/pgm.c b/pgm.c index 47acf982..c34a0489 100644 --- a/pgm.c +++ b/pgm.c @@ -1,5 +1,5 @@ /* - * Copyright 2002 Brian S. Dean + * Copyright 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -45,8 +45,6 @@ int pgm_default_5 (struct programmer_t *, unsigned char cmd[4], unsigned char res[4]); void pgm_default_6 (struct programmer_t *, char *); -char * pgm_version = "$Id$"; - PROGRAMMER * pgm_new(void) { diff --git a/pgm.h b/pgm.h index 8674d3c7..e7b6c78e 100644 --- a/pgm.h +++ b/pgm.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/pindefs.h b/pindefs.h index e1eed431..1e1e07ee 100644 --- a/pindefs.h +++ b/pindefs.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/ppi.c b/ppi.c index 54faf5e4..aa915a14 100644 --- a/ppi.c +++ b/ppi.c @@ -1,5 +1,5 @@ /* - * Copyright 2000, 2001, 2002 Brian S. Dean + * Copyright 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -85,11 +85,6 @@ static struct ppipins_t pins[] = { #define NPINS (sizeof(pins)/sizeof(struct ppipins_t)) -char * ppi_version = "$Id$"; - - - - int ppi_getops (int reg, unsigned long * get, unsigned long * set); int ppi_set (int fd, int reg, int bit); diff --git a/ppi.h b/ppi.h index 36e12caf..b456a16b 100644 --- a/ppi.h +++ b/ppi.h @@ -1,5 +1,5 @@ /* - * Copyright 2000, 2001, 2002 Brian S. Dean + * Copyright 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/stk500.c b/stk500.c index b6bc90c5..3b4f7dea 100644 --- a/stk500.c +++ b/stk500.c @@ -1,5 +1,5 @@ /* - * Copyright 2002 Brian S. Dean + * Copyright 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -54,8 +54,6 @@ extern char * progname; extern int do_cycles; -char * stk500_version = "$Id$"; - int static stk500_send(PROGRAMMER * pgm, char * buf, int buflen) { diff --git a/stk500.h b/stk500.h index 04811e83..77d49e17 100644 --- a/stk500.h +++ b/stk500.h @@ -1,5 +1,5 @@ /* - * Copyright 2002 Brian S. Dean + * Copyright 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/term.c b/term.c index 2e38fb9a..4dccc445 100644 --- a/term.c +++ b/term.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without @@ -55,8 +55,6 @@ struct command { char * desc; }; -char * term_version = "$Id$"; - int cmd_dump (PROGRAMMER * pgm, struct avrpart * p, int argc, char *argv[]); diff --git a/term.h b/term.h index 471d6900..eb812e5d 100644 --- a/term.h +++ b/term.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2001, 2002 Brian S. Dean + * Copyright (c) 2000, 2001, 2002, 2003 Brian S. Dean * All Rights Reserved. * * Redistribution and use in source and binary forms, with or without