Add info file creation into tcc build process

Add info file creation in tcc Makefile
This commit is contained in:
Thomas Preud'homme 2010-09-10 21:19:01 +02:00
parent 36f74e46b4
commit 3f829d11ff
2 changed files with 17 additions and 3 deletions

View File

@ -131,7 +131,7 @@ LIBTCCLIBS+=tcc1.def
endif
endif
all: $(PROGS) $(LIBTCC1) $(BCHECK_O) $(LIBTCCLIBS) tcc-doc.html tcc.1 libtcc_test$(EXESUF)
all: $(PROGS) $(LIBTCC1) $(BCHECK_O) $(LIBTCCLIBS) tcc-doc.html tcc.1 tcc-doc.info libtcc_test$(EXESUF)
# Host Tiny C Compiler
tcc$(EXESUF): tcc.o $(LIBTCCB)
@ -245,11 +245,13 @@ TCC_INCLUDES = stdarg.h stddef.h stdbool.h float.h varargs.h tcclib.h
INSTALL=install
ifndef CONFIG_WIN32
install: $(PROGS) $(LIBTCC1) $(BCHECK_O) $(LIBTCCLIBS) tcc.1 tcc-doc.html
install: $(PROGS) $(LIBTCC1) $(BCHECK_O) $(LIBTCCLIBS) tcc.1 tcc-doc.info tcc-doc.html
mkdir -p "$(bindir)"
$(INSTALL) -s -m755 $(PROGS) "$(bindir)"
mkdir -p "$(mandir)/man1"
$(INSTALL) tcc.1 "$(mandir)/man1"
mkdir -p $(infodir)
$(INSTALL) tcc-doc.info "$(infodir)"
mkdir -p "$(tccdir)"
mkdir -p "$(tccdir)/include"
ifneq ($(LIBTCC1),)
@ -315,6 +317,9 @@ tcc.1: tcc-doc.texi
-./texi2pod.pl $< tcc.pod
-pod2man --section=1 --center=" " --release=" " tcc.pod > $@
tcc-doc.info: tcc-doc.texi
makeinfo tcc-doc.texi
# tar release (use 'make -k tar' on a checkouted tree)
TCC-VERSION=tcc-$(shell cat VERSION)
tar:
@ -332,7 +337,7 @@ clean:
$(MAKE) -C tests $@
distclean: clean
rm -vf config.h config.mak config.texi tcc.1 tcc-doc.html
rm -vf config.h config.mak config.texi tcc.1 tcc-doc.info tcc-doc.html
config.mak:
@echo Running configure ...

9
configure vendored
View File

@ -29,6 +29,7 @@ libdir=""
tccdir=""
includedir=""
mandir=""
infodir=""
sysroot=""
cross_prefix=""
cc="gcc"
@ -108,6 +109,8 @@ for opt do
;;
--mandir=*) mandir=`echo $opt | cut -d '=' -f 2`
;;
--infodir=*) infodir=`echo $opt | cut -d '=' -f 2`
;;
--sysroot=*) sysroot=`echo $opt | cut -d '=' -f 2`
;;
--source-path=*) source_path=`echo $opt | cut -d '=' -f 2`
@ -227,6 +230,7 @@ echo " --bindir=DIR user executables in DIR [EPREFIX/bin]"
echo " --libdir=DIR object code libraries in DIR [EPREFIX/lib]"
echo " --includedir=DIR C header files in DIR [PREFIX/include]"
echo " --mandir=DIR man documentation in DIR [PREFIX/man]"
echo " --infodir=DIR info documentation in DIR [PREFIX/info]"
echo " --enable-cross build cross compilers"
echo ""
echo "Advanced options (experts only):"
@ -275,6 +279,9 @@ fi
if test x"$mandir" = x""; then
mandir="${prefix}/man"
fi
if test x"$infodir" = x""; then
infodir="${prefix}/info"
fi
if test x"$includedir" = x""; then
includedir="${prefix}/include"
fi
@ -284,6 +291,7 @@ echo "TinyCC directory $tccdir"
echo "Library directory $libdir"
echo "Include directory $includedir"
echo "Manual directory $mandir"
echo "Info directory $infodir"
echo "Doc directory $docdir"
echo "Target root prefix $sysroot"
echo "Source path $source_path"
@ -306,6 +314,7 @@ echo "libdir=\$(DESTDIR)$libdir" >> config.mak
echo "ln_libdir=$libdir" >> config.mak
echo "includedir=\$(DESTDIR)$includedir" >> config.mak
echo "mandir=\$(DESTDIR)$mandir" >> config.mak
echo "infodir=$infodir" >> config.mak
echo "docdir=\$(DESTDIR)$docdir" >> config.mak
echo "#define CONFIG_SYSROOT \"$sysroot\"" >> $TMPH