From dddf554290fd65bd55b2b4d2cd796147d6df4712 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Sun, 29 Jul 2012 17:13:10 +0200 Subject: [PATCH] ggo: Move options from makefile to .m4 files. It's easier to specify these options for gengetopt in the corresponding m4 files, together with the command line options of the program. --- m4/gengetopt/afh.m4 | 2 ++ m4/gengetopt/audioc.m4 | 2 ++ m4/gengetopt/audiod.m4 | 2 ++ m4/gengetopt/client.m4 | 3 ++- m4/gengetopt/filter.m4 | 2 ++ m4/gengetopt/makefile | 3 --- m4/gengetopt/recv.m4 | 2 ++ m4/gengetopt/write.m4 | 2 ++ 8 files changed, 14 insertions(+), 4 deletions(-) diff --git a/m4/gengetopt/afh.m4 b/m4/gengetopt/afh.m4 index ba7d7901..1cb44931 100644 --- a/m4/gengetopt/afh.m4 +++ b/m4/gengetopt/afh.m4 @@ -1,3 +1,5 @@ +args "--unamed-opts=audio_file" + include(header.m4) text " diff --git a/m4/gengetopt/audioc.m4 b/m4/gengetopt/audioc.m4 index 5ecc2a92..cb7ab03e 100644 --- a/m4/gengetopt/audioc.m4 +++ b/m4/gengetopt/audioc.m4 @@ -1,3 +1,5 @@ +args "--unamed-opts=command" + include(header.m4) option "socket" s diff --git a/m4/gengetopt/audiod.m4 b/m4/gengetopt/audiod.m4 index 9aabd575..f20bd105 100644 --- a/m4/gengetopt/audiod.m4 +++ b/m4/gengetopt/audiod.m4 @@ -1,3 +1,5 @@ +args "--no-handle-help" + include(header.m4) define(CURRENT_PROGRAM,para_audiod) define(DEFAULT_CONFIG_FILE,~/.paraslash/audiod.conf) diff --git a/m4/gengetopt/client.m4 b/m4/gengetopt/client.m4 index 8ade5089..6b589dc7 100644 --- a/m4/gengetopt/client.m4 +++ b/m4/gengetopt/client.m4 @@ -1,9 +1,10 @@ +args "--unamed-opts=command --no-handle-error" + include(header.m4) define(CURRENT_PROGRAM,para_client) define(DEFAULT_CONFIG_FILE,~/.paraslash/client.conf) define(DEFAULT_HISTORY_FILE,~/.paraslash/client.history) -args "--no-handle-error" option "hostname" i "ip or host to connect" string typestr="host" default="localhost" optional option "user" u "paraslash username" string typestr="username" default="" optional option "server_port" p "port to connect" int typestr="port" default="2990" optional diff --git a/m4/gengetopt/filter.m4 b/m4/gengetopt/filter.m4 index 9df0f3f2..f2efbc44 100644 --- a/m4/gengetopt/filter.m4 +++ b/m4/gengetopt/filter.m4 @@ -1,3 +1,5 @@ +args "--no-handle-help" + include(header.m4) include(loglevel.m4) diff --git a/m4/gengetopt/makefile b/m4/gengetopt/makefile index a887ab76..e1324115 100644 --- a/m4/gengetopt/makefile +++ b/m4/gengetopt/makefile @@ -27,9 +27,6 @@ $(cmdline_dir)/%_write.cmdline.h $(cmdline_dir)/%_write.cmdline.c: $(ggo_dir)/%_ --func-name $(subst _write.ggo,,$(