Commit c58d1f93 authored by anilsaharan's avatar anilsaharan

Modified for the avoid conditional compilation problems


git-svn-id: http://svn.code.sf.net/p/cunit/code/trunk@90 f00e6729-6848-4c17-8bfb-678c97c00071
parent 52c1582a
......@@ -10,20 +10,22 @@ FRAMEWORK_INCLUDES = CUError.h CUnit.h MyMem.h TestDB.h TestRun.h Util.h
INCLUDE_FILES = ${FRAMEWORK_INCLUDES}
if ENABLE_BASIC
INCLUDE_FILES += $(BASIC_INCLUDES)
BASIC_INCLUDE_FILES = $(BASIC_INCLUDES)
endif
if ENABLE_CONSOLE
INCLUDE_FILES += $(CONSOLE_INCLUDES)
CONSOLE_INCLUDE_FILES = $(CONSOLE_INCLUDES)
endif
if ENABLE_AUTOMATED
INCLUDE_FILES += $(AUTOMATED_INCLUDES)
AUTOMATED_INCLUDE_FILES = $(AUTOMATED_INCLUDES)
endif
if ENABLE_CURSES
INCLUDE_FILES += $(CURSES_INCLUDES)
CURSES_INCLUDE_FILES = $(CURSES_INCLUDES)
endif
INCLUDE_FILES += $(BASIC_INCLUDE_FILES) $(CONSOLE_INCLUDE_FILES) $(AUTOMATED_INCLUDE_FILES) $(CURSES_INCLUDE_FILES)
CUnitInclude_HEADERS = ${INCLUDE_FILES}
......@@ -8,37 +8,39 @@ OBJECT_FILES = $(FRAMEWORK_OBJECTS)
COMPILE_DIRS = Framework
if ENABLE_BASIC
OBJECT_FILES += $(BASIC_OBJECTS)
COMPILE_DIRS += Basic
BASIC_OBJECT_FILES = $(BASIC_OBJECTS)
BASIC_COMPILE_DIRS += Basic
endif
if ENABLE_CONSOLE
OBJECT_FILES += $(CONSOLE_OBJECTS)
COMPILE_DIRS += Console
CONSOLE_OBJECT_FILES += $(CONSOLE_OBJECTS)
CONSOLE_COMPILE_DIRS += Console
endif
if ENABLE_AUTOMATED
OBJECT_FILES += $(AUTOMATED_OBJECTS)
COMPILE_DIRS += Automated
AUTOMATED_OBJECT_FILES += $(AUTOMATED_OBJECTS)
AUTOMATED_COMPILE_DIRS += Automated
endif
if ENABLE_CURSES
OBJECT_FILES += $(CURSES_OBJECTS)
COMPILE_DIRS += Curses
CURSES_OBJECT_FILES += $(CURSES_OBJECTS)
CURSES_COMPILE_DIRS += Curses
endif
COMPILE_DIRS += .
if ENABLE_TEST
TEST_OBJECTS = \
TEST_OBJECT_FILES = \
Framework/CUError_test.o \
Framework/MyMem_test.o \
Framework/TestDB_test.o \
Framework/TestRun_test.o \
Framework/Util_test.o
COMPILE_DIRS += Test
TEST_COMPILE_DIRS += Test
endif
COMPILE_DIRS += $(BASIC_COMPILE_DIRS) $(CONSOLE_COMPILE_DIRS) $(AUTOMATED_COMPILE_DIRS) $(CURSES_COMPILE_DIRS) . $(TEST_COMPILE_DIRS)
OBJECT_FILES += $(BASIC_OBJECT_FILES) $(CONSOLE_OBJECT_FILES) $(AUTOMATED_OBJECT_FILES) $(CURSES_OBJECT_FILES)
TEST_OBJECTS = $(TEST_OBJECT_FILES)
SUBDIRS = $(COMPILE_DIRS)
......
EXAMPLE_DIRS = .
if ENABLE_BASIC
EXAMPLE_DIRS += BasicTest
BASIC_EXAMPLE_DIRS += BasicTest
endif
if ENABLE_CONSOLE
EXAMPLE_DIRS += ConsoleTest
CONSOLE_EXAMPLE_DIRS += ConsoleTest
endif
if ENABLE_CURSES
EXAMPLE_DIRS += CursesTest
CURSES_EXAMPLE_DIRS += CursesTest
endif
if ENABLE_AUTOMATED
EXAMPLE_DIRS += AutomatedTest
AUTOMATED_EXAMPLE_DIRS += AutomatedTest
endif
EXAMPLE_DIRS += $(BASIC_EXAMPLE_DIRS) $(CONSOLE_EXAMPLE_DIRS) $(CURSES_EXAMPLE_DIRS) $(AUTOMATED_EXAMPLE_DIRS)
SUBDIRS = ${EXAMPLE_DIRS}
noinst_LIBRARIES = libcunitexamples.a
......
COMPILE_DIRS = CUnit doc Man Share
if ENABLE_EXAMPLES
COMPILE_DIRS += Examples
EXAMPLE_COMPILE_DIR += Examples
endif
COMPILE_DIRS += $(EXAMPLE_COMPILE_DIR)
SUBDIRS = ${COMPILE_DIRS}
distdir=${PACKAGE}-${VERSION}-${RELEASE}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment