1
0
mirror of https://github.com/mfontanini/libtins synced 2026-01-26 20:01:35 +01:00

Added test suite makefile.

This commit is contained in:
Matias Fontanini
2011-09-15 10:22:15 -03:00
parent 46c9a21a72
commit 4c5fea0a5f
3 changed files with 4148 additions and 0 deletions

23
tests/Makefile.in Normal file
View File

@@ -0,0 +1,23 @@
CXX=@CXX@
CFLAGS=-c -Wall @CFLAGS@ -DTINS_VERSION=@PACKAGE_VERSION@
LDFLAGS=-lpcap -lgtest -lpthread
SOURCES=$(wildcard src/*.cpp ../src/*.cpp)
OBJECTS=$(SOURCES:.cpp=.o)
INCLUDE=-Iinclude/ -I../include
EXECUTABLE=test
all: $(SOURCES) $(EXECUTABLE)
compile: $(OBJECTS)
recompile: clean all
$(EXECUTABLE): $(OBJECTS)
$(CXX) $(OBJECTS) $(LDFLAGS) -o $@
.cpp.o:
$(CXX) $(CFLAGS) $(INCLUDE) $< -o $@
clean:
rm $(OBJECTS) $(EXECUTABLE)

4113
tests/configure vendored Executable file

File diff suppressed because it is too large Load Diff

12
tests/configure.ac Normal file
View File

@@ -0,0 +1,12 @@
AC_INIT(myconfig, 0.1)
AC_PROG_CXX()
AC_LANG(C++)
CFLAGS="-DDEBUG -g"
AC_CHECK_HEADERS([pcap.h gtest/gtest.h])
AC_CHECK_LIB(pcap, pcap_loop, [], [AC_MSG_ERROR([pcap library is needed!])])
#AC_CHECK_LIB([gtest_main], [main], [], [AC_MSG_ERROR([gtest library is needed!])])
AC_SUBST(CFLAGS)
AC_OUTPUT(Makefile)