File: makefile.imk

package info (click to toggle)
ppmd 10.1-5
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 380 kB
  • sloc: cpp: 3,703; makefile: 96
file content (48 lines) | stat: -rw-r--r-- 1,154 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# I`m too lazy to learn two make syntaxes, so I use Boralnd`s MAKE.EXE program
## Take a look at PPMdType.h for additional compiler & environment options
.AUTODEPEND
#               User defined variables
PRJNAME=PPMd
DEBUG=0
PROFILE=NO      # NO, GET, USE
CPP_SET=$(PRJNAME).cpp Model.cpp
C_SET=
.path.cpp = ;
#               End of user defined variables

CC     = icl.exe
LINK   = link.exe
ECFLAG = /GR- /GX-
ELFLAG =/OUT:$(PRJNAME).exe /MAP /ALIGN:4096 /NOLOGO
LIBS   = 

!if $(PROFILE) == USE
    PCFLAG = /Qprof_use /Qfnsplit
    PLFLAG = /ORDER:@proford.txt
!elif $(PROFILE) == GET
    PCFLAG = /Qprof_genx
    PLFLAG =
    LIBS = LIBIRC.LIB $(LIBS)
!endif

!if $(DEBUG) != 0
    DCFLAG = /Zi /Od 
    DLFLAG = /DEBUG
!else
    DCFLAG = /O3 /G6A /Qxi
    DLFLAG = /RELEASE
!endif

OBJ_SET = $(CPP_SET:.cpp=.obj) $(C_SET:.c=.obj) $(ASM_SET:.asm=.obj)

$(PRJNAME).exe: $(OBJ_SET)
!if $(PROFILE) == USE
  -proforder
!endif
  @$(LINK) $(ELFLAG) $(DLFLAG) $(PLFLAG) $(OBJ_SET)$(LIBS)

.cpp.obj:
    @$(CC) $(ECFLAG) $(DCFLAG) $(PCFLAG) -c {$< }

.c.obj:
    @$(CC) $(ECFLAG) $(DCFLAG) $(PCFLAG) -c {$< }