mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-21 18:39:34 +08:00
Tue Apr 1 16:24:28 1997 Klaus Kaempf <kkaempf@progis.de>
* config-gas.com: Update to handle both vax and alpha. * makefile.vms: Update to use config-gas. * conf-a-gas.com: Remove file.
This commit is contained in:
@ -41,7 +41,6 @@ bignum-copy.c
|
|||||||
bignum.h
|
bignum.h
|
||||||
bit_fix.h
|
bit_fix.h
|
||||||
cond.c
|
cond.c
|
||||||
conf-a-gas.com
|
|
||||||
conf.in
|
conf.in
|
||||||
config
|
config
|
||||||
config-gas.com
|
config-gas.com
|
||||||
|
@ -1,3 +1,9 @@
|
|||||||
|
Tue Apr 1 16:24:28 1997 Klaus Kaempf <kkaempf@progis.de>
|
||||||
|
|
||||||
|
* config-gas.com: Update to handle both vax and alpha.
|
||||||
|
* makefile.vms: Update to use config-gas.
|
||||||
|
* conf-a-gas.com: Remove file.
|
||||||
|
|
||||||
Tue Apr 1 16:08:21 1997 Ian Lance Taylor <ian@cygnus.com>
|
Tue Apr 1 16:08:21 1997 Ian Lance Taylor <ian@cygnus.com>
|
||||||
|
|
||||||
* Makefile.in: Remove unnecessary itbl-parse.h, ibtl-parse.c, and
|
* Makefile.in: Remove unnecessary itbl-parse.h, ibtl-parse.c, and
|
||||||
|
@ -1,168 +0,0 @@
|
|||||||
$!
|
|
||||||
$! This file sets things up to build gas on a openVMS/Alpha system to generate
|
|
||||||
$! object files for a openVMS/Alpha system.
|
|
||||||
$! We do not use the configure script, since there is no /bin/sh to execute it.
|
|
||||||
$!
|
|
||||||
$! If you are running this file, then obviously the host is alpha-dec-vms.
|
|
||||||
$!
|
|
||||||
$gas_host="vms"
|
|
||||||
$!
|
|
||||||
$cpu_type="alpha"
|
|
||||||
$emulation="generic"
|
|
||||||
$obj_format="evax"
|
|
||||||
$atof="ieee"
|
|
||||||
$!
|
|
||||||
$ DELETE = "delete/noConfirm"
|
|
||||||
$ ECHO = "write sys$output"
|
|
||||||
$!
|
|
||||||
$! Target specific information
|
|
||||||
$call link targ-cpu.c [.config]tc-'cpu_type'.c
|
|
||||||
$call link targ-cpu.h [.config]tc-'cpu_type'.h
|
|
||||||
$call link targ-env.h [.config]te-'emulation'.h
|
|
||||||
$!
|
|
||||||
$! Code to handle the object file format.
|
|
||||||
$call link obj-format.h [.config]obj-'obj_format'.h
|
|
||||||
$call link obj-format.c [.config]obj-'obj_format'.c
|
|
||||||
$!
|
|
||||||
$! Code to handle floating point.
|
|
||||||
$call link atof-targ.c [.config]atof-'atof'.c
|
|
||||||
$!
|
|
||||||
$!
|
|
||||||
$! Create the file version.opt, which helps identify the executable.
|
|
||||||
$!
|
|
||||||
$if f$trnlnm("IFILE$").nes."" then close/noLog ifile$
|
|
||||||
$search Makefile.in "VERSION="/Exact/Output=config-gas-tmp.tmp
|
|
||||||
$open ifile$ config-gas-tmp.tmp
|
|
||||||
$read ifile$ line
|
|
||||||
$close ifile$
|
|
||||||
$DELETE config-gas-tmp.tmp;*
|
|
||||||
$! Discard "VERSION=" and "\n" parts.
|
|
||||||
$ijk=f$locate("=",line)+1
|
|
||||||
$line=f$extract(ijk,f$length(line)-ijk,line)
|
|
||||||
$! [what "\n" part?? this seems to be useless, but is benign]
|
|
||||||
$ijk=f$locate("\n",line)
|
|
||||||
$line=f$extract(0,ijk,line)
|
|
||||||
$!
|
|
||||||
$ if f$search("version.opt").nes."" then DELETE version.opt;*
|
|
||||||
$copy _NL: version.opt
|
|
||||||
$open/Append ifile$ version.opt
|
|
||||||
$write ifile$ "identification="+""""+line+""""
|
|
||||||
$close ifile$
|
|
||||||
$!
|
|
||||||
$! Now write config.h.
|
|
||||||
$!
|
|
||||||
$ if f$search("config.h").nes."" then DELETE config.h;*
|
|
||||||
$copy _NL: config.h
|
|
||||||
$open/Append ifile$ config.h
|
|
||||||
$write ifile$ "/* config.h. Generated by config-gas.com. */
|
|
||||||
$write ifile$ "#ifndef GAS_VERSION"
|
|
||||||
$write ifile$ "#define GAS_VERSION """,line,""""
|
|
||||||
$write ifile$ "#endif"
|
|
||||||
$write ifile$ "/*--*/"
|
|
||||||
$append [.config]vms-a-conf.h ifile$:
|
|
||||||
$close ifile$
|
|
||||||
$ECHO "Created config.h."
|
|
||||||
$!
|
|
||||||
$! Check for, and possibly make, header file <unistd.h>.
|
|
||||||
$!
|
|
||||||
$ if f$search("tmp-chk-h.*").nes."" then DELETE tmp-chk-h.*;*
|
|
||||||
$!can't use simple `#include HDR' with `gcc /Define="HDR=<foo.h>"'
|
|
||||||
$!because the 2.6.[0-3] preprocessor handles it wrong (VMS-specific gcc bug)
|
|
||||||
$ create tmp-chk-h.c
|
|
||||||
int tmp_chk_h; /* guarantee non-empty output */
|
|
||||||
#ifdef HAVE_STDIO_H
|
|
||||||
#include <stdio.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_UNISTD_H
|
|
||||||
#include <unistd.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_UNIXIO_H
|
|
||||||
#include <unixio.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_UNIXLIB_H
|
|
||||||
#include <unixlib.h>
|
|
||||||
#endif
|
|
||||||
$ on warning then continue
|
|
||||||
$ CHECK = "call tmp_chk_h"
|
|
||||||
$ CHECK "HAVE_STDIO_H"
|
|
||||||
$ if .not.$status
|
|
||||||
$ then type sys$input:
|
|
||||||
|
|
||||||
? could not compile <stdio.h>.
|
|
||||||
Since gcc is not set up correctly, gas configuration cannot proceed.
|
|
||||||
|
|
||||||
$ DELETE tmp-chk-h.c;*
|
|
||||||
$ exit %x002C
|
|
||||||
$ endif
|
|
||||||
$!
|
|
||||||
$ CHECK "HAVE_UNISTD_H"
|
|
||||||
$ if .not.$status
|
|
||||||
$ then
|
|
||||||
$ if f$trnlnm("HFILE$").nes."" then close/noLog hfile$
|
|
||||||
$ CHECK "HAVE_UNIXIO_H"
|
|
||||||
$ got_unixio = ($status .and. 1)
|
|
||||||
$ CHECK "HAVE_UNIXLIB_H"
|
|
||||||
$ got_unixlib = ($status .and. 1)
|
|
||||||
$ create []unistd.h !with rudimentary contents
|
|
||||||
/* <unistd.h> substitute for building gas */
|
|
||||||
#ifndef UNISTD_H
|
|
||||||
#define UNISTD_H
|
|
||||||
|
|
||||||
$ open/Append hfile$ []unistd.h
|
|
||||||
$ if got_unixio
|
|
||||||
$ then write hfile$ "#include <unixio.h>"
|
|
||||||
$ else append sys$input: hfile$:
|
|
||||||
/* some of the routines normally prototyped in <unixio.h> */
|
|
||||||
extern int creat(), open(), close(), read(), write();
|
|
||||||
extern int access(), dup(), dup2(), fstat(), stat();
|
|
||||||
extern long lseek();
|
|
||||||
$ endif
|
|
||||||
$ write hfile$ ""
|
|
||||||
$ if got_unixlib
|
|
||||||
$ then write hfile$ "#include <unixlib.h>"
|
|
||||||
$ else append sys$input: hfile$:
|
|
||||||
/* some of the routines normally prototyped in <unixlib.h> */
|
|
||||||
extern char *sbrk(), *getcwd(), *cuserid();
|
|
||||||
extern int brk(), chdir(), chmod(), chown(), mkdir();
|
|
||||||
extern unsigned getuid(), umask();
|
|
||||||
$ endif
|
|
||||||
$ append sys$input: hfile$:
|
|
||||||
|
|
||||||
#endif /*UNISTD_H*/
|
|
||||||
$ close hfile$
|
|
||||||
$ ECHO "Created ""[]unistd.h""."
|
|
||||||
$ endif !gcc '#include <unistd.h>' failed
|
|
||||||
$ DELETE tmp-chk-h.c;*
|
|
||||||
$
|
|
||||||
$tmp_chk_h: subroutine
|
|
||||||
$ set noOn
|
|
||||||
$ hname = f$edit("<" + (p1 - "HAVE_" - "_H") + ".h>","LOWERCASE")
|
|
||||||
$ write sys$output "Checking for ''hname'."
|
|
||||||
$ if f$search("tmp-chk-h.obj").nes."" then DELETE tmp-chk-h.obj;*
|
|
||||||
$ define/noLog sys$error _NL: !can't use /User_Mode here due to gcc
|
|
||||||
$ define/noLog sys$output _NL: ! driver's use of multiple image activation
|
|
||||||
$ gcc /Include=([],[-.include]) /Define=("''p1'") tmp-chk-h.c
|
|
||||||
$!can't just check $status; gcc 2.6.[0-3] preprocessor doesn't set it correctly
|
|
||||||
$ ok = (($status.and.1).and.(f$search("tmp-chk-h.obj").nes."")) .or. %x10000000
|
|
||||||
$ deassign sys$error !restore, more or less
|
|
||||||
$ deassign sys$output
|
|
||||||
$ if ok then DELETE tmp-chk-h.obj;*
|
|
||||||
$ exit ok
|
|
||||||
$ endsubroutine !tmp_chk_h
|
|
||||||
$
|
|
||||||
$!
|
|
||||||
$! Done
|
|
||||||
$!
|
|
||||||
$ if f$search("config.status") .nes. "" then DELETE config.status;*
|
|
||||||
$ create config.status
|
|
||||||
Links are now set up for use with an Alpha running openVMS.
|
|
||||||
$ type config.status
|
|
||||||
$exit
|
|
||||||
$!
|
|
||||||
$!
|
|
||||||
$link:
|
|
||||||
$subroutine
|
|
||||||
$ if f$search(p1).nes."" then DELETE 'p1';*
|
|
||||||
$ copy 'p2' 'p1'
|
|
||||||
$ ECHO "Copied ''f$edit(p2,"LOWERCASE")' to ''f$edit(p1,"LOWERCASE")'."
|
|
||||||
$endsubroutine
|
|
@ -3,15 +3,23 @@ $! This file sets things up to build gas on a VMS system to generate object
|
|||||||
$! files for a VMS system. We do not use the configure script, since we
|
$! files for a VMS system. We do not use the configure script, since we
|
||||||
$! do not have /bin/sh to execute it.
|
$! do not have /bin/sh to execute it.
|
||||||
$!
|
$!
|
||||||
$! If you are running this file, then obviously the host is vax-dec-vms.
|
|
||||||
$! [That's no longer obvious, but there's not much we can do about alpha yet.]
|
|
||||||
$!
|
$!
|
||||||
$gas_host="vms"
|
$gas_host="vms"
|
||||||
$!
|
$!
|
||||||
|
$arch_indx = 1 + ((f$getsyi("CPU").ge.128).and.1) ! vax==1, alpha==2
|
||||||
|
$arch = f$element(arch_indx,"|","|VAX|Alpha|")
|
||||||
|
$if arch .eqs. "VAX"
|
||||||
|
$then
|
||||||
$cpu_type="vax"
|
$cpu_type="vax"
|
||||||
$emulation="generic"
|
|
||||||
$obj_format="vms"
|
$obj_format="vms"
|
||||||
$atof="vax"
|
$atof="vax"
|
||||||
|
$else
|
||||||
|
$ cpu_type="alpha"
|
||||||
|
$ obj_format="evax"
|
||||||
|
$ atof="ieee"
|
||||||
|
$endif
|
||||||
|
$
|
||||||
|
$emulation="generic"
|
||||||
$!
|
$!
|
||||||
$ DELETE = "delete/noConfirm"
|
$ DELETE = "delete/noConfirm"
|
||||||
$ ECHO = "write sys$output"
|
$ ECHO = "write sys$output"
|
||||||
@ -60,7 +68,12 @@ $write ifile$ "#ifndef GAS_VERSION"
|
|||||||
$write ifile$ "#define GAS_VERSION """,line,""""
|
$write ifile$ "#define GAS_VERSION """,line,""""
|
||||||
$write ifile$ "#endif"
|
$write ifile$ "#endif"
|
||||||
$write ifile$ "/*--*/"
|
$write ifile$ "/*--*/"
|
||||||
|
$if arch .eqs. "VAX"
|
||||||
|
$then
|
||||||
$append [.config]vms-conf.h ifile$:
|
$append [.config]vms-conf.h ifile$:
|
||||||
|
$else
|
||||||
|
$ append [.config]vms-a-conf.h ifile$:
|
||||||
|
$endif
|
||||||
$close ifile$
|
$close ifile$
|
||||||
$ECHO "Created config.h."
|
$ECHO "Created config.h."
|
||||||
$!
|
$!
|
||||||
@ -155,9 +168,10 @@ $!
|
|||||||
$! Done
|
$! Done
|
||||||
$!
|
$!
|
||||||
$ if f$search("config.status") .nes. "" then DELETE config.status;*
|
$ if f$search("config.status") .nes. "" then DELETE config.status;*
|
||||||
$ create config.status
|
$ open/write cfile []config.status
|
||||||
Links are now set up for use with a vax running VMS.
|
$ write cfile "Links are now set up for use with a "+arch+" running VMS."
|
||||||
$ type config.status
|
$ close cfile
|
||||||
|
$ type []config.status
|
||||||
$exit
|
$exit
|
||||||
$!
|
$!
|
||||||
$!
|
$!
|
||||||
|
@ -6,10 +6,9 @@
|
|||||||
|
|
||||||
ifeq ($(CC),gcc)
|
ifeq ($(CC),gcc)
|
||||||
DEFS=
|
DEFS=
|
||||||
CFLAGS=/cc1="-fno-exceptions -g0"/include=([],[-.bfd],[.config],[-.include],[-])$(DEFS)
|
CFLAGS=/include=([],[-.bfd],[.config],[-.include],[-])$(DEFS)
|
||||||
LFLAGS=
|
LFLAGS=
|
||||||
LIBS=,GNU:[000000]LIBGCC2/lib,GNU:[000000]LIBGCCLIB/lib,\
|
LIBS=,GNU:[000000]libgcc/lib,sys$$library:vaxcrtl.olb/lib,GNU:[000000]crt0.obj
|
||||||
sys$$library:vaxcrtl.olb/lib,GNU:[000000]crt0.obj
|
|
||||||
else
|
else
|
||||||
DEFS=/define=("table_size_of_flonum_powers_of_ten"="tabsiz_flonum_powers_of_ten",\
|
DEFS=/define=("table_size_of_flonum_powers_of_ten"="tabsiz_flonum_powers_of_ten",\
|
||||||
"_bfd_generic_get_section_contents_in_window"="_bfd_generic_get_win_section_cont",\
|
"_bfd_generic_get_section_contents_in_window"="_bfd_generic_get_win_section_cont",\
|
||||||
@ -30,6 +29,7 @@ LIBIBERTY = [-.libiberty]libiberty.olb
|
|||||||
LIBBFD = [-.bfd]libbfd.olb
|
LIBBFD = [-.bfd]libbfd.olb
|
||||||
LIBOPCODES = [-.opcodes]libopcodes.olb
|
LIBOPCODES = [-.opcodes]libopcodes.olb
|
||||||
|
|
||||||
|
all: config.status [-.bfd]bfd.h as.exe gasp.exe
|
||||||
|
|
||||||
as.exe: $(OBJS) $(LIBOPCODES) $(LIBBFD) $(LIBIBERTY)
|
as.exe: $(OBJS) $(LIBOPCODES) $(LIBBFD) $(LIBIBERTY)
|
||||||
link$(LFLAGS)/exe=$@ $(OBJS),$(LIBOPCODES)/lib,$(LIBBFD)/lib,$(LIBIBERTY)/lib$(LIBS)
|
link$(LFLAGS)/exe=$@ $(OBJS),$(LIBOPCODES)/lib,$(LIBBFD)/lib,$(LIBIBERTY)/lib$(LIBS)
|
||||||
@ -37,6 +37,9 @@ as.exe: $(OBJS) $(LIBOPCODES) $(LIBBFD) $(LIBIBERTY)
|
|||||||
gasp.exe: gasp.obj $(LIBBFD) $(LIBIBERTY)
|
gasp.exe: gasp.obj $(LIBBFD) $(LIBIBERTY)
|
||||||
link$(LFLAGS)/exe=$@ gasp.obj,$(LIBBFD)/lib,$(LIBIBERTY)/lib$(LIBS)
|
link$(LFLAGS)/exe=$@ gasp.obj,$(LIBBFD)/lib,$(LIBIBERTY)/lib$(LIBS)
|
||||||
|
|
||||||
|
config.status:
|
||||||
|
$$ @config-gas
|
||||||
|
|
||||||
targ-cpu.c: [.config]tc-alpha.c
|
targ-cpu.c: [.config]tc-alpha.c
|
||||||
copy $< $@
|
copy $< $@
|
||||||
targ-cpu.h: [.config]tc-alpha.h
|
targ-cpu.h: [.config]tc-alpha.h
|
||||||
@ -51,3 +54,20 @@ atof-targ.c: [.config]atof-ieee.c
|
|||||||
copy $< $@
|
copy $< $@
|
||||||
|
|
||||||
targ-cpu.obj: targ-cpu.c targ-cpu.h [.config]atof-vax.c
|
targ-cpu.obj: targ-cpu.c targ-cpu.h [.config]atof-vax.c
|
||||||
|
|
||||||
|
[-.bfd]bfd.h:
|
||||||
|
$(CD) [-.bfd]
|
||||||
|
gmake -f makefile.vms
|
||||||
|
$(CD) [-.gas]
|
||||||
|
|
||||||
|
clean:
|
||||||
|
$$ purge
|
||||||
|
$(RM) *.obj;
|
||||||
|
$(RM) *.exe;
|
||||||
|
$(RM) atof-targ.c;
|
||||||
|
$(RM) obj-format.c;
|
||||||
|
$(RM) obj-format.h;
|
||||||
|
$(RM) targ-env.h;
|
||||||
|
$(RM) targ-cpu.h;
|
||||||
|
$(RM) targ-cpu.c;
|
||||||
|
$(RM) config.status;
|
||||||
|
Reference in New Issue
Block a user