summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <maclas@gmx.de>2003-12-27 00:47:05 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2003-12-27 00:47:05 +0000
commit077cc1f9bc32a7e27dc23eb1fe4da21de0147350 (patch)
tree714911f9d75940538d8dc3c7ee67d156272dce9e
parent6014453a0d4527530267e53c8c633323643c8606 (diff)
downloadgtk-doc-077cc1f9bc32a7e27dc23eb1fe4da21de0147350.tar.gz
Add --help. (#126915)
Sat Dec 27 01:36:08 2003 Matthias Clasen <maclas@gmx.de> * gtkdoc-scangobj.in: * gtkdoc-mktmpl.in: * gtkdoc-scan.in: * gtkdoc-fixxref.in: Add --help. (#126915)
-rw-r--r--ChangeLog7
-rwxr-xr-xgtkdoc-fixxref.in22
-rwxr-xr-xgtkdoc-mktmpl.in20
-rwxr-xr-xgtkdoc-scan.in20
-rw-r--r--gtkdoc-scangobj.in21
5 files changed, 83 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index e01791c..dded430 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+Sat Dec 27 01:36:08 2003 Matthias Clasen <maclas@gmx.de>
+
+ * gtkdoc-scangobj.in:
+ * gtkdoc-mktmpl.in:
+ * gtkdoc-scan.in:
+ * gtkdoc-fixxref.in: Add --help. (#126915)
+
Sat Dec 27 00:43:42 2003 Matthias Clasen <maclas@gmx.de>
* gtkdoc-mkdb.in (ParseEnumDeclaration):
diff --git a/gtkdoc-fixxref.in b/gtkdoc-fixxref.in
index bb00b44..04dad59 100755
--- a/gtkdoc-fixxref.in
+++ b/gtkdoc-fixxref.in
@@ -36,20 +36,38 @@ my $MODULE_DIR;
my $HTML_DIR = "";
my @EXTRA_DIRS;
my $PRINT_VERSION;
+my $PRINT_HELP;
my %optctl = (module => \$MODULE,
'module-dir' => \$MODULE_DIR,
'html-dir' => \$HTML_DIR,
'extra-dir' => \@EXTRA_DIRS,
- 'version' => \$PRINT_VERSION);
+ 'version' => \$PRINT_VERSION,
+ 'help' => \$PRINT_HELP);
GetOptions(\%optctl, "module=s", "module-dir=s", "html-dir=s", "extra-dir=s@",
- "version");
+ "version", "help");
if ($PRINT_VERSION) {
print "@VERSION@\n";
exit 0;
}
+if (!$MODULE) {
+ $PRINT_HELP = 1;
+}
+
+if ($PRINT_HELP) {
+ print "gtkdoc-fixxref version @VERSION@\n";
+ print "\n--module=MODULE_NAME Name of the doc module being parsed";
+ print "\n--module-dir=MODULE_DIR The directory which contains the generated HTML";
+ print "\n--html-dir=HTML_DIR The directory where gtk-doc generated documentation is installed";
+ print "\n--extra-dir=EXTRA_DIR Directories to scan for indices in addition to HTML_DIR";
+ print "\n May be used more than once for multiple directories";
+ print "\n--version Print the version of this program";
+ print "\n--help Print this help\n";
+ exit 0;
+}
+
# This contains all the entities and their relative URLs.
my %Links;
diff --git a/gtkdoc-mktmpl.in b/gtkdoc-mktmpl.in
index a32a029..594e7d4 100755
--- a/gtkdoc-mktmpl.in
+++ b/gtkdoc-mktmpl.in
@@ -64,18 +64,34 @@ my $MODULE;
my $TMPL_DIR;
my $FLAG_CHANGES;
my $PRINT_VERSION;
+my $PRINT_HELP;
my %optctl = (module => \$MODULE,
'flag-changes' => \$FLAG_CHANGES,
'output-dir' => \$TMPL_DIR,
- 'version' => \$PRINT_VERSION);
-GetOptions(\%optctl, "module=s", "flag-changes!", "output-dir:s", "version");
+ 'version' => \$PRINT_VERSION,
+ 'help' => \$PRINT_HELP);
+GetOptions(\%optctl, "module=s", "flag-changes!", "output-dir:s", "version", "help");
if ($PRINT_VERSION) {
print "@VERSION@\n";
exit 0;
}
+if (!$MODULE) {
+ $PRINT_HELP = 1;
+}
+
+if ($PRINT_HELP) {
+ print "gtkdoc-mktmpl version @VERSION@\n";
+ print "\n--module=MODULE_NAME Name of the doc module being parsed";
+ print "\n--flag-changes If specified, changes in templates are flagged";
+ print "\n--output-dir=DIRNAME The directory where the results are stored";
+ print "\n--version Print the version of this program";
+ print "\n--help Print this help\n";
+ exit 0;
+}
+
my $ROOT_DIR = ".";
# The directory containing the template files.
diff --git a/gtkdoc-scan.in b/gtkdoc-scan.in
index 346b90f..9146dba 100755
--- a/gtkdoc-scan.in
+++ b/gtkdoc-scan.in
@@ -50,6 +50,7 @@ my $OUTPUT_DIR;
my @SOURCE_DIRS;
my $IGNORE_HEADERS = "";
my $PRINT_VERSION;
+my $PRINT_HELP;
# regexp matching cpp symbols which surround deprecated stuff
# e.g. 'GTK_ENABLE_BROKEN|GTK_DISABLE_DEPRECATED'
# these are detected if they are used as #if FOO, #ifndef FOO, or #ifdef FOO
@@ -60,9 +61,10 @@ my %optctl = (module => \$MODULE,
'ignore-headers' => \$IGNORE_HEADERS,
'output-dir' => \$OUTPUT_DIR,
'version' => \$PRINT_VERSION,
+ 'help' => \$PRINT_HELP,
'deprecated-guards' => \$DEPRECATED_GUARDS);
GetOptions(\%optctl, "module=s", "source-dir:s", "ignore-headers:s",
- "output-dir:s", "version",
+ "output-dir:s", "version", "help",
"deprecated-guards:s");
if ($PRINT_VERSION) {
@@ -70,6 +72,22 @@ if ($PRINT_VERSION) {
exit 0;
}
+if (!$MODULE) {
+ $PRINT_HELP = 1;
+}
+
+if ($PRINT_HELP) {
+ print "gtkdoc-scan version @VERSION@\n";
+ print "\n--module=MODULE_NAME Name of the doc module being parsed";
+ print "\n--source-dir=DIRNAME Directories containing the source files to scan";
+ print "\n--ignore-headers=FILES A space-separated list of header files not to scan";
+ print "\n--output-dir=DIRNAME The directory where the results are stored";
+ print "\n--deprecated-guards=GUARDS A |-separated list of symbols used as deprecation guards";
+ print "\n--version Print the version of this program";
+ print "\n--help Print this help\n";
+ exit 0;
+}
+
$DEPRECATED_GUARDS = $DEPRECATED_GUARDS ? $DEPRECATED_GUARDS : "does_not_match_any_cpp_symbols_at_all_nope";
$OUTPUT_DIR = $OUTPUT_DIR ? $OUTPUT_DIR : ".";
diff --git a/gtkdoc-scangobj.in b/gtkdoc-scangobj.in
index 9a3cdda..258a6ac 100644
--- a/gtkdoc-scangobj.in
+++ b/gtkdoc-scangobj.in
@@ -39,6 +39,7 @@ require "gtkdoc-common.pl";
my $MODULE;
my $OUTPUT_DIR;
my $PRINT_VERSION;
+my $PRINT_HELP;
my $TYPE_INIT_FUNC="g_type_init ()";
# --nogtkinit is deprecated, as it is the default now anyway.
@@ -47,9 +48,10 @@ my $TYPE_INIT_FUNC="g_type_init ()";
nogtkinit => \$NO_GTK_INIT,
'type-init-func' => \$TYPE_INIT_FUNC,
'output-dir' => \$OUTPUT_DIR,
- version => \$PRINT_VERSION);
+ 'version' => \$PRINT_VERSION,
+ 'help' => \$PRINT_HELP);
-GetOptions(\%optctl, "module=s", "types:s", "output-dir:s", "nogtkinit", "type-init-func:s", "version");
+GetOptions(\%optctl, "module=s", "types:s", "output-dir:s", "nogtkinit", "type-init-func:s", "version", "help");
if ($NO_GTK_INIT) {
# Do nothing. This just avoids a warning.
@@ -60,6 +62,21 @@ if ($PRINT_VERSION) {
exit 0;
}
+if (!$MODULE) {
+ $PRINT_HELP = 1;
+}
+
+if ($PRINT_HELP) {
+ print "gtkdoc-scangobj version @VERSION@\n";
+ print "\n--module=MODULE_NAME Name of the doc module being parsed";
+ print "\n--types=FILE The name of the file to store the types in";
+ print "\n--type-init-func=FUNC The init function to call instead of g_type_init ()";
+ print "\n--output-dir=DIRNAME The directory where the results are stored";
+ print "\n--version Print the version of this program";
+ print "\n--help Print this help\n";
+ exit 0;
+}
+
$OUTPUT_DIR = $OUTPUT_DIR ? $OUTPUT_DIR : ".";
$TYPES_FILE = $TYPES_FILE ? $TYPES_FILE : "$OUTPUT_DIR/$MODULE.types";