1 |
38 |
julius |
CRTSTUFF_T_CFLAGS = -mpreferred-stack-boundary=2
|
2 |
|
|
CRT0STUFF_T_CFLAGS = -mpreferred-stack-boundary=2 $(INCLUDES)
|
3 |
|
|
# this is a slight misuse (it's not an assembler file)
|
4 |
|
|
CRT0_S = $(srcdir)/config/i386/netware-crt0.c
|
5 |
|
|
MCRT0_S = $(srcdir)/config/i386/netware-crt0.c
|
6 |
|
|
|
7 |
|
|
libgcc.def: $(srcdir)/config/i386/t-nwld
|
8 |
|
|
echo "module libgcc_s" >$@
|
9 |
|
|
|
10 |
|
|
libc.def: $(srcdir)/config/i386/t-nwld
|
11 |
|
|
echo "module libc" >$@
|
12 |
|
|
|
13 |
|
|
libcpre.def: $(srcdir)/config/i386/t-nwld
|
14 |
|
|
echo "start _LibCPrelude" >$@
|
15 |
|
|
echo "exit _LibCPostlude" >>$@
|
16 |
|
|
echo "check _LibCCheckUnload" >>$@
|
17 |
|
|
|
18 |
|
|
posixpre.def: $(srcdir)/config/i386/t-nwld
|
19 |
|
|
echo "start POSIX_Start" >$@
|
20 |
|
|
echo "exit POSIX_Stop" >>$@
|
21 |
|
|
echo "check POSIX_CheckUnload" >>$@
|
22 |
|
|
|
23 |
|
|
nwld.o: $(srcdir)/config/i386/nwld.c $(RTL_H) $(TREE_H) $(CONFIG_H) $(TM_P_H)
|
24 |
|
|
$(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $(srcdir)/config/i386/nwld.c
|
25 |
|
|
|
26 |
|
|
|
27 |
|
|
s-crt0: $(srcdir)/unwind-dw2-fde.h
|
28 |
|
|
|
29 |
|
|
# Build a shared libgcc library for NetWare.
|
30 |
|
|
|
31 |
|
|
SHLIB_EXT = .nlm
|
32 |
|
|
SHLIB_NAME = @shlib_base_name@.nlm
|
33 |
|
|
SHLIB_SLIBDIR_QUAL = @shlib_slibdir_qual@
|
34 |
|
|
SHLIB_DEF = $(srcdir)/config/i386/netware-libgcc.def
|
35 |
|
|
SHLIB_MAP = $(srcdir)/config/i386/netware-libgcc.exp
|
36 |
|
|
SHLIB_SRC = $(srcdir)/config/i386/netware-libgcc.c
|
37 |
|
|
|
38 |
|
|
SHLIB_LINK = set -e; \
|
39 |
|
|
cat $(SHLIB_DEF) >@shlib_base_name@.def; \
|
40 |
|
|
echo "name $(SHLIB_NAME)" >>@shlib_base_name@.def; \
|
41 |
|
|
echo "version $(version)" | sed "s!\.!,!g" >>@shlib_base_name@.def; \
|
42 |
|
|
touch libgcc/build; \
|
43 |
|
|
echo "build $$$$(expr $$$$(>@shlib_base_name@.def; \
|
44 |
|
|
echo "export @$(SHLIB_MAP)" >>@shlib_base_name@.def; \
|
45 |
|
|
if mpkxdc -n -p @shlib_base_name@.xdc; \
|
46 |
|
|
then echo "xdcdata @shlib_base_name@.xdc" >>@shlib_base_name@.def; \
|
47 |
|
|
else echo "WARNING: $(SHLIB_NAME) built without XDC data will not work well." 1>&2; \
|
48 |
|
|
fi; \
|
49 |
|
|
$(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) -o $(SHLIB_NAME) \
|
50 |
|
|
$(SHLIB_SRC) -posix -static-libgcc -lnetware \
|
51 |
|
|
-Wl,--Map,--map-info,full,--strip-all,--def-file,@shlib_base_name@.def; \
|
52 |
|
|
rm -f @shlib_base_name@.imp; $(LN_S) $(SHLIB_MAP) @shlib_base_name@.imp; \
|
53 |
|
|
rm -f libgcc.imp; $(LN_S) @shlib_base_name@.imp libgcc.imp; \
|
54 |
|
|
expr $$$$(libgcc/build
|
55 |
|
|
|
56 |
|
|
# $(slibdir) double quoted to protect it from expansion while building
|
57 |
|
|
# libgcc.mk. We want this delayed until actual install time.
|
58 |
|
|
SHLIB_INSTALL = \
|
59 |
|
|
$$(SHELL) $(srcdir)/mkinstalldirs $$(slibdir)$(SHLIB_SLIBDIR_QUAL); \
|
60 |
|
|
$$(INSTALL_DATA) $(SHLIB_NAME) $$(slibdir)$(SHLIB_SLIBDIR_QUAL)/$(SHLIB_NAME); \
|
61 |
|
|
$$(INSTALL_DATA) @shlib_base_name@.imp $$(DESTDIR)$$(libsubdir)/
|