]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - lib/csu/powerpc64/Makefile
Merge ^/vendor/lldb/dist up to its last change, and resolve conflicts.
[FreeBSD/FreeBSD.git] / lib / csu / powerpc64 / Makefile
1 # $FreeBSD$
2
3 .PATH: ${.CURDIR:H}/common
4
5 SRCS=           crt1.c crti.S crtn.S
6 OBJS=           ${SRCS:N*.h:R:S/$/.o/g}
7 OBJS+=          crtsavres.o Scrt1.o gcrt1.o
8 CFLAGS+=        -I${.CURDIR} -I${.CURDIR:H}/common \
9                 -I${SRCTOP}/lib/libc/include \
10                 -mlongcall -DCRT_IRELOC_RELA
11
12 FILES=          ${OBJS}
13 FILESMODE=      ${LIBMODE}
14 FILESOWN=       ${LIBOWN}
15 FILESGRP=       ${LIBGRP}
16 FILESDIR=       ${LIBDIR}
17 # These FILES qualify as libraries for the purpose of LIBRARIES_ONLY.
18 .undef LIBRARIES_ONLY
19
20 CLEANFILES=     ${OBJS}
21 CLEANFILES+=    crt1.s crtsavres.s gcrt1.s Scrt1.s
22
23 # See the comment in lib/csu/common/crtbrand.c for the reason crt1.c is not
24 # directly compiled to .o files.
25
26 crt1.s: crt1.c
27         ${CC} ${CFLAGS} -S -o ${.TARGET} ${.CURDIR}/crt1.c
28         sed ${SED_FIX_NOTE} ${.TARGET}
29
30 # On powerpc64 crtsavres is an empty file
31 crtsavres.s:
32         touch ${.TARGET}
33
34 crt1.o: crt1.s
35         ${CC} ${CFLAGS:N-g} ${ACFLAGS} -c -o ${.TARGET} crt1.s
36
37 gcrt1.s: crt1.c
38         ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c
39         sed ${SED_FIX_NOTE} ${.TARGET}
40
41 gcrt1.o: gcrt1.s
42         ${CC} ${CFLAGS:N-g} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s
43
44 Scrt1.s: crt1.c
45         ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c
46         sed ${SED_FIX_NOTE} ${.TARGET}
47
48 Scrt1.o: Scrt1.s
49         ${CC} ${CFLAGS:N-g} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s
50
51 .include <bsd.lib.mk>