44a12484aafbd37a3ea455f0c882c7b570c2897d
[dragonfly.git] / lib / csu / i386 / Makefile.csu
1 # $FreeBSD: src/lib/csu/i386-elf/Makefile,v 1.6.2.5 2002/11/23 17:44:29 ru Exp $
2
3 SRCS+=          crti.S crtn.S
4 OBJS+=          gcrt1.o crt1.o Scrt1.o
5 INSTALLOBJS+=   crt1.o crti.o crtn.o gcrt1.o Scrt1.o
6 CLEANFILES+=    crt1.o crti.o crtn.o gcrt1.o Scrt1.o \
7                 crt1_c.o crt1_s.o gcrtl_c.o Scrt1_c.o
8 WARNS?=         2
9
10 CFLAGS+=        -I${CSUDIR}/../common
11
12 .PATH:          ${CSUDIR} ${CSUDIR}/../common
13
14 gcrt1_c.o:      crt1_c.c
15         ${CC} ${CFLAGS} -DGCRT -c -o gcrt1_c.o ${CSUDIR}/crt1_c.c
16
17 gcrt1.o:        gcrt1_c.o crt1_s.o
18         ${LD} ${LDFLAGS} -o gcrt1.o -r crt1_s.o gcrt1_c.o
19
20 crt1.o:         crt1_c.o crt1_s.o
21         ${LD} ${LDFLAGS} -o crt1.o -r crt1_s.o crt1_c.o
22         objcopy --localize-symbol _start1 crt1.o
23
24 Scrt1_c.o:      crt1_c.c
25         ${CC} ${CFLAGS} -DGCRT -fPIC -DPIC -c -o Scrt1_c.o ${CSUDIR}/crt1_c.c
26
27 Scrt1.o:        Scrt1_c.o crt1_s.o
28         ${LD} ${LDFLAGS} -o Scrt1.o -r crt1_s.o Scrt1_c.o
29         objcopy --localize-symbol _start1 Scrt1.o