source: trunk/make/testcase/dll-prog-c.mak@ 9054

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

Use new rules.

File size: 1.1 KB
Line 
1# $Id: dll-prog-c.mak,v 1.2 2002-08-20 08:01:46 bird Exp $
2
3# Testcase for makeing simple C DLLs.
4
5# root & setup
6PATH_ROOT=..\..
7!include $(PATH_ROOT)\make\setup.mak
8
9# target config.
10TARGET_NAME = dll-prog-c
11MAKEFILE = dll-prog-c.mak
12TARGET_LIBS = $(LIB_C_OBJ) $(LIB_OS) # use the static library!
13
14# rules and more
15!include $(MAKE_INCLUDE_PROCESS)
16
17
18
19# some helpers for the output.
20!if "$(BUILD_MODE)" == "DEBUG" || "$(BUILD_MODE)" == "PROFILE"
21_STR1 = Hello "C" "DEBUG" World!
22!else
23_STR1 = Hello "C" World!
24!endif
25
26!ifdef ENV_16BIT
27_STR2 = __16BIT__
28!else
29_STR2 = __32BIT__
30!endif
31
32
33#
34# validate that the executable actually runs and produces the desired output.
35#
36test:
37!if "$(MAKE_INCLUDE_PROCESS:process.forwarder=)" == "$(MAKE_INCLUDE_PROCESS)"
38 $(TOOL_MAKE) -f dll-c.mak rebuild
39 $(TARGET) $(PATH_OBJ)\dll-c.dll\dll-c.dll > out
40! ifdef BUILD_VERBOSE
41 type out
42! endif
43 $(TOOL_CMP) out <<
44DLLInit
45$(_STR1)
46$(_STR2)
47FOOName
48DLLTerm
49<<
50 $(TOOL_MAKE) -f dll-c.mak clean
51!else
52! ifndef BUILD_VERBOSE
53 @ \
54! endif
55 $(TOOL_BUILDENV) $(BUILD_ENVS_CHANGE) * $(TOOL_MAKE) -f $(MAKEFILE) $@
56!endif
57
Note: See TracBrowser for help on using the repository browser.