test/Makefile
author Volker Birk <vb@pep-project.org>
Tue, 17 May 2016 20:56:41 +0200
changeset 645 0bb373719dce
parent 458 72b4da3d4e2d
child 699 5665c57e9965
permissions -rw-r--r--
converting KeyList
     1 include ../Makefile.conf
     2 
     3 CC?=g++ -std=gnu++11 -pthread
     4 CXX?=g++ -std=gnu++11 -pthread
     5 LD?=$(CXX)
     6 LDFLAGS?=-L$(HOME)/lib
     7 LDLIBS?=-letpan -lpEpEngine -lstdc++ -L../asn.1 -lasn1
     8 CXXFLAGS?=-g -O0 -I../src -I../asn.1
     9 # CXXFLAGS=-O3 -DNDEBUG
    10 
    11 ifeq ("$(OPENPGP)","NETPGP")
    12 	LDLIBS+= -lnetpgp
    13 endif
    14 
    15 TARGET=pEpEngineTest
    16 
    17 UNIT_TESTS_SOURCE=$(wildcard *_test.cc)
    18 UNIT_TESTS=$(subst .cc,,$(UNIT_TESTS_SOURCE))
    19 
    20 all: $(TARGET) $(UNIT_TESTS)
    21 
    22 .PHONY: clean
    23 
    24 clean:
    25 	rm -f *.o $(TARGET) *.a *~ $(UNIT_TESTS) pep_Dokument_Titel.pdf msg4.asc
    26 	rm -Rf *.dSYM
    27 
    28 test: pEpEngineTest
    29 	LD_LIBRARY_PATH=~/lib:../src ./pEpEngineTest
    30 
    31 unit_tests: $(UNIT_TESTS)
    32 	for t in ./*_test ; do \
    33 		if LD_LIBRARY_PATH=~/lib:../src $$t ; then true; else break; fi \
    34 	done
    35 
    36 install:
    37 	make -C .. install