Add scripts for Travis CI
git-svn-id: http://pugixml.googlecode.com/svn/trunk@969 99668b35-9821-0410-8761-19e4c4f06640
This commit is contained in:
parent
0456f5deea
commit
09647e2b29
5
.travis.yml
Normal file
5
.travis.yml
Normal file
@ -0,0 +1,5 @@
|
||||
language: cpp
|
||||
compiler:
|
||||
- clang
|
||||
- gcc
|
||||
script: make -f tests/Makefile.travis test
|
||||
24
tests/Makefile.travis
Normal file
24
tests/Makefile.travis
Normal file
@ -0,0 +1,24 @@
|
||||
CXXFLAGS=-c -Wall -Wextra -Werror -pedantic
|
||||
|
||||
BUILD=build/travis
|
||||
|
||||
SOURCES=src/pugixml.cpp $(wildcard tests/*.cpp)
|
||||
OBJECTS=$(SOURCES:%=$(BUILD)/%.o)
|
||||
EXECUTABLE=$(BUILD)/test
|
||||
|
||||
all: $(EXECUTABLE)
|
||||
|
||||
test: $(EXECUTABLE)
|
||||
./$(EXECUTABLE)
|
||||
|
||||
$(EXECUTABLE): $(OBJECTS)
|
||||
$(CXX) $(OBJECTS) $(LDFLAGS) -o $@
|
||||
|
||||
$(BUILD)/%.cpp.o: %.cpp
|
||||
mkdir -p $(dir $@)
|
||||
$(CXX) $(CXXFLAGS) $< -o $@
|
||||
|
||||
clean:
|
||||
rm -rf $(BUILD)
|
||||
|
||||
.PHONY: all test clean
|
||||
Loading…
Reference in New Issue
Block a user