* stabs.c (s_stab_generic): Call the listing functions before
[deliverable/binutils-gdb.git] / gas / mpw-config.in
CommitLineData
ea838f99
SS
1# Configuration fragment for GAS.
2
9e4eebc2
SS
3Set target_arch `echo {target_canonical} | sed -e 's/-.*-.*//'`
4
6144e9a9
SS
5If "{target_arch}" =~ /powerpc/
6 Set short_arch_name "ppc"
7 Set target_cpu "powerpc"
8Else
9 Set short_arch_name "{target_arch}"
10End If
11
f64fd87f 12# The following works for many configurations, though not all.
9e4eebc2 13
a23e2b7c
SS
14Set obj_format `echo {target_canonical} | sed -e 's/.*-.*-//'`
15
d21041b3
SS
16Set bfd_gas no
17
f64fd87f 18Set TDEFINES ""
a23e2b7c 19
6144e9a9
SS
20Set EXTRA_OBJECTS ""
21
90f543f6
SS
22# Default emulation.
23
24Set em generic
25
a23e2b7c
SS
26If "{target_canonical}" =~ /m68k-apple-macos/
27 Set obj_format "coff"
d21041b3 28 Set TDEFINES '-d M68KCOFF'
6144e9a9 29 Set EXTRA_OBJECTS '"{o}"m68k-parse.c.o'
90f543f6 30
6144e9a9
SS
31Else If "{target_canonical}" =~ /powerpc-apple-macos/
32 Set obj_format "coff"
d21041b3 33 Set bfd_gas yes
90f543f6
SS
34 Set em macos
35
d21041b3 36Else If "{target_canonical}" =~ /i386-unknown-go32/
a23e2b7c 37 Set obj_format "coff"
d21041b3 38 Set TDEFINES '-d I386COFF'
90f543f6 39
d21041b3
SS
40Else If "{target_canonical}" =~ /m68k-unknown-coff/
41 Set TDEFINES '-d M68KCOFF'
90f543f6 42
a23e2b7c 43Else If "{target_canonical}" =~ /mips-idt-ecoff/
d21041b3 44 Set bfd_gas yes
a23e2b7c 45 Set TDEFINES '-d TARGET_BYTES_BIG_ENDIAN'
90f543f6
SS
46
47# start-sanitize-gm
48Else If "{target_canonical}" =~ /mips-gm-magic/
49 Set obj_format "ecoff"
50 Set bfd_gas yes
51 Set TDEFINES '-d TARGET_BYTES_BIG_ENDIAN'
52# end-sanitize-gm
53
d21041b3
SS
54Else If "{target_canonical}" =~ /sh-hitachi-hms/
55 Set obj_format "coff"
56 forward-include "{srcroot}"opcodes:sh-opc.h 'opcodes/sh-opc.h'
a23e2b7c 57End If
9e4eebc2 58
6144e9a9
SS
59forward-include "{srcdir}"config:tc-{short_arch_name}.c targ-cpu.c
60forward-include "{srcdir}"config:tc-{short_arch_name}.h targ-cpu.h
9e4eebc2 61
a23e2b7c
SS
62forward-include "{srcdir}"config:obj-{obj_format}.c obj-format.c
63forward-include "{srcdir}"config:obj-{obj_format}.h obj-format.h
9e4eebc2 64
90f543f6 65forward-include "{srcdir}"config:te-{em}.h targ-env.h
9e4eebc2 66
a23e2b7c
SS
67# Special cases for float handling.
68
9e4eebc2
SS
69If "{target_arch}" =~ /ns32k/
70 forward-include "{srcdir}"config:atof-ns32k.c atof-targ.c
71Else If "{target_arch}" =~ /tahoe/
72 forward-include "{srcdir}"config:atof-tahoe.c atof-targ.c
73Else If "{target_arch}" =~ /vax/
74 forward-include "{srcdir}"config:atof-vax.c atof-targ.c
75Else
76 # Use IEEE by default.
77 forward-include "{srcdir}"config:atof-ieee.c atof-targ.c
78End If
a23e2b7c 79
6144e9a9
SS
80Echo '# From mpw-config.in' > "{o}"mk.tmp
81Echo "TDEFINES = " {TDEFINES} >> "{o}"mk.tmp
82Echo "EXTRA_OBJECTS = " {EXTRA_OBJECTS} >> "{o}"mk.tmp
83# (We use the -n option here so as not to get extra spaces inserted)
84Echo -n 'TARG_CPU_DEP = {TARG_CPU_DEP_' >> "{o}"mk.tmp
85Echo -n {short_arch_name} >> "{o}"mk.tmp
86Echo -n '}' >> "{o}"mk.tmp
87Echo '# End from mpw-config.in' >> "{o}"mk.tmp
88
89Echo '/* conf. Generated by mpw-configure. */' > "{o}"conf.new
90Echo -n '#define TARGET_CPU "' >> "{o}"conf.new
91Echo -n "{target_cpu}" >> "{o}"conf.new
92Echo '"' >> "{o}"conf.new
93Echo -n '#define TARGET_ALIAS "' >> "{o}"conf.new
94Echo -n "{target_alias}" >> "{o}"conf.new
95Echo '"' >> "{o}"conf.new
96Echo -n '#define TARGET_CANONICAL "' >> "{o}"conf.new
97Echo -n "{target_canonical}" >> "{o}"conf.new
98Echo '"' >> "{o}"conf.new
99Echo '#include "mpw.h"' >> "{o}"conf.new
d21041b3 100If "{bfd_gas}" =~ /yes/
6144e9a9 101 Echo "#define BFD_ASSEMBLER" >> "{o}"conf.new
d21041b3 102Else
6144e9a9 103 Echo "#define MANY_SEGMENTS" >> "{o}"conf.new
d21041b3 104End If
6144e9a9
SS
105Echo '#define CR_EOL' >> "{o}"conf.new
106Echo '#define OBJ_COFF_OMIT_TIMESTAMP' >> "{o}"conf.new
107Echo '#define LOSING_COMPILER' >> "{o}"conf.new
d21041b3 108
6144e9a9 109MoveIfChange "{o}"conf.new "{o}"conf
a23e2b7c 110
6144e9a9 111sed -e "s/@srcdir@/{srcdir}/" "{srcdir}"gdbinit.in > "{o}"_gdbinit
This page took 0.146165 seconds and 4 git commands to generate.