1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
|
#
# SCCS: @(#)makefile 1.1 (98/09/01)
#
# UniSoft Ltd., London, England
#
# Copyright (c) 1998 The Open Group
# All rights reserved.
#
# No part of this source code may be reproduced, stored in a retrieval
# system, or transmitted, in any form or by any means, electronic,
# mechanical, photocopying, recording or otherwise, except as stated in
# the end-user licence agreement, without the prior permission of the
# copyright owners.
# A copy of the end-user licence agreement is contained in the file
# Licence which accompanies this distribution.
#
# Motif, OSF/1, UNIX and the "X" device are registered trademarks and
# IT DialTone and The Open Group are trademarks of The Open Group in
# the US and other countries.
#
# X/Open is a trademark of X/Open Company Limited in the UK and other
# countries.
#
# ************************************************************************
#
# SCCS: @(#)makefile 1.1 98/09/01 TETware release 3.3
# NAME: makefile
# PRODUCT: TETware
# AUTHOR: Andrew Dingwall, UniSoft Ltd.
# DATE CREATED: August 1998
#
# DESCRIPTION:
# makefile used to build the shared version of the API library
#
# MODIFICATIONS:
#
# ************************************************************************
include ../../defines.mk
include ../ts.mk
LOCAL_TET_CDEFS = $(TET_CDEFS)
LOCAL_DTET_CDEFS = $(DTET_CDEFS)
LOCAL_CDEFS = -DTET_SHLIB_SOURCE
LOCAL_COPTS = $(COPTS) $(SHLIB_COPTS)
LOCAL_CC = $(SHLIB_CC)
# TET_CFLAGS and DTET_CFLAGS are set in ../common.mk
include ../common.mk
# the main library name;
# on Win32 systems this is the name of the import library
LIBNAME = libapi_s$(SO)
# The name of the DLL on Win32 systems.
# The DLL is a byproduct of the process that builds the shared library.
# Since this file is only generated on a Win32 system, it can't be used
# as a target or as a dependency in a platform-independent makefile;
# instead, a proxy target called lib_installed is used to determine when
# the DLL needs to be installed.
DLLNAME = libapi_s.dll
ALL = $(LIBNAME)
TARGETS = $(LIB)/$(LIBNAME) lib_installed
all: $(ALL)
install: $(TARGETS)
$(LIB)/$(LIBNAME): $(LIBNAME)
rm -f $@
cp $? $@
lib_installed: $(LIBNAME)
@set -x; \
case `uname -s` in \
Windows_NT|Windows_95|DOS) \
rm -f $(BIN)/$(DLLNAME); \
cp $(DLLNAME) $(BIN)/$(DLLNAME); \
;; \
esac
touch $@
# single-threaded shared libraries are not supported on Win32 systems
dynlink.gen:
touch $@
# tcm/shared.mk contains a definition of TCM_SHARED_OFILES
TCMSRC = ../tcm/
include ../tcm/shared.mk
# apilib/shared.mk contains a definition of API_SHARED_OFILES
APISRC = ../apilib/
include ../apilib/shared.mk
# the include ../servlib/shared.mk is done in ts.mk if needed
# dtet2lib/shared.mk contains a definition of DTET_SHARED_OFILES
DTETSRC = ../dtet2lib/
include ../dtet2lib/shared.mk
# ts.mk contains a definition of TS_SHARED_OFILES and SERV_SHARED_OFILES
include ts.mk
OFILES = $(API_SHARED_OFILES) $(TCM_SHARED_OFILES) $(SERV_SHARED_OFILES) \
$(TS_SHARED_OFILES) $(DTET_SHARED_OFILES)
$(LIBNAME): $(OFILES)
$(SHLIB_BUILD) -o $@ $(OFILES) $(SHLIB_BUILD_END)
$(MCS) -c $@
.PRECIOUS: $(LIBNAME)
CLEAN clean:
rm -f $(ALL) $(OFILES) *.sym dynlink.gen
CLOBBER clobber: clean
rm -f $(TARGETS)
@set -x; \
case `uname -s` in \
Windows_NT|Windows_95|DOS) \
rm -f $(BIN)/$(DLLNAME); \
;; \
esac
FORCE FRC: clobber all
# remove suffix rules from this makefile
# all .o files are made by explicit rules
.SUFFIXES:
.SUFFIXES: .none
|