Commit ea177aef authored by Matthias Braun's avatar Matthias Braun
Browse files

add documentation make target, fix docu bugs

parent fbe9e7db
......@@ -515,7 +515,7 @@ LAYOUT_FILE =
# The QUIET tag can be used to turn on/off the messages that are generated
# by doxygen. Possible values are YES and NO. If left blank NO is used.
QUIET = NO
QUIET = YES
# The WARNINGS tag can be used to turn on/off the warning messages that are
# generated by doxygen. Possible values are YES and NO. If left blank
......@@ -1302,7 +1302,7 @@ TAGFILES =
# When a file name is specified after GENERATE_TAGFILE, doxygen will create
# a tag file that is based on the input files it reads.
GENERATE_TAGFILE = libfirm.tag
GENERATE_TAGFILE = firm-doc/libfirm.tag
# If the ALLEXTERNALS tag is set to YES all external classes will be listed
# in the class index. If set to NO only the inherited external classes
......
......@@ -19,6 +19,7 @@ builddir ?= $(top_builddir)/$(variant)
Q ?= @
CC ?= cc
DOXYGEN ?= doxygen
LINK ?= $(CC)
AR ?= ar
DLLEXT ?= .so
......@@ -176,9 +177,23 @@ $(builddir)/%.o: %.c $(IR_SPEC_GENERATED_FILES) config.h
@echo CC $@
$(Q)$(CC) $(CFLAGS) $(CPPFLAGS) $(libfirm_CPPFLAGS) -MMD -c -o $@ $<
firm-doc/libfirm.tag: $(IR_SPEC_GENERATED_FILES) Doxyfile $(wildcard include/libfirm/*.h) $(wildcard include/libfirm/adt/*.h)
@echo Doxygen
$(Q)$(DOXYGEN)
DOCU_GENERATOR := scripts/gen_docu.py
firm-doc/html/nodes.html: firm-doc/libfirm.tag $(DOCU_GENERATOR) $(IR_SPEC) scripts/spec_util.py scripts/style.css
@echo gen_docu.py
$(Q)$(DOCU_GENERATOR) firm-doc/libfirm.tag "" $@
$(Q)cp scripts/style.css firm-doc/html
.PHONY: documentation
documentation: firm-doc/libfirm.tag firm-doc/html/nodes.html
.PHONY: clean
clean:
@echo CLEAN
$(Q)rm -f $(libfirm_OBJECTS)
$(Q)rm -f $(libfirm_TARGET)
$(Q)rm -f $(shell find ir/ -name "gen_*.[ch]")
$(Q)rm -rf firm-docu
......@@ -162,7 +162,7 @@ FIRM_API void all_optimizations_off(void);
/** @} */
/** @ingroup irverify
* @defgroup Flags
* @defgroup irverify_flags Flags
* Enable/Disable automatic correctness tests
* @{
*/
......
......@@ -64,10 +64,9 @@ typedef enum ir_mode_arithmetic {
* Creates a new mode.
*
* @param name the name of the mode to be created
* @param sort the ir_mode_sort of the mode to be created
* @param arithmetic arithmetic operations possible with a mode
* @param bit_size number of bits this mode allocate
* @param sign non-zero if this is a signed mode
* @param arithmetic arithmetic operations possible with a mode
* @param modulo_shift Is ignored for modes other than integer.
*
* This function constructs a new mode given by the parameters.
......
......@@ -1093,7 +1093,7 @@ typedef ir_entity *(*compilerlib_entity_creator_t)(ident *id, ir_type *mt);
*
* @param cb the new compilerlib entity creation callback
*/
FIRM_API void set_compilerlib_entity_creator(compilerlib_entity_creator_t c);
FIRM_API void set_compilerlib_entity_creator(compilerlib_entity_creator_t cb);
/**
* Get the compilerlib entity creation callback.
......
......@@ -26,7 +26,7 @@ def format_doxygrouplink(string, link=None):
if len(anchorfile) == 0:
return string
global linkbase
return "<a href=\"%s/%s\">%s</a>" % (linkbase, anchorfile[0], string)
return "<a href=\"%s%s\">%s</a>" % (linkbase, anchorfile[0], string)
def format_doxylink(string, link=None):
global tags
......@@ -43,7 +43,7 @@ def format_doxylink(string, link=None):
if len(anchorfile) == 0 or len(anchor) == 0:
return string
global linkbase
return "<a href=\"%s/%s#%s\">%s</a>" % (linkbase, anchorfile[0], anchor[0], string)
return "<a href=\"%s%s#%s\">%s</a>" % (linkbase, anchorfile[0], anchor[0], string)
def format_docutils(string):
writer = docutils.writers.html4css1.Writer()
......@@ -153,6 +153,8 @@ def main(argv):
tagfile = open(argv[-3], "r")
global linkbase
linkbase = argv[-2]
if linkbase != "":
linkbase += "/"
try:
from lxml import etree
tags = etree.parse(tagfile)
......
Markdown is supported
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