Makefile (130325) | Makefile (132751) |
---|---|
1# $FreeBSD: head/gnu/usr.bin/cc/cc_tools/Makefile 130325 2004-06-11 00:35:29Z peter $ | 1# $FreeBSD: head/gnu/usr.bin/cc/cc_tools/Makefile 132751 2004-07-28 05:27:21Z kan $ |
2 3# 4# This could probably be merged with ../cc_int/Makefile, but bsd.lib.mk 5# is such a !@#!*#% nightmare because of how it reprograms the dependencies, 6# suffix rules, SRCS, etc. It's easiest to cheat by using bsd.prog.mk and 7# SRCS to get dependencies. 8# 9 10# 11# ../Makefile.inc will put an absolute path to our objdir in CFLAGS. 12# Prevent mkdep from using it, so that we don't have to give rules for 13# aliases of generated headers. 14# 15CFLAGS+= -I. 16 17.include "../Makefile.inc" 18 | 2 3# 4# This could probably be merged with ../cc_int/Makefile, but bsd.lib.mk 5# is such a !@#!*#% nightmare because of how it reprograms the dependencies, 6# suffix rules, SRCS, etc. It's easiest to cheat by using bsd.prog.mk and 7# SRCS to get dependencies. 8# 9 10# 11# ../Makefile.inc will put an absolute path to our objdir in CFLAGS. 12# Prevent mkdep from using it, so that we don't have to give rules for 13# aliases of generated headers. 14# 15CFLAGS+= -I. 16 17.include "../Makefile.inc" 18 |
19.PATH: ${GCCDIR} | 19.PATH: ${GCCDIR} ${GCCDIR}/f |
20 21CFLAGS+= -DGENERATOR_FILE 22 | 20 21CFLAGS+= -DGENERATOR_FILE 22 |
23# |
|
23#----------------------------------------------------------------------- | 24#----------------------------------------------------------------------- |
25# Build 'pocket' libiberty exclusively for build tools use. 26 27LIBIBERTY_SRCS= choose-temp.c concat.c cp-demangle.c cp-demint.c cplus-dem.c \ 28 dyn-string.c errors.c fibheap.c \ 29 getpwd.c getruntime.c hashtab.c hex.c lbasename.c make-temp-file.c \ 30 md5.c obstack.c partition.c pexecute.c physmem.c splay-tree.c xexit.c \ 31 xmalloc.c xmemdup.c xstrdup.c xstrerror.c xexit.c 32LIBIBERTY_OBJS= ${LIBIBERTY_SRCS:R:S/$/.o/g} 33 34SRCS+= ${LIBIBERTY_SRCS} 35 36LIBIBERTY=libiberty.a 37${LIBIBERTY}: ${LIBIBERTY_OBJS} 38 @rm -f ${.TARGET} 39 @${AR} cq ${.TARGET} `lorder ${LIBIBERTY_OBJS} | tsort -q` 40 ${RANLIB} ${.TARGET} 41CLEANFILES+= ${LIBIBERTY} 42 43# 44#----------------------------------------------------------------------- 45# options 46OPTION_FILES=${GCCDIR}/f/lang.opt ${GCCDIR}/c.opt ${GCCDIR}/common.opt 47 48.ORDER: options.h options.c 49options.h options.c: opts.sh ${OPTION_FILES} 50 /bin/sh ${GCCDIR}/opts.sh mv options.c options.h ${OPTION_FILES} 51 52 53GENSRCS+= options.c options.h 54CLEANFILES+= options.c options.h 55 56#----------------------------------------------------------------------- |
|
24# insn-* gunk 25 26.for F in attr codes config flags constants 27insn-$F.h: gen$F ${MD_FILE} 28 ./gen$F ${MD_FILE} > insn-$F.h 29GENSRCS+= insn-$F.h 30.endfor 31 --- 6 unchanged lines hidden (view full) --- 38GENSRCS+= gen-time-stamp 39gen-time-stamp: genattr genattrtab genconditions genconstants genemit \ 40 genextract gengtype genopinit genoutput genpeep genrecog 41 touch ${.TARGET} 42 43.for F in attr codes config emit extract flags opinit output peep recog 44build-tools: gen$F 45 | 57# insn-* gunk 58 59.for F in attr codes config flags constants 60insn-$F.h: gen$F ${MD_FILE} 61 ./gen$F ${MD_FILE} > insn-$F.h 62GENSRCS+= insn-$F.h 63.endfor 64 --- 6 unchanged lines hidden (view full) --- 71GENSRCS+= gen-time-stamp 72gen-time-stamp: genattr genattrtab genconditions genconstants genemit \ 73 genextract gengtype genopinit genoutput genpeep genrecog 74 touch ${.TARGET} 75 76.for F in attr codes config emit extract flags opinit output peep recog 77build-tools: gen$F 78 |
46gen$F: gen$F.o rtl.o obstack.o print-rtl.o bitmap.o errors.o gensupport.o \ 47 ggc-none.o hashtab.o read-rtl.o concat.o insn-conditions.o | 79gen$F: gen$F.o rtl.o print-rtl.o bitmap.o gensupport.o ggc-none.o \ 80 read-rtl.o insn-conditions.o min-insn-modes.o ${LIBIBERTY} |
48 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 49 50GENSRCS+= gen$F.c 51CLEANFILES+= gen$F 52.endfor 53 54# 55# genattrtab needs more complex build rule 56# 57build-tools: genattrtab 58 | 81 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 82 83GENSRCS+= gen$F.c 84CLEANFILES+= gen$F 85.endfor 86 87# 88# genattrtab needs more complex build rule 89# 90build-tools: genattrtab 91 |
59genattrtab : genattrtab.o rtl.o obstack.o print-rtl.o bitmap.o errors.o \ 60 gensupport.o ggc-none.o hashtab.o read-rtl.o concat.o \ 61 insn-conditions.o genautomata.o varray.o getruntime.o | 92genattrtab : genattrtab.o rtl.o print-rtl.o bitmap.o gensupport.o ggc-none.o \ 93 read-rtl.o insn-conditions.o genautomata.o varray.o min-insn-modes.o \ 94 ${LIBIBERTY} |
62 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} -lm 63 64GENSRCS+= genattrtab.c 65CLEANFILES+= genattrtab 66 67# 68# genconstants and genconditions cannot depend on insn-conditions.o 69# they should be liked with dummy-conditions.o stubs instead 70# 71.for F in constants conditions 72build-tools: gen$F 73 | 95 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} -lm 96 97GENSRCS+= genattrtab.c 98CLEANFILES+= genattrtab 99 100# 101# genconstants and genconditions cannot depend on insn-conditions.o 102# they should be liked with dummy-conditions.o stubs instead 103# 104.for F in constants conditions 105build-tools: gen$F 106 |
74gen$F: gen$F.o rtl.o obstack.o bitmap.o errors.o gensupport.o \ 75 ggc-none.o hashtab.o read-rtl.o concat.o dummy-conditions.o | 107gen$F: gen$F.o rtl.o bitmap.o gensupport.o ggc-none.o read-rtl.o dummy-conditions.o min-insn-modes.o ${LIBIBERTY} |
76 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 77 78GENSRCS+= gen$F.c 79CLEANFILES+= gen$F 80.endfor 81 | 108 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 109 110GENSRCS+= gen$F.c 111CLEANFILES+= gen$F 112.endfor 113 |
82.for F in check genrtl preds | 114.for F in modes check genrtl preds |
83build-tools: gen$F 84 | 115build-tools: gen$F 116 |
85gen$F: gen$F.o | 117gen$F: gen$F.o ${LIBIBERTY} |
86 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 87 88GENSRCS+= gen$F.c 89CLEANFILES+= gen$F 90.endfor 91 92.ORDER: genrtl.c genrtl.h 93genrtl.c genrtl.h: gengenrtl 94 ./gengenrtl > genrtl.c 95 ./gengenrtl -h > genrtl.h 96 97GENSRCS+= genrtl.c genrtl.h 98 | 118 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 119 120GENSRCS+= gen$F.c 121CLEANFILES+= gen$F 122.endfor 123 124.ORDER: genrtl.c genrtl.h 125genrtl.c genrtl.h: gengenrtl 126 ./gengenrtl > genrtl.c 127 ./gengenrtl -h > genrtl.h 128 129GENSRCS+= genrtl.c genrtl.h 130 |
99SRCS+= bitmap.c concat.c dummy-conditions.c errors.c genautomata.c \ | 131SRCS+= bitmap.c concat.c dummy-conditions.c genautomata.c \ |
100 gensupport.c getruntime.c ggc-none.c hashtab.c \ 101 obstack.c physmem.c print-rtl.c read-rtl.c rtl.c varray.c xmemdup.c 102 103#----------------------------------------------------------------------- | 132 gensupport.c getruntime.c ggc-none.c hashtab.c \ 133 obstack.c physmem.c print-rtl.c read-rtl.c rtl.c varray.c xmemdup.c 134 135#----------------------------------------------------------------------- |
136# insn modes stuff. 137 138.ORDER: insn-modes.c insn-modes.h 139insn-modes.h: genmodes 140 ./genmodes -h > insn-modes.h 141 142insn-modes.c: genmodes 143 ./genmodes > insn-modes.c 144 145min-insn-modes.c: genmodes 146 ./genmodes -m > min-insn-modes.c 147 148GENSRCS+= insn-modes.c min-insn-modes.c insn-modes.h 149 150#----------------------------------------------------------------------- |
|
104# Common parser stuff. 105 106tree-check.h: gencheck 107 ./gencheck > ${.TARGET} 108GENSRCS+= tree-check.h 109 110#----------------------------------------------------------------------- 111# Predicates stuff. --- 19 unchanged lines hidden (view full) --- 131gengtype-yacc+%DIKED.c: gengtype-yacc.c 132 cat ${.ALLSRC} > ${.TARGET} 133 sed -e "s/xmalloc/malloc/g" \ 134 -e "s/xrealloc/realloc/g" \ 135 -e "s/malloc/xmalloc/g" \ 136 -e "s/realloc/xrealloc/g" \ 137 ${.ALLSRC} > ${.TARGET} 138 | 151# Common parser stuff. 152 153tree-check.h: gencheck 154 ./gencheck > ${.TARGET} 155GENSRCS+= tree-check.h 156 157#----------------------------------------------------------------------- 158# Predicates stuff. --- 19 unchanged lines hidden (view full) --- 178gengtype-yacc+%DIKED.c: gengtype-yacc.c 179 cat ${.ALLSRC} > ${.TARGET} 180 sed -e "s/xmalloc/malloc/g" \ 181 -e "s/xrealloc/realloc/g" \ 182 -e "s/malloc/xmalloc/g" \ 183 -e "s/realloc/xrealloc/g" \ 184 ${.ALLSRC} > ${.TARGET} 185 |
139gengtype: gengtype.o gengtype-yacc+%DIKED.o gengtype-lex.o xmemdup.o | 186gengtype: gengtype.o gengtype-yacc+%DIKED.o gengtype-lex.o ${LIBIBERTY} |
140 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 141 142GENSRCS+= gengtype.c 143CLEANFILES+= gengtype 144 145gengtype-lex.o: gengtype-yacc.h 146 147.ORDER: gtype-desc.c gtype-desc.h 148gtype-desc.c gtype-desc.h: gtype-time-stamp 149 @true 150 151GENSRCS+= gtype-time-stamp 152gtype-time-stamp: gengtype ${GTFILES} 153 ./gengtype 154 touch ${.TARGET} 155 156GENSRCS+= gtype-desc.c gtype-desc.h 157CLEANFILES+= gt-*.h gtype-*.h 158 | 187 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 188 189GENSRCS+= gengtype.c 190CLEANFILES+= gengtype 191 192gengtype-lex.o: gengtype-yacc.h 193 194.ORDER: gtype-desc.c gtype-desc.h 195gtype-desc.c gtype-desc.h: gtype-time-stamp 196 @true 197 198GENSRCS+= gtype-time-stamp 199gtype-time-stamp: gengtype ${GTFILES} 200 ./gengtype 201 touch ${.TARGET} 202 203GENSRCS+= gtype-desc.c gtype-desc.h 204CLEANFILES+= gt-*.h gtype-*.h 205 |
206# |
|
159#----------------------------------------------------------------------- | 207#----------------------------------------------------------------------- |
208# Fortran build tools 209 210.if !defined(NO_FORTRAN) 211gen-time-stamp: fini 212build-tools: fini 213fini: fini.o ${LIBIBERTY} 214 ${CC} ${CFLAGS} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} 215SRCS+= fini.c 216CLEANFILES+= fini 217.endif 218 219#----------------------------------------------------------------------- |
|
160# Determine content of variables used by the target/host config files 161 162# | 220# Determine content of variables used by the target/host config files 221 222# |
163# The list of headers to go into tconfig.h | 223# The list of headers to go into tm.h |
164# | 224# |
165TARGET_INC= ansidecl.h | 225.if ${TARGET_ARCH} == "amd64" 226TARGET_INC= i386/biarch64.h 227.endif |
166TARGET_INC+= ${GCC_CPU}/${GCC_CPU}.h 167.if ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "amd64" 168TARGET_INC+= ${GCC_CPU}/unix.h 169TARGET_INC+= ${GCC_CPU}/att.h 170.endif 171.if ${TARGET_ARCH} != "alpha" 172TARGET_INC+= dbxelf.h 173TARGET_INC+= elfos.h --- 10 unchanged lines hidden (view full) --- 184.endif 185.endif 186TARGET_INC+= ${GCC_CPU}/freebsd.h 187.if ${TARGET_ARCH} == "amd64" 188TARGET_INC+= ${GCC_CPU}/x86-64.h 189TARGET_INC+= ${GCC_CPU}/freebsd64.h 190TARGET_INC+= freebsd64-fix.h 191.endif | 228TARGET_INC+= ${GCC_CPU}/${GCC_CPU}.h 229.if ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "amd64" 230TARGET_INC+= ${GCC_CPU}/unix.h 231TARGET_INC+= ${GCC_CPU}/att.h 232.endif 233.if ${TARGET_ARCH} != "alpha" 234TARGET_INC+= dbxelf.h 235TARGET_INC+= elfos.h --- 10 unchanged lines hidden (view full) --- 246.endif 247.endif 248TARGET_INC+= ${GCC_CPU}/freebsd.h 249.if ${TARGET_ARCH} == "amd64" 250TARGET_INC+= ${GCC_CPU}/x86-64.h 251TARGET_INC+= ${GCC_CPU}/freebsd64.h 252TARGET_INC+= freebsd64-fix.h 253.endif |
254.if ${TARGET_ARCH} == "powepc" 255TARGET_INC+= altivec-defs.h 256.endif |
|
192TARGET_INC+= defaults.h 193 194# 195# Use TARGET_INC as a template and build a list of target specific 196# include files for gengtype to scan 197# | 257TARGET_INC+= defaults.h 258 259# 260# Use TARGET_INC as a template and build a list of target specific 261# include files for gengtype to scan 262# |
198GCONFIG_H= ${.OBJDIR}/tconfig.h ${.CURDIR}/auto-host.h | 263GCONFIG_H= ${.CURDIR}/auto-host.h |
199 200.for H in ${TARGET_INC} 201.for D in ${GCCDIR}/config ${GCCDIR} ${.CURDIR} 202.if exists($D/$H) 203GCONFIG_H+= $D/$H 204.endif 205.endfor 206.endfor 207 208# 209# Define some variables to make blocks copied from Makefile.in happy 210# 211srcdir= ${GCCDIR} 212HASHTAB_H= ${GCCDIR}/hashtab.h | 264 265.for H in ${TARGET_INC} 266.for D in ${GCCDIR}/config ${GCCDIR} ${.CURDIR} 267.if exists($D/$H) 268GCONFIG_H+= $D/$H 269.endif 270.endfor 271.endfor 272 273# 274# Define some variables to make blocks copied from Makefile.in happy 275# 276srcdir= ${GCCDIR} 277HASHTAB_H= ${GCCDIR}/hashtab.h |
278SPLAY_TREE_H= ${GCCDIR}/splay-tree.h |
|
213out_file= ${GCCDIR}/config/${GCC_CPU}/${GCC_CPU}.c 214GTFILES_SRCDIR= ${GCCDIR} 215 216# 217# Copied unchanged from gcc/Makefile.in 218# | 279out_file= ${GCCDIR}/config/${GCC_CPU}/${GCC_CPU}.c 280GTFILES_SRCDIR= ${GCCDIR} 281 282# 283# Copied unchanged from gcc/Makefile.in 284# |
219GTFILES = $(GCONFIG_H) $(srcdir)/location.h \ 220 $(HASHTAB_H) \ 221 $(srcdir)/bitmap.h $(srcdir)/function.h $(srcdir)/rtl.h $(srcdir)/optabs.h \ 222 $(srcdir)/tree.h $(srcdir)/libfuncs.h $(srcdir)/hashtable.h $(srcdir)/real.h \ 223 $(srcdir)/varray.h $(srcdir)/ssa.h $(srcdir)/insn-addr.h $(srcdir)/cselib.h \ | 285GTFILES = $(srcdir)/input.h $(srcdir)/coretypes.h $(srcdir)/cpplib.h \ 286 $(GCONFIG_H) $(HASHTAB_H) $(SPLAY_TREE_H) \ 287 $(srcdir)/bitmap.h $(srcdir)/coverage.c $(srcdir)/function.h $(srcdir)/rtl.h \ 288 $(srcdir)/optabs.h $(srcdir)/tree.h $(srcdir)/libfuncs.h $(srcdir)/hashtable.h \ 289 $(srcdir)/real.h $(srcdir)/varray.h $(srcdir)/insn-addr.h \ 290 $(srcdir)/cselib.h $(srcdir)/basic-block.h $(srcdir)/cgraph.h \ |
224 $(srcdir)/c-common.h $(srcdir)/c-tree.h \ | 291 $(srcdir)/c-common.h $(srcdir)/c-tree.h \ |
225 $(srcdir)/basic-block.h \ 226 $(srcdir)/alias.c $(srcdir)/bitmap.c $(srcdir)/cselib.c \ 227 $(srcdir)/dwarf2out.c $(srcdir)/emit-rtl.c \ 228 $(srcdir)/except.c $(srcdir)/explow.c $(srcdir)/expr.c \ | 292 $(srcdir)/alias.c $(srcdir)/bitmap.c $(srcdir)/cselib.c $(srcdir)/cgraph.c \ 293 $(srcdir)/dbxout.c $(srcdir)/dwarf2out.c $(srcdir)/dwarf2asm.c \ 294 $(srcdir)/emit-rtl.c $(srcdir)/except.c $(srcdir)/explow.c $(srcdir)/expr.c \ |
229 $(srcdir)/fold-const.c $(srcdir)/function.c \ 230 $(srcdir)/gcse.c $(srcdir)/integrate.c $(srcdir)/lists.c $(srcdir)/optabs.c \ 231 $(srcdir)/profile.c $(srcdir)/ra-build.c $(srcdir)/regclass.c \ | 295 $(srcdir)/fold-const.c $(srcdir)/function.c \ 296 $(srcdir)/gcse.c $(srcdir)/integrate.c $(srcdir)/lists.c $(srcdir)/optabs.c \ 297 $(srcdir)/profile.c $(srcdir)/ra-build.c $(srcdir)/regclass.c \ |
232 $(srcdir)/reg-stack.c \ | 298 $(srcdir)/reg-stack.c $(srcdir)/cfglayout.c $(srcdir)/langhooks.c \ |
233 $(srcdir)/sdbout.c $(srcdir)/stmt.c $(srcdir)/stor-layout.c \ | 299 $(srcdir)/sdbout.c $(srcdir)/stmt.c $(srcdir)/stor-layout.c \ |
234 $(srcdir)/tree.c $(srcdir)/varasm.c \ 235 $(out_file) | 300 $(srcdir)/stringpool.c $(srcdir)/tree.c $(srcdir)/varasm.c $(out_file) |
236 237# 238# Build a list of frontend directories to look into 239# 240GTFILES_LANG_DIR_NAMES= 241 242.if !defined(NO_CXX) 243GTFILES_LANG_DIR_NAMES+= cp --- 22 unchanged lines hidden (view full) --- 266GTFILES_LANGS+= $L 267.endfor 268.endfor 269GTFILES+= ${GTFILES_FILES} 270 271#----------------------------------------------------------------------- 272# the host/target compiler config. 273 | 301 302# 303# Build a list of frontend directories to look into 304# 305GTFILES_LANG_DIR_NAMES= 306 307.if !defined(NO_CXX) 308GTFILES_LANG_DIR_NAMES+= cp --- 22 unchanged lines hidden (view full) --- 331GTFILES_LANGS+= $L 332.endfor 333.endfor 334GTFILES+= ${GTFILES_FILES} 335 336#----------------------------------------------------------------------- 337# the host/target compiler config. 338 |
274COMMONHDRS= config.h hconfig.h multilib.h options.h specs.h tconfig.h \ 275 tm_p.h configargs.h safe-ctype.h 276GENSRCS+= ${COMMONHDRS} gencheck.h gtyp-gen.h | 339COMMONHDRS= bconfig.h config.h configargs.h gencheck.h multilib.h \ 340 specs.h safe-ctype.h tconfig.h tm.h tm_p.h gcov-iov.h \ 341 gtyp-gen.h 342GENSRCS+= ${COMMONHDRS} |
277 278MFILE?= ${.CURDIR}/Makefile 279${COMMONHDRS}: ${MFILE} 280 281configargs.h: 282 echo 'static const char configuration_arguments[] =' > ${.TARGET} 283 echo ' "FreeBSD/${TARGET_ARCH} system compiler";' >> ${.TARGET} 284 echo 'static const char thread_model[] = "posix";' >> ${.TARGET} | 343 344MFILE?= ${.CURDIR}/Makefile 345${COMMONHDRS}: ${MFILE} 346 347configargs.h: 348 echo 'static const char configuration_arguments[] =' > ${.TARGET} 349 echo ' "FreeBSD/${TARGET_ARCH} system compiler";' >> ${.TARGET} 350 echo 'static const char thread_model[] = "posix";' >> ${.TARGET} |
351 echo 'static const struct {' >> ${.TARGET} 352 echo ' const char *name, *value;' >> ${.TARGET} 353 echo '} configure_default_options[] = {' >> ${.TARGET} 354 echo ' { "NULL", "NULL" } };' >> ${.TARGET} |
|
285 | 355 |
286hconfig.h: 287 echo '#include "auto-host.h"' > ${.TARGET} 288 echo '#include <tconfig.h>' >> ${.TARGET} | 356tconfig.h: 357 echo '#ifndef GCC_TCONFIG_H' > ${.TARGET} 358 echo '#define GCC_TCONFIG_H' >> ${.TARGET} 359 echo '#ifdef IN_GCC' >> ${.TARGET} 360 echo '# include "ansidecl.h"' >> ${.TARGET} 361 echo '#endif' >> ${.TARGET} 362 echo '#define USED_FOR_TARGET' >> ${.TARGET} 363 echo '#endif /* GCC_TCONFIG_H */' >> ${.TARGET} |
289 | 364 |
365bconfig.h: 366 echo '#ifndef GCC_BCONFIG_H' > ${.TARGET} 367 echo '#define GCC_BCONFIG_H' >> ${.TARGET} 368 echo '#include "auto-host.h"' >> ${.TARGET} 369.if exists(${GCCDIR}/config/${GCC_CPU}/${GCC_CPU}-modes.def) 370 echo '#define EXTRA_MODES_FILE "${GCC_CPU}/${GCC_CPU}-modes.def"' >> ${.TARGET} 371.endif 372 echo '#ifdef IN_GCC' >> ${.TARGET} 373 echo '# include "ansidecl.h"' >> ${.TARGET} 374 echo '#endif' >> ${.TARGET} 375 echo '#endif /* GCC_BCONFIG_H */' >> ${.TARGET} 376 |
|
290gencheck.h: 291 echo '#include "cp/cp-tree.def"' > ${.TARGET} 292 echo '#include "objc/objc-tree.def"' >> ${.TARGET} 293 294multilib.h: 295 echo 'static const char *const multilib_raw[] = { \ 296 "aout maout;", "elf !maout;", NULL };' > ${.TARGET} 297 echo 'static const char *const multilib_matches_raw[] = { \ 298 "maout maout;", "melf melf;", NULL };' >> ${.TARGET} 299 echo 'static const char *multilib_extra = "";' >> ${.TARGET} 300 echo 'static const char *multilib_options = "";'>> ${.TARGET} 301 echo 'static const char *const multilib_exclusions_raw[] = { \ 302 NULL };' >> ${.TARGET} 303 | 377gencheck.h: 378 echo '#include "cp/cp-tree.def"' > ${.TARGET} 379 echo '#include "objc/objc-tree.def"' >> ${.TARGET} 380 381multilib.h: 382 echo 'static const char *const multilib_raw[] = { \ 383 "aout maout;", "elf !maout;", NULL };' > ${.TARGET} 384 echo 'static const char *const multilib_matches_raw[] = { \ 385 "maout maout;", "melf melf;", NULL };' >> ${.TARGET} 386 echo 'static const char *multilib_extra = "";' >> ${.TARGET} 387 echo 'static const char *multilib_options = "";'>> ${.TARGET} 388 echo 'static const char *const multilib_exclusions_raw[] = { \ 389 NULL };' >> ${.TARGET} 390 |
304options.h: 305 echo '#include "cp/lang-options.h"' > ${.TARGET} 306 echo '#include "f/lang-options.h"' >> ${.TARGET} 307 echo '#include "objc/lang-options.h"' >> ${.TARGET} 308 | |
309specs.h: 310 echo '#include "cp/lang-specs.h"' > ${.TARGET} 311 echo '#include "f/lang-specs.h"' >> ${.TARGET} 312 echo '#include "objc/lang-specs.h"' >> ${.TARGET} 313 | 391specs.h: 392 echo '#include "cp/lang-specs.h"' > ${.TARGET} 393 echo '#include "f/lang-specs.h"' >> ${.TARGET} 394 echo '#include "objc/lang-specs.h"' >> ${.TARGET} 395 |
314config.h: 315 echo '#include <hconfig.h>' > ${.TARGET} 316 echo '#ifndef GENERATOR_FILE' >> ${.TARGET} 317 echo '#include "insn-constants.h"' >> ${.TARGET} 318 echo '#include "insn-flags.h"' >> ${.TARGET} 319 echo '#endif' >> ${.TARGET} | 396config.h: bconfig.h 397 echo '#include <bconfig.h>' > ${.TARGET} |
320 | 398 |
321tconfig.h: 322 echo 'struct rtx_def;' > ${.TARGET} 323 echo 'typedef struct rtx_def *rtx;' >> ${.TARGET} 324 echo 'struct rtvec_def;' >> ${.TARGET} 325 echo 'typedef struct rtvec_def *rtvec;' >> ${.TARGET} 326 echo 'union tree_node;' >> ${.TARGET} 327 echo 'typedef union tree_node *tree;' >> ${.TARGET} 328 echo '#ifndef GTY' >> ${.TARGET} 329 echo '# define GTY(x)' >> ${.TARGET} 330 echo '#endif' >> ${.TARGET} 331 echo '' >> ${.TARGET} 332.if ${TARGET_ARCH} == "amd64" 333 echo '#include "i386/biarch64.h"' >> ${.TARGET} | 399tm.h: 400 echo '#ifndef GCC_TM_H' > ${.TARGET} 401 echo '#define GCC_TM_H' >> ${.TARGET} 402.if defined(TARGET_CPU_DEFAULT) 403 echo "#define TARGET_CPU_DEFAULT (${TARGET_CPU_DEFAULT})" >> ${.TARGET} |
334.endif | 404.endif |
335.if ${TARGET_ARCH} == "ia64" 336 echo '#define TARGET_CPU_DEFAULT (MASK_GNU_AS|MASK_GNU_LD)' >>${.TARGET} 337.endif | 405 echo '#ifdef IN_GCC' >> ${.TARGET} |
338.for H in ${TARGET_INC} 339 echo '#include "$H"' >> ${.TARGET} 340.endfor | 406.for H in ${TARGET_INC} 407 echo '#include "$H"' >> ${.TARGET} 408.endfor |
341 echo '#ifndef POSIX' >> ${.TARGET} 342 echo '# define POSIX' >> ${.TARGET} | 409 echo '#if !defined GENERATOR_FILE && !defined USED_FOR_TARGET' >> ${.TARGET} 410 echo '# include "insn-constants.h"' >> ${.TARGET} 411 echo '# include "insn-flags.h"' >> ${.TARGET} |
343 echo '#endif' >> ${.TARGET} | 412 echo '#endif' >> ${.TARGET} |
413 echo '#endif' >> ${.TARGET} |
|
344.if exists(${GCCDIR}/config/${GCC_CPU}/${GCC_CPU}-modes.def) 345 echo '#define EXTRA_MODES_FILE "${GCC_CPU}/${GCC_CPU}-modes.def"' >> ${.TARGET} | 414.if exists(${GCCDIR}/config/${GCC_CPU}/${GCC_CPU}-modes.def) 415 echo '#define EXTRA_MODES_FILE "${GCC_CPU}/${GCC_CPU}-modes.def"' >> ${.TARGET} |
346 echo '#define EXTRA_CC_MODES 1' >> ${.TARGET} | |
347.endif | 416.endif |
417 echo '#endif /* GCC_TM_H */' >> ${.TARGET} |
|
348 349tm_p.h: 350 echo '#include "${GCC_CPU}/${GCC_CPU}-protos.h"' >> ${.TARGET} 351 echo '#include "tm-preds.h"' >> ${.TARGET} 352 | 418 419tm_p.h: 420 echo '#include "${GCC_CPU}/${GCC_CPU}-protos.h"' >> ${.TARGET} 421 echo '#include "tm-preds.h"' >> ${.TARGET} 422 |
353safe-ctype.h: Makefile | 423safe-ctype.h: |
354 echo '#include <ctype.h>' > ${.TARGET} 355.for Z in TOUPPER TOLOWER ISDIGIT ISXDIGIT ISUPPER ISLOWER ISALPHA ISALNUM \ 356 ISSPACE ISPUNCT ISGRAPH ISBLANK ISPRINT ISCNTRL 357 echo '#define ${Z} ${Z:L}' >> ${.TARGET} 358.endfor 359 echo "#define ISIDST(x) \ 360 ((x) == '_' || isalpha(x))" >> ${.TARGET} 361 echo "#define ISIDNUM(x) \ --- 24 unchanged lines hidden (view full) --- 386 echo "\"$F\", " >> ${.TARGET} 387.endfor 388 echo "NULL};" >> ${.TARGET} 389 echo "static const char *lang_dir_names[] = { \"c\", " >> ${.TARGET} 390.for F in ${GTFILES_LANG_DIR_NAMES} 391 echo "\"$F\", " >> ${.TARGET} 392.endfor 393 echo "NULL};" >> ${.TARGET} | 424 echo '#include <ctype.h>' > ${.TARGET} 425.for Z in TOUPPER TOLOWER ISDIGIT ISXDIGIT ISUPPER ISLOWER ISALPHA ISALNUM \ 426 ISSPACE ISPUNCT ISGRAPH ISBLANK ISPRINT ISCNTRL 427 echo '#define ${Z} ${Z:L}' >> ${.TARGET} 428.endfor 429 echo "#define ISIDST(x) \ 430 ((x) == '_' || isalpha(x))" >> ${.TARGET} 431 echo "#define ISIDNUM(x) \ --- 24 unchanged lines hidden (view full) --- 456 echo "\"$F\", " >> ${.TARGET} 457.endfor 458 echo "NULL};" >> ${.TARGET} 459 echo "static const char *lang_dir_names[] = { \"c\", " >> ${.TARGET} 460.for F in ${GTFILES_LANG_DIR_NAMES} 461 echo "\"$F\", " >> ${.TARGET} 462.endfor 463 echo "NULL};" >> ${.TARGET} |
394 echo "#define xexit exit" >> ${.TARGET} | |
395 | 464 |
465gcov-iov.h: 466 echo "#define GCOV_VERSION ((gcov_unsigned_t)0x33303470)" >> ${.TARGET} |
|
396 397#----------------------------------------------------------------------- 398# General things. 399 400SRCS+= ${GENSRCS} 401CLEANFILES+= ${GENSRCS} 402 | 467 468#----------------------------------------------------------------------- 469# General things. 470 471SRCS+= ${GENSRCS} 472CLEANFILES+= ${GENSRCS} 473 |
403all: ${SRCS} | 474all: ${SRCS} 475build-tools: ${SRCS} |
404 405.include <bsd.prog.mk> 406 407#----------------------------------------------------------------------- 408# Fixups. 409 410# Set OBJS the same as bsd.prog.mk would do if we defined PROG. We can't 411# define PROG because we have multiple programs. 412# 413OBJS+= ${SRCS:N*.h:R:S/$/.o/g} 414CLEANFILES+= ${OBJS} 415 416.if !exists(${DEPENDFILE}) 417# Fudge pre-dependfile dependencies of objects in much the same way as | 476 477.include <bsd.prog.mk> 478 479#----------------------------------------------------------------------- 480# Fixups. 481 482# Set OBJS the same as bsd.prog.mk would do if we defined PROG. We can't 483# define PROG because we have multiple programs. 484# 485OBJS+= ${SRCS:N*.h:R:S/$/.o/g} 486CLEANFILES+= ${OBJS} 487 488.if !exists(${DEPENDFILE}) 489# Fudge pre-dependfile dependencies of objects in much the same way as |
418# bsd.prog.mk would do if we defined PROG. There are complications to 419# avoid circular dependencies. First, only make most objects depend on 420# all headers. Filter out the objects that would cause problems (i.e., 421# objects that will be used to create programs that will generate headers). 422# 423${OBJS}: ${SRCS:M*.h:Ngtype-desc.h:Ngenrtl.h:Ntree-check.h:Ntm-preds.h:Ninsn-*.h} | 490# bsd.prog.mk would do if we defined PROG. |
424 | 491 |
425${OBJS:Ngencheck.o:Ngengenrtl.o:Ngenpreds.o}: tree-check.h tm-preds.h genrtl.h | 492${OBJS}: ${COMMONHDRS} |
426 | 493 |
427${OBJS:Ngengtype*.o:Nxmemdup.o:Ngengenrtl.o:Ngencheck.o:Ngenpreds.o}: gtype-desc.h | 494dummy-conditions.o: 495gencheck.o: 496genmodes.o: |
428 | 497 |
429genextract.o: insn-config.h | 498genpreds.o: insn-modes.h 499genconstants.o: insn-modes.h genrtl.h 500gengtype.o: insn-modes.h genrtl.h gtyp-gen.h 501rtl.o: insn-modes.h gtype-desc.h genrtl.h 502bitmap.o: insn-modes.h gtype-desc.h genrtl.h 503ggc-none.o: gtype-desc.h 504gensupport.o: insn-modes.h genrtl.h 505varray.o: gtype-desc.h 506genautomata.o: insn-modes.h genrtl.h 507genconditions.o: insn-modes.h genrtl.h 508gencodes.o: insn-modes.h genrtl.h 509genconfig.o: insn-modes.h genrtl.h 510print-rtl.o: insn-modes.h genrtl.h tm-preds.h tree-check.h 511read-rtl.o: insn-modes.h genrtl.h 512genattr.o: insn-modes.h genrtl.h 513genemit.o: insn-modes.h genrtl.h 514genflags.o: insn-modes.h genrtl.h 515genopinit.o: insn-modes.h genrtl.h 516genoutput.o: insn-modes.h genrtl.h 517genpeep.o: insn-modes.h genrtl.h 518genrecog.o: insn-modes.h genrtl.h 519genextract.o: genrtl.h insn-config.h 520genattrtab.o: insn-modes.h gtype-desc.h genrtl.h 521genrtl.o: insn-modes.h genrtl.h gtype-desc.h |
430 | 522 |
431insn-conditions.o: insn-constants.h | 523insn-conditions.o: insn-constants.h tm-preds.h 524insn-modes.o: insn-modes.h 525min-insn-modes.o: insn-modes.h 526gtype-desc.o: insn-modes.h insn-config.h insn-codes.h tree-check.h |
432 433.endif | 527 528.endif |