From 3c5d9f1866d127dc7ab43347f3a5e524d49c08c1 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Wed, 8 Oct 2014 23:53:30 +0200 Subject: added mandir handling to configure --- src/configure | 38 +++++++++++++++++++++++++++++++++++--- 1 file changed, 35 insertions(+), 3 deletions(-) diff --git a/src/configure b/src/configure index 73a1de7..0e1f887 100755 --- a/src/configure +++ b/src/configure @@ -41,12 +41,16 @@ USE_CLANG=0 PREFIX='/usr/local' BINDIR='' +MANDIR='' +INSTALLMANPAGE=1 print_usage() { echo "configure --help print this" echo " --target= build target i.e. Linux (default: autodetect)" echo " --prefix= the installation prefix (default: /usr/local)" echo " --bindir= the path to the bin directory (default: $PREFIX/bin)" + echo " --mandir= the path to the system man pages (default: $PREFIX/share/man)" + echo " --no-manpage dont't install manpages" echo " --use-clang use clang/llvm as compiler/linker" } @@ -62,6 +66,12 @@ do --bindir=*) BINDIR=${arg#--bindir=} ;; + --mandir=*) + MANDIR=${arg#--mandir=} + ;; + --no-manpage) + INSTALLMANPAGE=0 + ;; --use-clang) USE_CLANG=1 ;; @@ -101,7 +111,7 @@ CFLAGS="$CFLAGS $(pkg-config --cflags gstreamer-1.0 gthread-2.0 gio-2.0)" LDFLAGS="$LDFLAGS $(pkg-config --libs gstreamer-1.0 gthread-2.0 gio-2.0)" rm -f include.mk -rm -f config.h +rm -f config-*.h case $TARGET in Linux) ;; @@ -119,6 +129,10 @@ if [ -z "$BINDIR" ]; then BINDIR=$PREFIX/bin fi +if [ -z "$MANDIR" ]; then + MANDIR=$PREFIX/share/man +fi + cat > include.mk <> include.mk + echo "installing manpages" +else + echo "not installing manpages" +fi + VERSION=`cat ../version` if which git >/dev/null; then GIT_HASH=`git rev-parse HEAD 2> /dev/null` @@ -165,8 +186,6 @@ cat > config-rtp.h < config-launch.h < config-launch.h <> config-launch.h + echo "#define MANDIR \"$MANDIR\"" >> config-rtp.h +fi + +cat >> config-rtp.h <> config-launch.h <