aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile6
-rwxr-xr-xconfigure35
-rw-r--r--doc/Makefile4
-rw-r--r--protocols/skype/Makefile6
4 files changed, 38 insertions, 13 deletions
diff --git a/Makefile b/Makefile
index fd107b0b..60ecd0cf 100644
--- a/Makefile
+++ b/Makefile
@@ -24,7 +24,9 @@ ifdef SKYPE_PI
endif
doc:
+ifdef DOC
$(MAKE) -C doc
+endif
uninstall: uninstall-bin uninstall-doc
@echo -e '\nmake uninstall does not remove files in '$(DESTDIR)$(ETCDIR)', you can use make uninstall-etc to do that.\n'
@@ -72,13 +74,17 @@ lcov: check
genhtml -o coverage bitlbee.info
install-doc:
+ifdef DOC
$(MAKE) -C doc install
+endif
ifdef SKYPE_PI
$(MAKE) -C protocols/skype install-doc
endif
uninstall-doc:
+ifdef DOC
$(MAKE) -C doc uninstall
+endif
ifdef SKYPE_PI
$(MAKE) -C protocols/skype uninstall-doc
endif
diff --git a/configure b/configure
index 8761bfd2..7b23e182 100755
--- a/configure
+++ b/configure
@@ -36,6 +36,7 @@ yahoo="default-on"
twitter=1
purple=0
+doc=1
debug=0
strip=1
gcov=0
@@ -58,10 +59,10 @@ echo BitlBee configure
# Cygwin and Darwin don't support PIC/PIE
case "$arch" in
- CYGWIN* )
- pie=0;;
- Darwin )
- pie=0;;
+ CYGWIN* )
+ pie=0;;
+ Darwin )
+ pie=0;;
esac
while [ -n "$1" ]; do
@@ -93,6 +94,7 @@ Option Description Default
--purple=0/1 Disable/enable libpurple support $purple
(automatically disables other protocol modules)
+--doc=0/1 Disable/enable help.txt generation $doc
--debug=0/1 Disable/enable debugging $debug
--strip=0/1 Disable/enable binary stripping $strip
--pie=0/1 Build position independent executable $pie
@@ -646,10 +648,27 @@ if [ "$skype" = "1" -o "$skype" = "plugin" ]; then
protocols_mods="$protocol_mods skype(plugin)"
fi
-if [ ! -e doc/user-guide/help.txt ] && ! type xmlto > /dev/null 2> /dev/null; then
- echo
- echo 'WARNING: Building from an unreleased source tree without prebuilt helpfile.'
- echo 'Install xmlto if you want online help to work.'
+if [ "$doc" = "1" ]; then
+ if [ ! -e doc/user-guide/help.txt ] && \
+ ! type xmlto > /dev/null 2> /dev/null || \
+ ! type xsltproc > /dev/null 2> /dev/null
+ then
+ echo
+ echo 'WARNING: Building from an unreleased source tree without prebuilt helpfile.'
+ echo 'Install xmlto and xsltproc if you want online help to work.'
+ else
+ echo "DOC=1" >> Makefile.settings
+ fi
+
+ if [ "$skype" = "1" -o "$skype" = "plugin" ]; then
+ # skype also needs asciidoc
+ if ! type a2x > /dev/null 2> /dev/null; then
+ echo
+ echo 'WARNING: The skyped man page requires asciidoc. It will not be generated.'
+ else
+ echo "ASCIIDOC=1" >> Makefile.settings
+ fi
+ fi
fi
REAL_BITLBEE_VERSION=`grep '^#define BITLBEE_VERSION ' $srcdir/bitlbee.h | sed 's/.*\"\(.*\)\".*/\1/'`
diff --git a/doc/Makefile b/doc/Makefile
index 1e32dbe4..69471d32 100644
--- a/doc/Makefile
+++ b/doc/Makefile
@@ -5,13 +5,13 @@ endif
all:
# Only build the docs if this is a git tree
- -test ! '(' -d ../.git -o -d ../.bzr ')' || $(MAKE) -C user-guide
+ test ! '(' -d ../.git -o -d ../.bzr ')' || $(MAKE) -C user-guide
install:
mkdir -p $(DESTDIR)$(MANDIR)/man8/ $(DESTDIR)$(MANDIR)/man5/
$(INSTALL) -m 0644 $(_SRCDIR_)bitlbee.8 $(DESTDIR)$(MANDIR)/man8/
$(INSTALL) -m 0644 $(_SRCDIR_)bitlbee.conf.5 $(DESTDIR)$(MANDIR)/man5/
- -$(MAKE) -C user-guide $@
+ $(MAKE) -C user-guide $@
uninstall:
rm -f $(DESTDIR)$(MANDIR)/man8/bitlbee.8*
diff --git a/protocols/skype/Makefile b/protocols/skype/Makefile
index 6548bfb9..b0ad2237 100644
--- a/protocols/skype/Makefile
+++ b/protocols/skype/Makefile
@@ -5,9 +5,9 @@ endif
DATE := $(shell date +%Y-%m-%d)
INSTALL = install
-ASCIIDOC = yes
-ifeq ($(ASCIIDOC),yes)
+
+ifdef ASCIIDOC
MANPAGES = skyped.1
else
MANPAGES =
@@ -28,7 +28,7 @@ test: all
doc: $(MANPAGES)
install-doc: doc
-ifeq ($(ASCIIDOC),yes)
+ifdef ASCIIDOC
$(INSTALL) -d $(DESTDIR)$(MANDIR)/man1
$(INSTALL) -m644 $(MANPAGES) $(DESTDIR)$(MANDIR)/man1
endif