# -*- Mode: Makefile -*-
#
# Makefile.am - automake file for Raptor docs
#
# Copyright (C) 2000-2006, David Beckett http://purl.org/net/dajobe/
# Copyright (C) 2000-2005, University of Bristol, UK http://www.bristol.ac.uk/
# 
# This package is Free Software and part of Redland http://librdf.org/
# 
# It is licensed under the following three licenses as alternatives:
#   1. GNU Lesser General Public License (LGPL) V2.1 or any newer version
#   2. GNU General Public License (GPL) V2 or any newer version
#   3. Apache License, V2.0 or any newer version
# 
# You may not use this file except in compliance with at least one of
# the above three licenses.
# 
# See LICENSE.html or LICENSE.txt at the top of this package for the
# complete terms and further detail along with the license texts for
# the licenses in COPYING.LIB, COPYING and LICENSE-2.0.txt respectively.
# 
# 


# The name of the module.
DOC_MODULE=raptor

# The top-level SGML file.
DOC_MAIN_SGML_FILE=raptor-docs.xml

# Extra options to supply to gtkdoc-scan
SCAN_OPTIONS=

# The directory containing the source code. Relative to $(srcdir)
DOC_SOURCE_DIR=../src

# Used for dependencies
HFILE_GLOB=$(top_srcdir)/src/raptor.h
CFILE_GLOB=$(top_srcdir)/src/raptor_*.c

IGNORE_CFILES= \
n3_lexer.c \
n3_parser.c \
raptor_nfc_test.c \
raptor_rss_common.c \
raptor_xsd.c \
turtle_lexer.c \
turtle_parser.c \
turtle_common.c \
parsedate.c \
strcasecmp.c

# Headers to ignore
IGNORE_HFILES= \
	n3_common.h \
	n3_lexer.h \
	n3_parser.h \
	parsedate.h \
	raptor_config.h \
	raptor_internal.h \
	raptor_nfc.h \
	raptor_rss.h \
	turtle_common.h \
	turtle_lexer.h \
	turtle_parser.h \
	win32_raptor_config.h

# CFLAGS and LDFLAGS for compiling scan program. Only needed
# if $(DOC_MODULE).types is non-empty.
AM_CPPFLAGS =
GTKDOC_LIBS =

# Extra options to supply to gtkdoc-mkdb
MKDB_OPTIONS=--sgml-mode --output-format=xml --ignore-files="$(IGNORE_CFILES)"

# Extra options to supply to gtkdoc-mktmpl
MKTMPL_OPTIONS=

# Non-autogenerated (XML, other) files to be included in $(DOC_MAIN_SGML_FILE)
content_files = \
	raptor-parsers.xml \
	raptor-serializers.xml \
	raptor-tutorial-intro.xml \
	raptor-tutorial-querying-functionality.xml \
	raptor-tutorial-parsing.xml \
	raptor-tutorial-serializing.xml \
	version.xml \
	rdfprint.c \
	rdfcat.c \
	rdfserialize.c

# Images to copy into HTML directory
HTML_IMAGES =

# Extra options to supply to gtkdoc-fixref
FIXXREF_OPTIONS=

include $(top_srcdir)/gtk-doc.make

man_MANS = libraptor.3

EXTRA_DIST+= \
libraptor.html \
$(man_MANS) \
version.xml.in


if MAINTAINER_MODE
libraptor.html: $(srcdir)/libraptor.3 $(srcdir)/../fix-groff-xhtml
	-groff -man -Thtml -P-l $< | tidy -asxml -wrap 1000 2>/dev/null | perl $(srcdir)/../fix-groff-xhtml $@

rdfcat.c: $(srcdir)/../examples/rdfcat.c
	$(install_sh_DATA) $? $@

rdfprint.c: $(srcdir)/../examples/rdfprint.c
	$(install_sh_DATA) $? $@

rdfserialize.c: $(srcdir)/../examples/rdfserialize.c
	$(install_sh_DATA) $? $@

raptor-tutorial-parsing.xml: rdfcat.c

raptor-tutorial-serializing.xml: rdfprint.c rdfserialize.c

endif
