3 .PATH: ${.CURDIR}/../common
6 FILES= ${SRCS:N*.h:R:S/$/.o/g} gcrt1.o crt1.o Scrt1.o
11 CFLAGS+= -I${.CURDIR}/../common \
12 -I${.CURDIR}/../../libc/include
13 CLEANFILES= ${FILES} crt1_c.o crt1_s.o gcrt1_c.o Scrt1_c.o
14 CLEANFILES+= crt1_c.s gcrt1_c.s Scrt1_c.s
16 # See the comment in lib/csu/common/crtbrand.c for the reason crt1_c.c is not
17 # directly compiled to .o files.
20 ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1_c.c
21 sed ${SED_FIX_NOTE} ${.TARGET}
24 ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1_c.s
26 gcrt1.o: gcrt1_c.o crt1_s.o
27 ${LD} ${LDFLAGS} -o gcrt1.o -r crt1_s.o gcrt1_c.o
30 ${CC} ${CFLAGS} -S -o ${.TARGET} ${.CURDIR}/crt1_c.c
31 sed ${SED_FIX_NOTE} ${.TARGET}
34 ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1_c.s
36 crt1.o: crt1_c.o crt1_s.o
37 ${LD} ${LDFLAGS} -o crt1.o -r crt1_s.o crt1_c.o
38 objcopy --localize-symbol _start1 crt1.o
41 ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1_c.c
42 sed ${SED_FIX_NOTE} ${.TARGET}
45 ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1_c.s
47 Scrt1.o: Scrt1_c.o crt1_s.o
48 ${LD} ${LDFLAGS} -o Scrt1.o -r crt1_s.o Scrt1_c.o
49 objcopy --localize-symbol _start1 Scrt1.o
51 .include <bsd.prog.mk>