mirror of
https://github.com/postgres/postgres.git
synced 2025-08-27 07:42:10 +03:00
Remove separate version numbering for ecpg preprocessor.
Once upon a time, it made sense for the ecpg preprocessor to have its own version number, because it used a manually-maintained grammar that wasn't always in sync with the core grammar. But those days are thankfully long gone, leaving only a maintenance nuisance behind. Let's use the PG v10 version numbering changeover as an excuse to get rid of the ecpg version number and just have ecpg identify itself by PG_VERSION. From the user's standpoint, ecpg will go from "4.12" in the 9.6 branch to "10" in the 10 branch, so there's no failure of monotonicity. Discussion: <1471332659.4410.67.camel@postgresql.org>
This commit is contained in:
@@ -150,8 +150,7 @@ main(int argc, char *const argv[])
|
||||
switch (c)
|
||||
{
|
||||
case ECPG_GETOPT_LONG_VERSION:
|
||||
printf("ecpg (PostgreSQL %s) %d.%d.%d\n", PG_VERSION,
|
||||
MAJOR_VERSION, MINOR_VERSION, PATCHLEVEL);
|
||||
printf("ecpg %s\n", PG_VERSION);
|
||||
exit(0);
|
||||
case ECPG_GETOPT_LONG_HELP:
|
||||
help(progname);
|
||||
@@ -264,8 +263,9 @@ main(int argc, char *const argv[])
|
||||
|
||||
if (verbose)
|
||||
{
|
||||
fprintf(stderr, _("%s, the PostgreSQL embedded C preprocessor, version %d.%d.%d\n"),
|
||||
progname, MAJOR_VERSION, MINOR_VERSION, PATCHLEVEL);
|
||||
fprintf(stderr,
|
||||
_("%s, the PostgreSQL embedded C preprocessor, version %s\n"),
|
||||
progname, PG_VERSION);
|
||||
fprintf(stderr, _("EXEC SQL INCLUDE ... search starts here:\n"));
|
||||
for (ip = include_paths; ip != NULL; ip = ip->next)
|
||||
fprintf(stderr, " %s\n", ip->path);
|
||||
@@ -440,7 +440,7 @@ main(int argc, char *const argv[])
|
||||
if (regression_mode)
|
||||
fprintf(yyout, "/* Processed by ecpg (regression mode) */\n");
|
||||
else
|
||||
fprintf(yyout, "/* Processed by ecpg (%d.%d.%d) */\n", MAJOR_VERSION, MINOR_VERSION, PATCHLEVEL);
|
||||
fprintf(yyout, "/* Processed by ecpg (%s) */\n", PG_VERSION);
|
||||
|
||||
if (header_mode == false)
|
||||
{
|
||||
|
Reference in New Issue
Block a user