Makefile revision 132751
1# $FreeBSD: head/gnu/usr.bin/cc/cc_int/Makefile 132751 2004-07-28 05:27:21Z kan $
2
3.include "../Makefile.inc"
4
5.PATH: ../cc_tools ${GCCDIR}/config/${GCC_CPU} ${GCCDIR}
6
7LIB=		cc_int
8INTERNALLIB=	YES
9
10# Files from libiberty.
11SRCS=	choose-temp.c concat.c cp-demangle.c cp-demint.c cplus-dem.c \
12        dyn-string.c errors.c fibheap.c getpwd.c getruntime.c hashtab.c \
13	hex.c lbasename.c make-temp-file.c md5.c obstack.c partition.c \
14	pexecute.c physmem.c splay-tree.c xexit.c xmalloc.c xmemdup.c \
15	xstrdup.c xstrerror.c xexit.c
16
17# Language-independent files.
18SRCS+=	alias.c bb-reorder.c bitmap.c builtins.c caller-save.c calls.c \
19	cfg.c cfganal.c cfgbuild.c cfgcleanup.c cfglayout.c cfgloop.c \
20	cfgloopanal.c cfgloopmanip.c loop-init.c loop-unswitch.c loop-unroll.c \
21	cfgrtl.c combine.c conflict.c convert.c coverage.c cse.c cselib.c \
22	dbxout.c debug.c df.c diagnostic.c dojump.c doloop.c dominance.c \
23	dwarf2asm.c dwarf2out.c emit-rtl.c except.c explow.c \
24	expmed.c expr.c final.c flow.c fold-const.c function.c gcse.c \
25	genrtl.c ggc-common.c global.c graph.c gtype-desc.c \
26	haifa-sched.c hooks.c ifcvt.c  \
27	integrate.c intl.c jump.c  langhooks.c lcm.c lists.c local-alloc.c \
28	loop.c optabs.c options.c opts.c params.c postreload.c predict.c \
29	print-rtl.c print-tree.c value-prof.c \
30	profile.c ra.c ra-build.c ra-colorize.c ra-debug.c ra-rewrite.c \
31	real.c recog.c reg-stack.c regclass.c regmove.c regrename.c \
32	reload.c reload1.c reorg.c resource.c rtl.c rtlanal.c rtl-error.c \
33	sbitmap.c sched-deps.c sched-ebb.c sched-rgn.c sched-vis.c sdbout.c \
34	sibcall.c simplify-rtx.c sreal.c stmt.c stor-layout.c stringpool.c \
35	targhooks.c timevar.c toplev.c tracer.c tree.c tree-dump.c unroll.c \
36	varasm.c varray.c version.c vmsdbgout.c xcoffout.c alloc-pool.c \
37	et-forest.c cfghooks.c bt-load.c pretty-print.c ggc-page.c web.c
38
39# Miscellaneous files.
40SRCS+=	hashtable.c tree-inline.c tree-optimize.c cgraph.c cgraphunit.c
41
42# Host hooks.
43SRCS+=	host-default.c
44
45# C and ObjC files.
46SRCS+=	attribs.c c-errors.c c-lex.c c-pragma.c c-decl.c c-typeck.c \
47	c-convert.c c-aux-info.c c-common.c c-opts.c c-format.c c-semantics.c \
48	c-incpath.c cppdefault.c c-ppoutput.c c-cppbuiltin.c prefix.c \
49	c-objc-common.c c-dump.c c-pch.c
50
51# Files shared by cc1plus, cc1 and cc1obj
52SRCS+=	c-pretty-print.c
53
54# Machine-dependent files.
55SRCS+=	${GCC_CPU}.c
56.if exists(${GCCDIR}/config/${GCC_CPU}/${GCC_CPU}-c.c)
57SRCS+=	${GCC_CPU}-c.c
58.endif
59
60# libcpp files.
61SRCS+=	cpplib.c cpplex.c cppmacro.c cppexp.c cppfiles.c cpptrad.c \
62	cpphash.c cpperror.c cppinit.c cppcharset.c \
63	line-map.c mkdeps.c cpppch.c
64
65# insn-* gunk -- headers are built in cc_tools, as they are used by the
66# "build-tools"
67.for F in attrtab emit extract opinit output peep recog
68SRCS+=	insn-$F.c
69CLEANFILES+= insn-$F.c
70insn-$F.c: ${.OBJDIR}/../cc_tools/gen$F ${MD_FILE}
71	${.OBJDIR}/../cc_tools/gen$F ${MD_FILE} > insn-$F.c
72.endfor
73.for F in modes
74SRCS+=	insn-$F.c
75CLEANFILES+= insn-$F.c
76insn-$F.c: ${.OBJDIR}/../cc_tools/gen$F
77	${.OBJDIR}/../cc_tools/gen$F > insn-$F.c
78.endfor
79
80CFLAGS+=	-DHAVE_CONFIG_H
81CFLAGS+=	-DTARGET_NAME=\"${target}\" -DIN_GCC
82
83# c-pch.o needs extra defines. Replicate the rule here rather than
84# pollute compiler command line for all other files.
85c-pch.o: c-pch.c
86	${CC} ${CFLAGS} -DHOST_MACHINE=\"${host}\" \
87		 -DTARGET_MACHINE=\"${target}\" -c ${.IMPSRC}
88
89.include <bsd.lib.mk>
90