aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2016-08-05 14:20:55 +0300
committerSergey Poznyakoff <gray@gnu.org.ua>2016-08-05 14:20:55 +0300
commit102d1b9c1a94548dfa0c498845c77933db6a7738 (patch)
tree3b2a14da2614b9f016eb555d2b3378f01e4d3c01
parentedd1a92f6743a5f5c31fa1468fdb511c097e75ad (diff)
downloadgrecs-102d1b9c1a94548dfa0c498845c77933db6a7738.tar.gz
grecs-102d1b9c1a94548dfa0c498845c77933db6a7738.tar.bz2
Minor fix
* build-aux/getopt.m4: Only define lastoptlab if necessary
-rw-r--r--build-aux/getopt.m47
1 files changed, 5 insertions, 2 deletions
diff --git a/build-aux/getopt.m4 b/build-aux/getopt.m4
index d424088..86bac99 100644
--- a/build-aux/getopt.m4
+++ b/build-aux/getopt.m4
@@ -264,7 +264,9 @@ define([<OPTNODE>],[<do {
264 264
265dnl LASTOPT() 265dnl LASTOPT()
266dnl Stop option processing (as if "--" has been encountered 266dnl Stop option processing (as if "--" has been encountered
267define([<LASTOPT>],[<goto lastoptlab>]) 267define([<LASTOPT>],[<dnl
268define([<__GETOPT_LASTOPT>],[<lastoptlab:>])dnl
269goto lastoptlab>])
268 270
269dnl GETOPT(argc, argv, [long_index], [onerr]) 271dnl GETOPT(argc, argv, [long_index], [onerr])
270dnl Emit option parsing code. Arguments: 272dnl Emit option parsing code. Arguments:
@@ -295,7 +297,7 @@ define([<GETOPT>],[<
295 undivert(4) 297 undivert(4)
296 } 298 }
297 } 299 }
298lastoptlab: 300__GETOPT_LASTOPT
299 ifelse([<$3>],,[< 301 ifelse([<$3>],,[<
300 if (optind < argc) { 302 if (optind < argc) {
301 fprintf(stderr, "%s: unexpected arguments\n", $2[0]); 303 fprintf(stderr, "%s: unexpected arguments\n", $2[0]);
@@ -352,6 +354,7 @@ divert(-1)
352 354
353define([<OPTIONS_BEGIN>], 355define([<OPTIONS_BEGIN>],
354 [<divert(-1) 356 [<divert(-1)
357 define([<__GETOPT_LASTOPT>])
355 _getopt_set_options(shift(shift(shift($@)))) 358 _getopt_set_options(shift(shift(shift($@))))
356 _getopt_if_option_set([<gnu>], 359 _getopt_if_option_set([<gnu>],
357 [<STDFUNC([<$1 " (" PACKAGE_NAME ") " PACKAGE_VERSION>], 360 [<STDFUNC([<$1 " (" PACKAGE_NAME ") " PACKAGE_VERSION>],

Return to:

Send suggestions and report system problems to the System administrator.