Make.proto
author Jan Vrany <jan.vrany@fit.cvut.cz>
Wed, 09 Jul 2014 21:35:30 +0100
branchworking_v5_0
changeset 611 1eecc860f4a5
parent 588 0d69293eb505
child 614 3003097506c9
permissions -rw-r--r--
Project definition fixed and HG configured as for CVS mirror repository.

# $Header$
#
# DO NOT EDIT
# automagically generated from the projectDefinition: stx_goodies_sunit.
#
# Warning: once you modify this file, do not rerun
# stmkmp or projectDefinition-build again - otherwise, your changes are lost.
#
# The Makefile as generated by this Make.proto supports the following targets:
#    make         - compile all st-files to a classLib
#    make clean   - clean all temp files
#    make clobber - clean all
#
# This file contains definitions for Unix based platforms.
# It shares common definitions with the win32-make in Make.spec.

#
# position (of this package) in directory hierarchy:
# (must point to ST/X top directory, for tools and includes)
TOP=../..
INCLUDE_TOP=$(TOP)/..

# subdirectories where targets are to be made:
SUBDIRS=


# subdirectories where Makefiles are to be made:
# (only define if different from SUBDIRS)
# ALLSUBDIRS=

REQUIRED_SUPPORT_DIRS=

# if your embedded C code requires any system includes,
# add the path(es) here:,
# ********** OPTIONAL: MODIFY the next lines ***
# LOCALINCLUDES=-Ifoo -Ibar
LOCALINCLUDES= -I$(INCLUDE_TOP)/stx/libbasic -I$(INCLUDE_TOP)/stx/libbasic2 -I$(INCLUDE_TOP)/stx/libview -I$(INCLUDE_TOP)/stx/libview2


# if you need any additional defines for embedded C code,
# add them here:,
# ********** OPTIONAL: MODIFY the next lines ***
# LOCALDEFINES=-Dfoo -Dbar -DDEBUG
LOCALDEFINES=

LIBNAME=libstx_goodies_sunit
STCLOCALOPT='-package=$(PACKAGE)' -I. $(LOCALINCLUDES) $(STCLOCALOPTIMIZATIONS) $(STCWARNINGS) $(LOCALDEFINES) -headerDir=.  -varPrefix=$(LIBNAME)


# ********** OPTIONAL: MODIFY the next line ***
# additional C-libraries that should be pre-linked with the class-objects
LD_OBJ_LIBS=
LOCAL_SHARED_LIBS=


# ********** OPTIONAL: MODIFY the next line ***
# additional C targets or libraries should be added below
LOCAL_EXTRA_TARGETS=

OBJS= $(COMMON_OBJS) $(UNIX_OBJS)



all:: preMake classLibRule postMake

pre_objs::  




# Update SVN revision in package definition class
ifneq (,$(findstring .svn,$(wildcard .svn)))
.svnversion: *.st
	if [ -d .svn ]; then \
		rev=$(shell svnversion -n); \
		echo -n $$rev > .svnversion; \
	else \
		echo -n exported > .svnversion; \
	fi

stx_goodies_sunit.o: stx_goodies_sunit.st .svnversion
	@if [ -d .svn ]; then \
		rev2="$(shell printf "%-16s" $$(cat .svnversion))"; \
		echo "  [SV]  Expanding svnRevisionNo in $1.st"; \
		sed -e "s/\"\$$SVN\-Revision:\".*\"\$$\"/\"\$$SVN-Revision:\"\'$$rev2\'\"\$$\"/g" $< > .stx_goodies_sunit.svn.st; \
	fi
	$(MAKE) CC="$(CLASSLIB_CC)" OPT="$(OPT)" SEPINITCODE="$(SEPINITCODE)" STC="$(STC)" STFILE=.stx_goodies_sunit.svn $(C_RULE);
	sed -i -e "s/\".stx_goodies_sunit.svn.st\");/\"\stx_goodies_sunit.st\");/g" .stx_goodies_sunit.svn.c
	$(MAKE) .stx_goodies_sunit.svn.$(O)
	@mv .stx_goodies_sunit.svn.$(O) stx_goodies_sunit.$(O)
endif



# Enforce recompilation of package definition class if Mercurial working
# copy state changes. Together with --guessVersion it ensures that package
# definition class always contains correct binary revision string.
ifneq (**NOHG**, $(shell hg root 2> /dev/null || echo -n '**NOHG**'))
stx_goodies_sunit.$(O): $(shell hg root)/.hg/dirstate
endif




# run default testsuite for this package
test: $(TOP)/goodies/builder/reports
	$(MAKE) -C $(TOP)/goodies/builder/reports -f Makefile.init
	$(TOP)/goodies/builder/reports/report-runner.sh -D . -r Builder::TestReport -p $(PACKAGE)



# add more install actions here
install::

# add more install actions for aux-files (resources) here
installAux::

# add more preMake actions here
preMake::

# add more postMake actions here
postMake:: cleanjunk

