persistentstorage/dbms/bmake/MAKEFILE
author Chris Dudding <chris.dudding@nokia.com>
Tue, 13 Jul 2010 18:32:07 +0100
changeset 37 5ce4638b3d6d
parent 0 08ec8eefde2f
permissions -rw-r--r--
DEADHEAD Closing redundant branch: Bug 3168 (changeset 32: 0bacd7dbb9a9) is already incorporated in the 201025_05 bulk delivery (changeset 33: 5e4beccba4e9).

# makefile to replace BLD.CMD
#
# Full syntax:
#    plat is wins,marm
#    cfg is rel,deb,urel,udeb,clean
#    target is component to build
#

!if "$(PLAT)" == "marm"
TARGETS=edbms edbsrv
!else
TARGETS=edbms
!endif

MAKE_DIR=\epoc32\make\$(PLAT)

MAKE=nmake -nologo
MAKMAKE=makmake
MAKCLEAN=makmake -clean

!if "$(PLAT)" == "marm"
CPP_FLAG=-Wno-non-virtual-dtor
!endif

all: $(TARGETS)

$(TARGETS):
!if "$(PLAT)" == "ide"
# build the IDE makfile in the current directory
#
    $(MAKMAKE) -d $(*B) $(CFG)
!else if "$(CFG)" == "clean"
# use Makmake's clean verb to delete all generated files
#
    $(MAKCLEAN) -d $(*B) $(PLAT)
    @if exist $(MAKE_DIR)\$(*B).$(PLAT) erase $(MAKE_DIR)\$(*B).$(PLAT)
!else
	@$(MAKE) -c $(MAKE_DIR)\$(*B).$(PLAT)
	$(MAKE) -kcs -f$(MAKE_DIR)\$(*B).$(PLAT) $(CFG) USERDEFS=$(CPP_FLAG) 1>$(*B).$(PLAT).$(CFG).log 2>&1
!endif

.SUFFIXES: .$(PLAT) .mmp

.mmp{$(MAKE_DIR)}.$(PLAT):
	$(MAKMAKE) -d $(*B) $(PLAT)

wins:
    @$(MAKE) plat=wins cfg=urel
    @$(MAKE) plat=wins cfg=udeb

marm:
    @$(MAKE) plat=marm cfg=urel
    @$(MAKE) plat=marm cfg=udeb

clean:
    @$(MAKE) plat=wins cfg=clean
	@$(MAKE) plat=marm cfg=clean