Commit 59e9b83f authored by Thomas Moulard's avatar Thomas Moulard
Browse files

Factorize asciidoc rules.



	Search for asciidoc, source-highlight.
	Asciidoc syntax does not seem to be retrocompatible, so
	for now check that version is at least 8.2.5 (Fedora 11).

	* bootstrap: Check submodule sanity.
	* build-aux: Synchronize.
	* configure.ac: Search for asciidoc manually.
	* doc/Makefile.am: Use factorized asciidoc rules.
Signed-off-by: default avatarThomas Moulard <thomas.moulard@gmail.com>
parent 890e5871
2010-01-11 Thomas Moulard <thomas.moulard@gmail.com>
Factorize asciidoc rules.
Search for asciidoc, source-highlight.
Asciidoc syntax does not seem to be retrocompatible, so
for now check that version is at least 8.2.5 (Fedora 11).
* bootstrap: Check submodule sanity.
* build-aux: Synchronize.
* configure.ac: Search for asciidoc manually.
* doc/Makefile.am: Use factorized asciidoc rules.
2010-01-11 Thomas Moulard <thomas.moulard@gmail.com> 2010-01-11 Thomas Moulard <thomas.moulard@gmail.com>
Distribute and install missing files. Distribute and install missing files.
......
#! /bin/sh #! /bin/sh
set -e
# Print an error message and exit. # Print an error message and exit.
die () die ()
{ {
...@@ -7,8 +9,51 @@ die () ...@@ -7,8 +9,51 @@ die ()
exit 2 exit 2
} }
# Properly explain how to set up a RobOptim working directory and exit.
die_noroboptimalias ()
{
echo >&2 "To properly finish setting up your working directory,"
echo >&2 "you need to define how RobOptim should connect to SourceForge."
echo >&2 ""
echo >&2 "If you only need read-access (which is usually what one wants):"
echo >&2 "echo '[url \"git://roboptim.git.sourceforge.net/gitroot/roboptim/\"]"
echo >&2 " insteadOf = roboptim:' >> ~/.gitconfig"
echo >&2 ""
die "no \`\`roboptim:'' alias in your git configuration."
}
# Check that git version is newer enough.
check_git_version ()
{
version=`git --version | sed 's/^git version \([0-9]\.[0-9]\.[0-9]\).*$/\1/'`
if test x"$version" = x; then
die "failed to parse git version"
fi
for i in 1 2 3; do
wantedversion=`echo "$1" | cut -d'.' -f$i`
gitversion=`echo "$version" | cut -d'.' -f$i`
if test $gitversion -lt $wantedversion; then
die "git version is too old (version $1 at least is required)"
fi
if test $gitversion -gt $wantedversion; then
return
fi
done
}
# Make sure that the submodule are retrieved. # Make sure that the submodule are retrieved.
if test -d ".git"; then if test -d ".git"; then
# Url rewriting has been introduced in git 1.5.5.
check_git_version "1.5.5"
if test x`git config -l | grep 'url\..*\.insteadof=roboptim:'` = x; then
die_noroboptimalias
fi
git submodule init git submodule init
git submodule update git submodule update
fi fi
......
build-aux @ fc8dffa4
Subproject commit 6d7fc1db4a946e2b82334052de97d934a2fb0b10 Subproject commit fc8dffa45c182ab7198d0905c83a4bc3866ea6a4
...@@ -26,11 +26,13 @@ AC_CONFIG_MACRO_DIR([build-aux]) ...@@ -26,11 +26,13 @@ AC_CONFIG_MACRO_DIR([build-aux])
# Search for install. # Search for install.
AC_PROG_INSTALL AC_PROG_INSTALL
# Check for asciidoc.
JRL_PROG_ASCIIDOC([ASCIIDOC], [8.2.5])
# Search for pkg-config. # Search for pkg-config.
PKG_PROG_PKG_CONFIG PKG_PROG_PKG_CONFIG
# Macro that search for a package's documentation and # Macro that search for a package's documentation and
# generate the corresponding link to the ``main.html'' file # generate the corresponding link to the ``main.html'' file
# of the Doxygen documentation. # of the Doxygen documentation.
......
include $(top_srcdir)/build-aux/init.mk include $(top_srcdir)/build-aux/init.mk
include $(top_srcdir)/build-aux/asciidoc.mk
EXTRA_DIST += \ EXTRA_DIST += \
$(top_srcdir)/scripts/packageDep \ $(top_srcdir)/scripts/packageDep \
...@@ -41,12 +42,6 @@ EXTRA_DIST += $(DOC_EXTRA) \ ...@@ -41,12 +42,6 @@ EXTRA_DIST += $(DOC_EXTRA) \
graph-dependency.html.in \ graph-dependency.html.in \
cmaxp.html cmaxp.html
# Asciidoc pages.
SUFFIXES += .html
.txt.html:
asciidoc -a icons -o $@ $<
# Distribute all files (HTML, images, videos...). # Distribute all files (HTML, images, videos...).
DOC_EXTRA = \ DOC_EXTRA = \
custom.css \ custom.css \
...@@ -120,4 +115,3 @@ nobase_html_DATA = \ ...@@ -120,4 +115,3 @@ nobase_html_DATA = \
tree.html tree.html
nobase_html_DATA += $(MISSING_FILES) $(DOC_EXTRA) nobase_html_DATA += $(MISSING_FILES) $(DOC_EXTRA)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment