diff options
author | Arseny Kapoulkine <arseny.kapoulkine@gmail.com> | 2015-04-10 22:26:57 -0700 |
---|---|---|
committer | Arseny Kapoulkine <arseny.kapoulkine@gmail.com> | 2015-04-10 22:26:57 -0700 |
commit | e90d2ac8ba44fbcf4d5702643f708f2c86bde42e (patch) | |
tree | a52fe8e4efee8176da169998c203c1a93f6a6ff1 /Makefile | |
parent | 6457f0941204a79ec5ba359a12aa00bf06f0e621 (diff) | |
parent | 405fefc8777c55900a4e44561b545a9abb5276ba (diff) |
Merge branch 'master' into compact
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 21 |
1 files changed, 19 insertions, 2 deletions
@@ -1,11 +1,17 @@ +.SUFFIXES: +MAKEFLAGS+=-r + config=debug defines=standard BUILD=build/make-$(CXX)-$(config)-$(defines) -SOURCES=src/pugixml.cpp tests/main.cpp tests/allocator.cpp tests/test.cpp tests/writer_string.cpp $(wildcard tests/test_*.cpp) +SOURCES=src/pugixml.cpp $(filter-out tests/fuzz_%,$(wildcard tests/*.cpp)) EXECUTABLE=$(BUILD)/test +VERSION=$(shell sed -n 's/.*version \(.*\).*/\1/p' src/pugiconfig.hpp) +RELEASE=$(shell git ls-files src docs/*.html docs/*.css docs/samples docs/images scripts contrib readme.txt) + CXXFLAGS=-g -Wall -Wextra -Werror -pedantic LDFLAGS= @@ -47,6 +53,13 @@ fuzz: clean: rm -rf $(BUILD) +release: build/pugixml-$(VERSION).tar.gz build/pugixml-$(VERSION).zip + +docs: docs/quickstart.html docs/manual.html + +build/pugixml-%: .FORCE | $(RELEASE) + perl tests/archive.pl $@ $| + $(EXECUTABLE): $(OBJECTS) $(CXX) $(OBJECTS) $(LDFLAGS) -o $@ @@ -56,4 +69,8 @@ $(BUILD)/%.o: % -include $(OBJECTS:.o=.d) -.PHONY: all test clean +.SECONDEXPANSION: +docs/%.html: docs/%.adoc $$(shell sed -n 's/include\:\:\(.*\)\[.*/docs\/\1/p' docs/%.adoc) + asciidoctor -b html5 -a version=$(VERSION) $< -o $@ + +.PHONY: all test clean release .FORCE |