sbsv2/raptor/lib/flm/tools/buildstubsis.flm
author yiluzhu
Tue, 23 Feb 2010 14:22:19 +0000
branchfix
changeset 247 8426d4dedf84
parent 3 e1eecf4d390d
permissions -rw-r--r--
Merge

# Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
# All rights reserved.
# This component and the accompanying materials are made available
# under the terms of the License "Eclipse Public License v1.0"
# which accompanies this distribution, and is available
# at the URL "http://www.eclipse.org/legal/epl-v10.html".
#
# Initial Contributors:
# Nokia Corporation - initial contribution.
#
# Contributors:
#
# Description:
#

# FLM to build StubSis libraries.

## Outputs - externally relevant targets that this FLM generates

TARGETDIR:=$(EPOCROOT)/epoc32/data/z/system/install

ifeq ($(PLATFORM),WINSCW)
	TARGETDIR:=$(EPOCROOT)/epoc32/release/$(PLATFORM_PATH)/$(CFG_PATH)/z/system/install
endif

$(call makepath,$(TARGETDIR))

# This section is in a macro oherwise startrule could get wrong values
define SisFileCreation
$(SISFILE): $(EXTENSION_ROOT)/$(SRCDIR)/$(SISNAME).pkg
	$(call startrule,stubsis) \
	$(EPOCROOT)/epoc32/tools/makesis$(DOTEXE) -s $$? $$@  \
	$(call endrule,stubsis)
endef

# Build stub SIS file
SISFILE:= $(TARGETDIR)/$(SISNAME).sis
# Here a variable named "done_<sanitised $SISFILE>" gets created
GUARD:=done_$(call sanitise,$(SISFILE))
# If variable "done_..." not set, set it to 1, so that
# UREL and UDEB do not execute makesis twice on the same target 
ifeq ($($(GUARD)),)
$(GUARD):=1
ALL:: $(SISFILE)
$(eval $(call SisFileCreation))
$(eval $(call whatmacro,$(SISFILE)))
$(eval $(call GenerateStandardCleanTarget,$(SISFILE),$(TARGETDIR)))
endif