THRIFT-1336 thrift: added server and processor test code
Patch: Dave Watson
- rework made by roger

git-svn-id: https://svn.apache.org/repos/asf/thrift/trunk@1336544 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/lib/cpp/Makefile.am b/lib/cpp/Makefile.am
old mode 100644
new mode 100755
index 21480ab..21f70dd
--- a/lib/cpp/Makefile.am
+++ b/lib/cpp/Makefile.am
@@ -208,7 +208,8 @@
                   src/thrift/qt/TQTcpServer.h
 
 
-noinst_PROGRAMS = concurrency_test
+noinst_PROGRAMS = concurrency_test \
+                  processor_test
 
 concurrency_test_SOURCES = \
                            src/thrift/concurrency/test/Tests.cpp \
@@ -218,6 +219,41 @@
 
 concurrency_test_LDADD = libthrift.la
 
+processor_test_SOURCES = src/thrift/processor/test/ProcessorTest.cpp \
+                        src/thrift/processor/test/EventLog.cpp \
+                        src/thrift/processor/test/ServerThread.cpp \
+                        src/thrift/processor/test/EventLog.h \
+                        src/thrift/processor/test/Handlers.h \
+                        src/thrift/processor/test/ServerThread.h \
+                        src/thrift/processor/test/gen-cpp/ChildService.h
+
+processor_test_LDADD = libprocessortest.la \
+                       libthrift.la \
+                       libthriftnb.la \
+                       $(BOOST_LDFLAGS) \
+                       -levent \
+                       $(BOOST_ROOT_PATH)/lib/libboost_unit_test_framework.a
+
+check_PROGRAMS = \
+       concurrency_test \
+       processor_test
+
+TESTS = \
+       $(check_PROGRAMS)
+
+noinst_LTLIBRARIES = libprocessortest.la
+
+THRIFT = $(top_builddir)/compiler/cpp/thrift
+
+gen-cpp/ChildService.cpp: $(top_srcdir)/lib/cpp/src/thrift/processor/test/proc.thrift
+	$(THRIFT) --gen cpp:templates,cob_style $<
+
+nodist_libprocessortest_la_SOURCES = \
+       gen-cpp/ChildService.h \
+       gen-cpp/ChildService.cpp \
+       gen-cpp/ParentService.h \
+       gen-cpp/ParentService.cpp
+
 WINDOWS_DIST = \
              README_WINDOWS \
              src/windows \