mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-22 02:50:08 +08:00
vms changes from pat rankin
This commit is contained in:
@ -4,6 +4,7 @@ $! 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.
|
$! 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"
|
||||||
$!
|
$!
|
||||||
@ -12,8 +13,8 @@ $emulation="generic"
|
|||||||
$obj_format="vms"
|
$obj_format="vms"
|
||||||
$atof="vax"
|
$atof="vax"
|
||||||
$!
|
$!
|
||||||
$! host specific information
|
$ DELETE = "delete/noConfirm"
|
||||||
$call link host.h [.config]ho-'gas_host'.h
|
$ ECHO = "write sys$output"
|
||||||
$!
|
$!
|
||||||
$! Target specific information
|
$! Target specific information
|
||||||
$call link targ-cpu.c [.config]tc-'cpu_type'.c
|
$call link targ-cpu.c [.config]tc-'cpu_type'.c
|
||||||
@ -28,34 +29,42 @@ $! Code to handle floating point.
|
|||||||
$call link atof-targ.c [.config]atof-'atof'.c
|
$call link atof-targ.c [.config]atof-'atof'.c
|
||||||
$!
|
$!
|
||||||
$!
|
$!
|
||||||
$! Create the file version.opt, which helps identify the executalbe.
|
$! Create the file version.opt, which helps identify the executable.
|
||||||
$!
|
$!
|
||||||
$search Makefile.in "VERSION="/match=and/output=t.tmp
|
$if f$trnlnm("IFILE$").nes."" then close/noLog ifile$
|
||||||
$open ifile$ t.tmp
|
$search Makefile.in "VERSION="/Exact/Output=config-gas-tmp.tmp
|
||||||
|
$open ifile$ config-gas-tmp.tmp
|
||||||
$read ifile$ line
|
$read ifile$ line
|
||||||
$close ifile$
|
$close ifile$
|
||||||
$delete/nolog t.tmp;*
|
$DELETE config-gas-tmp.tmp;*
|
||||||
$! Discard "VERSION=" and "\n" parts.
|
$! Discard "VERSION=" and "\n" parts.
|
||||||
$ijk=f$locate("=",line)+1
|
$ijk=f$locate("=",line)+1
|
||||||
$line=f$extract(ijk,f$length(line)-ijk,line)
|
$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)
|
$ijk=f$locate("\n",line)
|
||||||
$line=f$extract(0,ijk,line)
|
$line=f$extract(0,ijk,line)
|
||||||
$!
|
$!
|
||||||
$ if f$search("version.opt").nes."" then delete/noconfirm version.opt;*
|
$ if f$search("version.opt").nes."" then DELETE version.opt;*
|
||||||
$open ifile$ version.opt/write
|
$copy _NL: version.opt
|
||||||
$write ifile$ "ident="+""""+line+""""
|
$open/Append ifile$ version.opt
|
||||||
|
$write ifile$ "identification="+""""+line+""""
|
||||||
$close ifile$
|
$close ifile$
|
||||||
$! Now write config.h.
|
$! Now write config.h.
|
||||||
$ if f$search("config.h").nes."" then delete/noconfirm config.h;*
|
$ if f$search("config.h").nes."" then DELETE config.h;*
|
||||||
$open ifile$ config.h/write
|
$copy _NL: config.h
|
||||||
$write ifile$ "#define TARGET_CPU """,cpu_type,"""
|
$open/Append ifile$ config.h
|
||||||
$write ifile$ "#define TARGET_ALIAS ""vms"""
|
$write ifile$ "/* config.h. Generated by config-gas.com. */
|
||||||
$write ifile$ "#define TARGET_CANONICAL ""vax-dec-vms"""
|
$write ifile$ "#ifndef GAS_VERSION"
|
||||||
$write ifile$ "#define GAS_VERSION """,line,""""
|
$write ifile$ "#define GAS_VERSION """,line,""""
|
||||||
|
$write ifile$ "#endif"
|
||||||
|
$write ifile$ "/*--*/"
|
||||||
|
$append [.config]vms-conf.h ifile$:
|
||||||
$close ifile$
|
$close ifile$
|
||||||
|
$ECHO "Created config.h."
|
||||||
$!
|
$!
|
||||||
$ if f$search("config.status") .nes. "" then delete config.status.*
|
$ if f$search("config.status") .nes. "" then DELETE config.status;*
|
||||||
$ open/write file config.status
|
$ copy _NL: config.status
|
||||||
|
$ open/Append file config.status
|
||||||
$ write file "Links are now set up for use with a vax running VMS."
|
$ write file "Links are now set up for use with a vax running VMS."
|
||||||
$ close file
|
$ close file
|
||||||
$ type config.status
|
$ type config.status
|
||||||
@ -64,7 +73,7 @@ $!
|
|||||||
$!
|
$!
|
||||||
$link:
|
$link:
|
||||||
$subroutine
|
$subroutine
|
||||||
$if f$search(p1).nes."" then delete/nolog 'p1';
|
$ if f$search(p1).nes."" then DELETE 'p1';*
|
||||||
$ copy 'p2' 'p1'
|
$ copy 'p2' 'p1'
|
||||||
$write sys$output "Linked ''p2' to ''p1'."
|
$ ECHO "Copied ''f$edit(p2,"LOWERCASE")' to ''f$edit(p1,"LOWERCASE")'."
|
||||||
$endsubroutine
|
$endsubroutine
|
||||||
|
132
gas/config/vms-conf.h
Normal file
132
gas/config/vms-conf.h
Normal file
@ -0,0 +1,132 @@
|
|||||||
|
/* vms-conf.h. Generated manually from conf.in,
|
||||||
|
and used by config-gas.com when constructing config.h. */
|
||||||
|
|
||||||
|
/* Define if using alloca.c. */
|
||||||
|
#ifdef __GNUC__
|
||||||
|
#undef C_ALLOCA
|
||||||
|
#else
|
||||||
|
#define C_ALLOCA
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems.
|
||||||
|
This function is required for alloca.c support on those systems. */
|
||||||
|
#undef CRAY_STACKSEG_END
|
||||||
|
|
||||||
|
/* Define if you have <alloca.h> and it should be used (not on Ultrix). */
|
||||||
|
#undef HAVE_ALLOCA_H
|
||||||
|
|
||||||
|
/* Define as __inline if that's what the C compiler calls it. */
|
||||||
|
#ifdef __GNUC__
|
||||||
|
#undef inline
|
||||||
|
#else
|
||||||
|
#define inline
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* If using the C implementation of alloca, define if you know the
|
||||||
|
direction of stack growth for your system; otherwise it will be
|
||||||
|
automatically deduced at run-time.
|
||||||
|
STACK_DIRECTION > 0 => grows toward higher addresses
|
||||||
|
STACK_DIRECTION < 0 => grows toward lower addresses
|
||||||
|
STACK_DIRECTION = 0 => direction of growth unknown
|
||||||
|
*/
|
||||||
|
#define STACK_DIRECTION (-1)
|
||||||
|
|
||||||
|
/* Should gas use high-level BFD interfaces? */
|
||||||
|
#undef BFD_ASSEMBLER
|
||||||
|
|
||||||
|
/* Some assert/preprocessor combinations are incapable of handling
|
||||||
|
certain kinds of constructs in the argument of assert. For example,
|
||||||
|
quoted strings (if requoting isn't done right) or newlines. */
|
||||||
|
#ifdef __GNUC__
|
||||||
|
#undef BROKEN_ASSERT
|
||||||
|
#else
|
||||||
|
#define BROKEN_ASSERT
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* If we aren't doing cross-assembling, some operations can be optimized,
|
||||||
|
since byte orders and value sizes don't need to be adjusted. */
|
||||||
|
#undef CROSS_COMPILE
|
||||||
|
|
||||||
|
/* Some IBM compilers can't handle some of the (rather basic) constructs
|
||||||
|
used in the 68k support code. */
|
||||||
|
#undef IBM_COMPILER_SUX
|
||||||
|
|
||||||
|
/* Some gas code wants to know these parameters. */
|
||||||
|
#define TARGET_ALIAS "vms"
|
||||||
|
#define TARGET_CPU "vax"
|
||||||
|
#define TARGET_CANONICAL "vax-dec-vms"
|
||||||
|
#define TARGET_OS "vms"
|
||||||
|
#define TARGET_VENDOR "dec"
|
||||||
|
|
||||||
|
/* Some operating systems, for example DOS, require the use of "wb" mode when
|
||||||
|
opening a binary file for writing. If only "w" is used, the file will not
|
||||||
|
be correct. However, some other systems reject such a mode. This indicates
|
||||||
|
which ../include/fopen-*.h header file we want to include, so that we can
|
||||||
|
get macros that'll do the right thing for this system. */
|
||||||
|
#undef WANT_FOPEN_BIN
|
||||||
|
|
||||||
|
/* Sometimes the system header files don't declare malloc and realloc. */
|
||||||
|
#undef NEED_DECLARATION_MALLOC
|
||||||
|
|
||||||
|
/* Sometimes the system header files don't declare free. */
|
||||||
|
#undef NEED_DECLARATION_FREE
|
||||||
|
|
||||||
|
/* Sometimes errno.h doesn't declare errno itself. */
|
||||||
|
#undef NEED_DECLARATION_ERRNO
|
||||||
|
|
||||||
|
#undef MANY_SEGMENTS
|
||||||
|
|
||||||
|
/* Needed only for sparc configuration */
|
||||||
|
#undef sparcv9
|
||||||
|
|
||||||
|
/* Define if you have the delete function. */
|
||||||
|
#define HAVE_DELETE
|
||||||
|
|
||||||
|
/* Define if you have the unlink function. */
|
||||||
|
#undef HAVE_UNLINK
|
||||||
|
|
||||||
|
/* Define if you have the <errno.h> header file. */
|
||||||
|
#define HAVE_ERRNO_H
|
||||||
|
|
||||||
|
/* Define if you have the <memory.h> header file. */
|
||||||
|
#undef HAVE_MEMORY_H
|
||||||
|
|
||||||
|
/* Define if you have the <stdarg.h> header file. */
|
||||||
|
#define HAVE_STDARG_H
|
||||||
|
|
||||||
|
/* Define if you have the <stdlib.h> header file. */
|
||||||
|
#define HAVE_STDLIB_H
|
||||||
|
|
||||||
|
/* Define if you have the <string.h> header file. */
|
||||||
|
#define HAVE_STRING_H
|
||||||
|
|
||||||
|
/* Define if you have the <strings.h> header file. */
|
||||||
|
#undef HAVE_STRINGS_H
|
||||||
|
|
||||||
|
/* Define if you have the <sys/types.h> header file. */
|
||||||
|
#ifdef __GNUC__
|
||||||
|
#define HAVE_SYS_TYPES_H
|
||||||
|
#else
|
||||||
|
#undef HAVE_SYS_TYPES_H
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Define if you have the <unistd.h> header file. */
|
||||||
|
#undef HAVE_UNISTD_H
|
||||||
|
|
||||||
|
/* Define if you have the <varargs.h> header file. */
|
||||||
|
#undef HAVE_VARARGS_H
|
||||||
|
|
||||||
|
/* VMS-specific: we need to set up EXIT_xxx here because the default
|
||||||
|
values in as.h are inappropriate for VMS, but we also want to prevent
|
||||||
|
as.h's inclusion of <stdlib.h> from triggering redefinition warnings.
|
||||||
|
<stdlib.h> guards itself against multiple inclusion, so including it
|
||||||
|
here turns as.h's later #include into a no-op. (We can't simply use
|
||||||
|
#ifndef HAVE_STDLIB_H here, because the <stdlib.h> in several older
|
||||||
|
gcc-vms distributions neglects to define these two required macros.) */
|
||||||
|
#ifdef HAVE_STDLIB_H
|
||||||
|
#include <stdlib.h>
|
||||||
|
#undef EXIT_SUCCESS
|
||||||
|
#undef EXIT_FAILURE
|
||||||
|
#endif
|
||||||
|
#define EXIT_SUCCESS 1 /* SS$_NORMAL, STS$K_SUCCESS */
|
||||||
|
#define EXIT_FAILURE 0x10000002 /* (STS$K_ERROR | STS$M_INHIB_MSG) */
|
Reference in New Issue
Block a user