# build all mandatory prerequisite packages (containing superclasses) for this package
prereq:
	cd ../../libbasic && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES)"
	cd ../../libbasic2 && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES)"
	cd ../../libview && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES)"
	cd ../../libview2 && $(MAKE) "CFLAGS_LOCAL=$(GLOBALDEFINES)"



# build all packages containing referenced classes for this package
# they are nor needed to compile the package
references:


cleanjunk::
	-rm -f *.s *.s2

clean::
	-rm -f *.o *.H

clobber:: clean
	-rm -f *.so *.dll


# BEGINMAKEDEPEND --- do not remove this line; make depend needs it
$(OUTDIR)MetricsReporter.$(O) MetricsReporter.$(H): MetricsReporter.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)SUnitDelay.$(O) SUnitDelay.$(H): SUnitDelay.st $(INCLUDE_TOP)/stx/libbasic/Delay.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)SUnitNameResolver.$(O) SUnitNameResolver.$(H): SUnitNameResolver.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestAsserter.$(O) TestAsserter.$(H): TestAsserter.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestCaseOutcome.$(O) TestCaseOutcome.$(H): TestCaseOutcome.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestCoverageReporter.$(O) TestCoverageReporter.$(H): TestCoverageReporter.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestFailure.$(O) TestFailure.$(H): TestFailure.st $(INCLUDE_TOP)/stx/libbasic/Exception.$(H) $(INCLUDE_TOP)/stx/libbasic/GenericException.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestResult.$(O) TestResult.$(H): TestResult.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestResultReporter.$(O) TestResultReporter.$(H): TestResultReporter.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestRunner.$(O) TestRunner.$(H): TestRunner.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(INCLUDE_TOP)/stx/libview2/ApplicationModel.$(H) $(INCLUDE_TOP)/stx/libview2/Model.$(H) $(STCHDR)
$(OUTDIR)TestSuite.$(O) TestSuite.$(H): TestSuite.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestSuitesScripter.$(O) TestSuitesScripter.$(H): TestSuitesScripter.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)stx_goodies_sunit.$(O) stx_goodies_sunit.$(H): stx_goodies_sunit.st $(INCLUDE_TOP)/stx/libbasic/LibraryDefinition.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(INCLUDE_TOP)/stx/libbasic/ProjectDefinition.$(H) $(STCHDR)
$(OUTDIR)ResumableTestFailure.$(O) ResumableTestFailure.$(H): ResumableTestFailure.st $(INCLUDE_TOP)/stx/goodies/sunit/TestFailure.$(H) $(INCLUDE_TOP)/stx/libbasic/Exception.$(H) $(INCLUDE_TOP)/stx/libbasic/GenericException.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestCase.$(O) TestCase.$(H): TestCase.st $(INCLUDE_TOP)/stx/goodies/sunit/TestAsserter.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestResource.$(O) TestResource.$(H): TestResource.st $(INCLUDE_TOP)/stx/goodies/sunit/TestAsserter.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestResultStX.$(O) TestResultStX.$(H): TestResultStX.st $(INCLUDE_TOP)/stx/goodies/sunit/TestResult.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestSkipped.$(O) TestSkipped.$(H): TestSkipped.st $(INCLUDE_TOP)/stx/goodies/sunit/TestFailure.$(H) $(INCLUDE_TOP)/stx/libbasic/Exception.$(H) $(INCLUDE_TOP)/stx/libbasic/GenericException.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestCaseWithArguments.$(O) TestCaseWithArguments.$(H): TestCaseWithArguments.st $(INCLUDE_TOP)/stx/goodies/sunit/TestAsserter.$(H) $(INCLUDE_TOP)/stx/goodies/sunit/TestCase.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)TestResultForRunWithDebug.$(O) TestResultForRunWithDebug.$(H): TestResultForRunWithDebug.st $(INCLUDE_TOP)/stx/goodies/sunit/TestResult.$(H) $(INCLUDE_TOP)/stx/goodies/sunit/TestResultStX.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR)
$(OUTDIR)extensions.$(O): extensions.st $(INCLUDE_TOP)/stx/libbasic/ArrayedCollection.$(H) $(INCLUDE_TOP)/stx/libbasic/Behavior.$(H) $(INCLUDE_TOP)/stx/libbasic/Block.$(H) $(INCLUDE_TOP)/stx/libbasic/CharacterArray.$(H) $(INCLUDE_TOP)/stx/libbasic/Class.$(H) $(INCLUDE_TOP)/stx/libbasic/ClassDescription.$(H) $(INCLUDE_TOP)/stx/libbasic/Collection.$(H) $(INCLUDE_TOP)/stx/libbasic/CompiledCode.$(H) $(INCLUDE_TOP)/stx/libbasic/ExecutableFunction.$(H) $(INCLUDE_TOP)/stx/libbasic/GenericException.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(INCLUDE_TOP)/stx/libbasic/SequenceableCollection.$(H) $(INCLUDE_TOP)/stx/libbasic/String.$(H) $(INCLUDE_TOP)/stx/libbasic/Symbol.$(H) $(INCLUDE_TOP)/stx/libbasic/UninterpretedBytes.$(H) $(STCHDR)

# ENDMAKEDEPEND --- do not remove this line