summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2011-04-30 21:59:56 +0200
committerDaniel Friesel <derf@finalrewind.org>2011-04-30 21:59:56 +0200
commit858fefb5f1db61b8cc90149432fdc5f76677311e (patch)
tree31c2e08181baf79f7758f37919394dabb87be429
parent753fc6efd6488d16d83f9cc20b45958d9b208420 (diff)
Do not include help text by default
-rw-r--r--ChangeLog3
-rw-r--r--README1
-rw-r--r--config.mk5
-rw-r--r--src/options.c4
4 files changed, 13 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index ee31553..234b343 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -10,6 +10,9 @@ git HEAD
<https://github.com/derf/feh/pull/20>
* Show certain warnings in the image window as well as on the commandline
<http://github.com/derf/feh/issues/43>
+ * Since the manual is way better structured and more detailed than the
+ --help output, it now simply refers to the manual. To include the old
+ help text, build feh with 'help=1'
Sat, 23 Apr 2011 22:00:27 +0200 Daniel Friesel <derf@finalrewind.org>
diff --git a/README b/README
index d5b4a69..2faaa37 100644
--- a/README
+++ b/README
@@ -36,6 +36,7 @@ Available flags are:
* curl (default 1) - use libcurl to view http:// and similar images
* debug (default 0) - debug build, enables --debug
+ * help (default 0) - include help text (refers to the manpage otherwise)
* xinerama (default 1) - Support Xinerama multiscreen setups
So, by default libcurl and Xinerama are enabled, while debug is disabled.
diff --git a/config.mk b/config.mk
index b19a6df..8bad1a4 100644
--- a/config.mk
+++ b/config.mk
@@ -19,6 +19,7 @@ CFLAGS += -Wall -Wextra -pedantic
curl ?= 1
debug ?= 0
+help ?= 0
xinerama ?= 1
ifeq (${curl},1)
@@ -36,6 +37,10 @@ else
MAN_DEBUG =
endif
+ifeq (${help},1)
+ CFLAGS += -DINCLUDE_HELP
+endif
+
ifeq (${xinerama},1)
CFLAGS += -DHAVE_LIBXINERAMA
LDLIBS += -lXinerama
diff --git a/src/options.c b/src/options.c
index 61aee64..b947908 100644
--- a/src/options.c
+++ b/src/options.c
@@ -882,7 +882,11 @@ void show_mini_usage(void)
static void show_usage(void)
{
fputs(
+#ifdef INCLUDE_HELP
#include "help.inc"
+#else
+ "See 'man " PACKAGE "'\n"
+#endif
, stdout);
exit(0);
}