makelib/definitions.make
author Jan Vrany <jan.vrany@labware.com>
Mon, 31 Jul 2023 16:32:33 +0100
changeset 339 6582cb445441
parent 274 d9d5871b987c
permissions -rw-r--r--
Specs, get-stx.py: use 'https://dl.vrany.io/public/smalltalkx/devel' as artifact repository


include $(MAKELIB)/../build/stx-config.make

#
# MIMEType: application/x-make
#
# this Makefile was generated by CONFIG / make Makefile
#
# do not change here
# - change in Make.proto, stdRules or stdHeader
#
# otherwise your changes are lost when Makefiles are recreated
#
# if your system is not the one described below (CONF=),
# you have to rerun config in stc's TOP directory !
#

default:: redefinableAll

#------------------ start of rules/stdHeader ---------------------
#
# $Header: /cvs/stx/stx/rules/stdHeader,v 1.33 2014-11-20 16:24:40 cg Exp $
#

#
# the default target;
# this is redefined for HP and AIX, to compile some individual files
# using different options
# (due to exponential grows of their cc, they cannot compile certain files with -O/-O2)
#
ALL_TARGET=all

#
# where things get collected when building
#
BUILD_DIR=$(TOP)/build
BUILD_BIN_DIR=$(BUILD_DIR)/bin
BUILD_PACKAGE_DIR=$(BUILD_DIR)/packages

# -------------------------------------------
# installation directories (for make install)
# -------------------------------------------

INSTALLBASE=/opt/smalltalk/$(RELEASE)

INSTALLTOP_DIR=$(INSTALLBASE)/packages/$(MODULE)/$(MODULE_DIR)
INSTALLLIB_DIR=$(INSTALLTOP_DIR)
INSTALLBIN_DIR=$(INSTALLBASE)/bin

INSTALLBITMAPSLIB_DIR=$(INSTALLLIB_DIR)
INSTALLDOCLIB_DIR=$(INSTALLLIB_DIR)
DOC_DIR=doc

INSTALL_SUBDIRS=$(ALLSUBDIRS)

#
# if found in a directory,
# those are also installed
#
INSTALLED_LOAD_SCRIPTS=loadAll

#
# LIB is used for recursive make-invocations;
# it needs a non-empty default for make to accept the Makefile
#
LIB=none

H=H
OUTDIR=

INCL=$(INCLUDE)/

STCHDR=$(INCLUDE)/stc.h $(INCLUDE)/stcIntern.h
# STC_MSGFORMAT= -messageFormat: gcc
STC_MSGFORMAT= -messageFormat: gcc-jenkins
SYSDEP_OBJS=$(UNIX_OBJS)
AR_OBJS=$(OBJS) $(AUXOBJS)

UNCRITICALOBJS='xxx.o'
UNCRITICALOPT=+optspace3
AUTOLOADEDOBJS='yyy.o'

#
# SUBDIRS is used to make targets;
# ALLSUBDIRS are those in which makefiles are created
# (i.e. this allows passive directories, like all in
# clients to be added)
#

SUBDIRS=
ALLSUBDIRS=$(SUBDIRS)

RULEDIR=$(TOP)/rules

STBC=$(RULEDIR)/stbc
STDHEADER=stdHeader
STDRULES=stdRules
STDHEADER_NT=stdHeader_nt
STDRULES_NT=stdRules_nt

#
# files to be rcs managed
# this is ok for classlib directories;
# c directories (librun, stc) must redefine it
#
RCSSOURCES=*.st Make.proto

#
# files to be symlinked to a common source tree
# this is ok for classlib directories;
# c directories (librun, stc) must redefine it
#
LINKSOURCES=*.st Make.proto

#
# files to be delivered by default.
# to be redefined in sub-Make.protos
#
DELIVERSOURCES=$(RCSSOURCES)
DELIVERMISC=Makefile *.stc .dir.info README*
DELIVERBINARIES=lib*.o lib*.so lib*.a

#
# rule for object file creation.
# If redefined, there must be a corresponding rule in
# the architecture specific config file
# This is extra tricky and not recommended
#
O_RULE=__STANDARD_O_RULE__
C_RULE=__STANDARD_C_RULE__
S_RULE=__STANDARD_S_RULE__
H_RULE=__STANDARD_H_RULE__

SPACEOPT_O_RULE=__STANDARD_O_RULE__
SPEEDOPT_O_RULE=__STANDARD_O_RULE__

CC_SPEEDOPT=
CC_SPACEOPT=

#
# rule to create a classList & to edit it into a .c file
#
CLASSLISTRULE=genClassList
CLASSLISTEDITRULE=classListEdit

#
# special kludge for HP's stupid cpp limitations
#
# allows definition of another rule for big-st files,
# and setting of BIG_ST_RULE=some_other_rule
# see libview/Make.proto for an example
#

BIG_STFILE_RULE=BIG_STFILE_NORMAL
BIG_STFILE_NORMAL:
	    $(STC) -CC="$(CC)" $(STCFLAGS) $(CFLAGS) -c $(BIG_FILE).st

#
# special kludge for a bug in NeXT's (2.1) assembler,
# which dumps core for some long identifiers
# (funny, only happens with SeqColl)
#
LONGNAME_RULE=LONGNAME_NORMAL
LONGNAME_NORMAL:
	    $(STC) -CC="$(CC)" $(STCFLAGS) $(CFLAGS) -c $(LONGNAME_FILE).st

SHAREDCLASSLIBRARIES=""

UPDATETARGET=all

#------------------ end of rules/stdHeader ---------------------


# Include config
ifndef BUILD_TARGET
$(error "BUILD_TARGET not defined!")
endif
include $(MAKELIB)/config-$(BUILD_TARGET).make


#------------------ start of rules/stdHeader2 ---------------------
COMMONDEFS += -DBUILD_TARGET=\"$(BUILD_TARGET)\"
COMMONSYMBOLS=+commonSymbols


# collected compiler flags

CC_OPTS=$(CCCOMMONOPT) $(CCARCHCOMMONOPT) $(CCARCHOPT) $(OPT) $(CCCONFOPT) $(CC_CMD_OPT)

STC_OPTS=$(STCCOMMONOPT) $(STCARCHCOMMONOPT) $(STCARCHOPT) $(STCOPT) $(COMMONSTCCONFOPT) $(STCCONFOPT) $(STCLOCALOPT) $(STC_CMD_OPT)

CC_DEFS=$(DEFS) $(COMMONDEFS) $(ARCHCOMMONDEFS) $(ARCHDEFS) $(OTHERDEFS) $(LOCALDEFS)

CFLAGS     = -I$(INCLUDE) $(LOCALINCLUDES) $(OS) $(CC_OPTS) $(DBG) $(CC_DEFS) $(CCLOCALOPT)

MAIN_CFLAGS= -I$(INCLUDE) $(OS) $(ARCHOPT) $(CCCONFOPT) $(MAIN_OPT) $(DBG) $(CC_DEFS)

STCFLAGS   = -CC="$(CC)" -Y$(INCLUDE) -I$(INCLUDE) $(STCOPT) $(STC_OPTS) $(LIMITSUPERINCLUDE) $(FORCEAUTOLOAD) +lineInfo +stLineInfo -scmType: auto -sha1

SNMP_CC_OPT=$(ARCHOPT) $(OPT)

DLD_CFLAGS=$(CC_OPTS) $(DBG) $(CC_DEFS)

LINKOBJS   = $(OBJS)

#------------------ end of rules/stdHeader2 ---------------------