source: trunk/make/testcase/prog-cxx-as-c.mak@ 9063

Last change on this file since 9063 was 9063, checked in by bird, 23 years ago

Bugfixes.

File size: 869 bytes
Line 
1# $Id: prog-cxx-as-c.mak,v 1.2 2002-08-20 21:14:30 bird Exp $
2
3# Testcase for makeing simple C programs as C++.
4
5# root & setup
6CXX_AS_CC= 1
7PATH_ROOT=..\..
8!include $(PATH_ROOT)\make\setup.mak
9
10# target config.
11TARGET_NAME = prog-cxx
12MAKEFILE = prog-cxx-as-c.mak
13TARGET_LIBS = $(LIB_C_OBJ) $(LIB_OS) # use the static library!
14
15# rules and more
16RULES_FORWARD = test
17!include $(MAKE_INCLUDE_PROCESS)
18
19!if !$(BUILD_FORWARDING)
20
21# some helpers for the output.
22!if "$(BUILD_MODE)" == "DEBUG" || "$(BUILD_MODE)" == "PROFILE"
23_STR1 = Hello "C" "DEBUG" World!
24!else
25_STR1 = Hello "C" World!
26!endif
27
28!ifdef ENV_16BIT
29_STR2 = __16BIT__
30!else
31_STR2 = __32BIT__
32!endif
33
34
35#
36# validate that the executable actually runs and produces the desired output.
37#
38test:
39 $(TARGET) > out
40!ifdef BUILD_VERBOSE
41 type out
42!endif
43 $(TOOL_CMP) out <<
44$(_STR1)
45
46$(_STR2)
47
48<<
49
50!endif
Note: See TracBrowser for help on using the repository browser.