| author | sl@SLION-WIN7.fritz.box | 
| Fri, 15 Jun 2012 03:10:57 +0200 | |
| changeset 0 | bde4ae8d615e | 
| permissions | -rw-r--r-- | 
| sl@0 | 1  | 
# makefile to replace BLD.CMD  | 
| sl@0 | 2  | 
#  | 
| sl@0 | 3  | 
# Full syntax:  | 
| sl@0 | 4  | 
# plat is wins,marm  | 
| sl@0 | 5  | 
# cfg is rel,deb,urel,udeb,clean  | 
| sl@0 | 6  | 
# target is component to build  | 
| sl@0 | 7  | 
#  | 
| sl@0 | 8  | 
|
| sl@0 | 9  | 
!if "$(PLAT)" == "marm"  | 
| sl@0 | 10  | 
TARGETS=edbms edbsrv  | 
| sl@0 | 11  | 
!else  | 
| sl@0 | 12  | 
TARGETS=edbms  | 
| sl@0 | 13  | 
!endif  | 
| sl@0 | 14  | 
|
| sl@0 | 15  | 
MAKE_DIR=\epoc32\make\$(PLAT)  | 
| sl@0 | 16  | 
|
| sl@0 | 17  | 
MAKE=nmake -nologo  | 
| sl@0 | 18  | 
MAKMAKE=makmake  | 
| sl@0 | 19  | 
MAKCLEAN=makmake -clean  | 
| sl@0 | 20  | 
|
| sl@0 | 21  | 
!if "$(PLAT)" == "marm"  | 
| sl@0 | 22  | 
CPP_FLAG=-Wno-non-virtual-dtor  | 
| sl@0 | 23  | 
!endif  | 
| sl@0 | 24  | 
|
| sl@0 | 25  | 
all: $(TARGETS)  | 
| sl@0 | 26  | 
|
| sl@0 | 27  | 
$(TARGETS):  | 
| sl@0 | 28  | 
!if "$(PLAT)" == "ide"  | 
| sl@0 | 29  | 
# build the IDE makfile in the current directory  | 
| sl@0 | 30  | 
#  | 
| sl@0 | 31  | 
$(MAKMAKE) -d $(*B) $(CFG)  | 
| sl@0 | 32  | 
!else if "$(CFG)" == "clean"  | 
| sl@0 | 33  | 
# use Makmake's clean verb to delete all generated files  | 
| sl@0 | 34  | 
#  | 
| sl@0 | 35  | 
$(MAKCLEAN) -d $(*B) $(PLAT)  | 
| sl@0 | 36  | 
@if exist $(MAKE_DIR)\$(*B).$(PLAT) erase $(MAKE_DIR)\$(*B).$(PLAT)  | 
| sl@0 | 37  | 
!else  | 
| sl@0 | 38  | 
@$(MAKE) -c $(MAKE_DIR)\$(*B).$(PLAT)  | 
| sl@0 | 39  | 
$(MAKE) -kcs -f$(MAKE_DIR)\$(*B).$(PLAT) $(CFG) USERDEFS=$(CPP_FLAG) 1>$(*B).$(PLAT).$(CFG).log 2>&1  | 
| sl@0 | 40  | 
!endif  | 
| sl@0 | 41  | 
|
| sl@0 | 42  | 
.SUFFIXES: .$(PLAT) .mmp  | 
| sl@0 | 43  | 
|
| sl@0 | 44  | 
.mmp{$(MAKE_DIR)}.$(PLAT):
 | 
| sl@0 | 45  | 
$(MAKMAKE) -d $(*B) $(PLAT)  | 
| sl@0 | 46  | 
|
| sl@0 | 47  | 
wins:  | 
| sl@0 | 48  | 
@$(MAKE) plat=wins cfg=urel  | 
| sl@0 | 49  | 
@$(MAKE) plat=wins cfg=udeb  | 
| sl@0 | 50  | 
|
| sl@0 | 51  | 
marm:  | 
| sl@0 | 52  | 
@$(MAKE) plat=marm cfg=urel  | 
| sl@0 | 53  | 
@$(MAKE) plat=marm cfg=udeb  | 
| sl@0 | 54  | 
|
| sl@0 | 55  | 
clean:  | 
| sl@0 | 56  | 
@$(MAKE) plat=wins cfg=clean  | 
| sl@0 | 57  | 
@$(MAKE) plat=marm cfg=clean  |