2015-06-21 19:24:03 +00:00
|
|
|
SRCDIR = ../src
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -fr me.nlohmann.json.docset html
|
|
|
|
|
|
|
|
|
|
|
|
##########################################################################
|
|
|
|
# example files
|
|
|
|
##########################################################################
|
|
|
|
|
|
|
|
# where are the example cpp files
|
|
|
|
EXAMPLES = $(wildcard examples/*.cpp)
|
|
|
|
|
|
|
|
# create output from a stand-alone example file
|
|
|
|
%.output: %.cpp
|
|
|
|
make $(<:.cpp=) CPPFLAGS="-I $(SRCDIR)" CXXFLAGS="-std=c++11"
|
|
|
|
./$(<:.cpp=) > $@
|
|
|
|
rm $(<:.cpp=)
|
|
|
|
|
|
|
|
# compare created output with current output of the example files
|
|
|
|
%.test: %.cpp
|
|
|
|
make $(<:.cpp=) CPPFLAGS="-I $(SRCDIR)" CXXFLAGS="-std=c++11"
|
|
|
|
./$(<:.cpp=) > $@
|
|
|
|
diff $@ $(<:.cpp=.output)
|
|
|
|
rm $(<:.cpp=) $@
|
|
|
|
|
|
|
|
# create output from all stand-alone example files
|
|
|
|
create_output: $(EXAMPLES:.cpp=.output)
|
|
|
|
|
|
|
|
# check output of all stand-alone example files
|
|
|
|
check_output: $(EXAMPLES:.cpp=.test)
|
|
|
|
|
|
|
|
|
|
|
|
##########################################################################
|
|
|
|
# Doxygen HTML documentation
|
|
|
|
##########################################################################
|
|
|
|
|
|
|
|
# create Doxygen documentation
|
|
|
|
doxygen: create_output
|
|
|
|
doxygen
|
|
|
|
gsed -i 's@< ObjectType, ArrayType, StringType, BooleanType, NumberIntegerType, NumberFloatType, AllocatorType >@@g' html/*.html
|
|
|
|
gsed -i 's@< ObjectType, ArrayType, StringType, BooleanType, NumberIntegerType, NumberFloatType, AllocatorType >@@g' html/*.html
|
|
|
|
|
2015-06-21 19:51:23 +00:00
|
|
|
upload: doxygen
|
|
|
|
cd html ; ../git-update-ghpages nlohmann/json
|
|
|
|
rm -fr html
|
|
|
|
open http://nlohmann.github.io/json/
|
|
|
|
|
2015-06-21 19:24:03 +00:00
|
|
|
|
|
|
|
##########################################################################
|
|
|
|
# docset
|
|
|
|
##########################################################################
|
|
|
|
|
|
|
|
# create docset for Dash
|
|
|
|
docset: create_output
|
|
|
|
cp Doxyfile Doxyfile_docset
|
|
|
|
gsed -i 's/DISABLE_INDEX = NO/DISABLE_INDEX = YES/' Doxyfile_docset
|
|
|
|
gsed -i 's/SEARCHENGINE = YES/SEARCHENGINE = NO/' Doxyfile_docset
|
|
|
|
gsed -i 's/GENERATE_TREEVIEW = YES/GENERATE_TREEVIEW = NO/' Doxyfile_docset
|
|
|
|
gsed -i 's/BINARY_TOC = YES/BINARY_TOC = NO/' Doxyfile_docset
|
|
|
|
gsed -i 's@HTML_EXTRA_STYLESHEET = css/mylayout.css@HTML_EXTRA_STYLESHEET = css/mylayout_docset.css@' Doxyfile_docset
|
|
|
|
rm -fr html *.docset
|
|
|
|
doxygen Doxyfile_docset
|
|
|
|
gsed -i 's@< ObjectType, ArrayType, StringType, BooleanType, NumberIntegerType, NumberFloatType, AllocatorType >@@g' html/*.html
|
|
|
|
gsed -i 's@< ObjectType, ArrayType, StringType, BooleanType, NumberIntegerType, NumberFloatType, AllocatorType >@@g' html/*.html
|
|
|
|
make -C html
|
|
|
|
mv html/*.docset .
|
|
|
|
gsed -i 's@<string>doxygen</string>@<string>json</string>@' me.nlohmann.json.docset/Contents/Info.plist
|
|
|
|
rm -fr Doxyfile_docset html
|