+2000-02-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * Makefile.in (TREE_H, collect2.o, gcc.h, mips-tfile.o, cccp.o,
+ cpphash.o, cppinit.o, protoize.o, unprotoize.o): Depend on version.h.
+
+ * cccp.c: Include version.h and/or don't declare `version_string'.
+ * collect2.c: Likewise.
+ * alpha.c: Likewise.
+ * arm/aof.h: Likewise.
+ * arm/coff.h: Likewise.
+ * arm/elf.h: Likewise.
+ * arm/pe.h: Likewise.
+ * arm/tcoff.h: Likewise.
+ * arm/telf.h: Likewise.
+ * arm/tpe.h: Likewise.
+ * arm/vxarm.h: Likewise.
+ * convex/convex.c: Likewise.
+ * i386/dgux.c: Likewise.
+ * i386/sun386.h: Likewise.
+ * m88k/m88k.c: Likewise.
+ * mcore/mcore-pe.h: Likewise.
+ * mips/mips.h: Likewise.
+ * romp/romp.h: Likewise.
+ * sh/sh.c: Likewise.
+ * cpphash.c: Likewise.
+ * cppinit.c: Likewise.
+ * dwarf2out.c: Likewise.
+ * dwarfout.c: Likewise.
+ * gcc.c: Likewise.
+ * gcc.h: Likewise.
+ * mips-tfile.c: Likewise.
+ * protoize.c: Likewise.
+ * toplev.c: Likewise.
+ * tree.h: Likewise.
+
+ * version.c (version_string): Constify a char*.
+
+ * version.h: New file.
+
2000-02-14 Nick Clifton <nickc@cygnus.com>
* configure.in: Add mcore-elf and mcore-pe targets.
MACHMODE_H = machmode.h machmode.def
RTL_BASE_H = rtl.h rtl.def $(MACHMODE_H)
RTL_H = $(RTL_BASE_H) genrtl.h
-TREE_H = tree.h real.h tree.def $(MACHMODE_H) tree-check.h
+TREE_H = tree.h real.h tree.def $(MACHMODE_H) tree-check.h version.h
BASIC_BLOCK_H = basic-block.h bitmap.h sbitmap.h varray.h
DEMANGLE_H = $(srcdir)/../include/demangle.h
RECOG_H = recog.h
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(COLLECT2_OBJS) $(LIBS)
collect2.o : collect2.c $(CONFIG_H) system.h gstab.h intl.h \
- $(srcdir)/../include/obstack.h $(DEMANGLE_H) collect2.h
+ $(srcdir)/../include/obstack.h $(DEMANGLE_H) collect2.h version.h
$(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
-DTARGET_MACHINE=\"$(target_alias)\" $(MAYBE_USE_COLLECT2) \
-c `echo $(srcdir)/collect2.c | sed 's,^\./,,'`
# Language-independent files.
+gcc.h: version.h
+
DRIVER_DEFINES = \
-DSTANDARD_STARTFILE_PREFIX=\"$(unlibsubdir)/\" \
-DSTANDARD_EXEC_PREFIX=\"$(libdir)/gcc-lib/\" \
mips-tfile: mips-tfile.o version.o $(LIBDEPS)
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ mips-tfile.o version.o $(LIBS)
-mips-tfile.o : mips-tfile.c $(CONFIG_H) $(RTL_H) system.h
+mips-tfile.o : mips-tfile.c $(CONFIG_H) $(RTL_H) system.h version.h
mips-tdump: mips-tdump.o version.o $(LIBDEPS)
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ mips-tdump.o version.o $(LIBS)
# We use $(libsubdir)/$(unlibsubdir) to match the
# -iprefix argument which gcc will pass if GCC_EXEC_PREFIX is used.
cccp.o: cccp.c $(CONFIG_H) intl.h pcp.h version.c config.status system.h \
- mbchar.h prefix.h Makefile.in
+ mbchar.h prefix.h Makefile.in version.h
$(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
$(PREPROCESSOR_DEFINES) \
-c `echo $(srcdir)/cccp.c | sed 's,^\./,,'`
cppulp.o: cppulp.c $(CONFIG_H) system.h output.h
cpplib.o: cpplib.c $(CONFIG_H) cpplib.h intl.h system.h cpphash.h
-cpphash.o: cpphash.c $(CONFIG_H) cpplib.h intl.h system.h cpphash.h
+cpphash.o: cpphash.c $(CONFIG_H) cpplib.h intl.h system.h cpphash.h version.h
cppalloc.o: cppalloc.c $(CONFIG_H) cpplib.h intl.h system.h
cpperror.o: cpperror.c $(CONFIG_H) cpplib.h intl.h system.h
cppexp.o: cppexp.c $(CONFIG_H) cpplib.h intl.h system.h
cppfiles.o: cppfiles.c $(CONFIG_H) cpplib.h intl.h system.h
cppinit.o: cppinit.c $(CONFIG_H) cpplib.h intl.h system.h \
- cpphash.h prefix.h output.h Makefile
+ cpphash.h prefix.h output.h Makefile version.h
$(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
$(PREPROCESSOR_DEFINES) \
-c `echo $(srcdir)/cppinit.c | sed 's,^\./,,'`
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ unprotoize.o $(PROTO_OBJS) $(LIBS)
protoize.o: protoize.c $(srcdir)/../include/getopt.h $(CONFIG_H) system.h \
- Makefile
+ Makefile version.h
$(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
$(DRIVER_DEFINES) $(PREPROCESSOR_DEFINES) \
$(srcdir)/protoize.c
unprotoize.o: unprotoize.c protoize.c $(srcdir)/../include/getopt.h \
- $(CONFIG_H) system.h Makefile
+ $(CONFIG_H) system.h Makefile version.h
$(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
$(DRIVER_DEFINES) $(PREPROCESSOR_DEFINES) \
$(srcdir)/unprotoize.c
#include "pcp.h"
#include "intl.h"
#include "prefix.h"
+#include "version.h"
#ifdef MULTIBYTE_CHARS
#include "mbchar.h"
/* External declarations. */
-extern char *version_string;
HOST_WIDEST_INT parse_escape PARAMS ((char **, HOST_WIDEST_INT));
HOST_WIDEST_INT parse_c_expression PARAMS ((char *, int));
\f
+2000-02-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * grant.c: Don't declare `version_string'.
+
2000-02-11 Nathan Sidwell <nathan@acm.org>
* decl.c (init_decl_processing): Remove duplicate decl of
/* mark that a SPEC MODULE was generated */
static int spec_module_generated = 0;
-/* define version strings */
-extern char *version_string;
-
/* define a faster string handling */
typedef struct
{
#include "demangle.h"
#include "obstack.h"
#include "intl.h"
+#include "version.h"
/* Obstack allocation and deallocation routines. */
#define obstack_chunk_alloc xmalloc
PASS_SECOND /* with constructors linked in */
};
-extern char *version_string;
-
int vflag; /* true if -v */
static int rflag; /* true if -r */
static int strip_flag; /* true if -s */
#include "tm_p.h"
/* External data. */
-extern char *version_string;
extern int rtx_equal_function_value_matters;
/* Specify which cpu to schedule for. */
#define ASM_FILE_START(STREAM) \
{ \
- extern char *version_string; \
fprintf ((STREAM), "%s Generated by gcc %s for ARM/%s\n", \
ASM_COMMENT_START, version_string, ARM_OS_NAME); \
fprintf ((STREAM), "__r0\tRN\t0\n"); \
#define ASM_FILE_START(STREAM) \
do \
{ \
- extern char * version_string; \
fprintf (STREAM, "%s Generated by gcc %s for ARM/coff\n", \
ASM_COMMENT_START, version_string); \
fprintf (STREAM, ASM_APP_OFF); \
#define ASM_FILE_START(STREAM) \
do \
{ \
- extern char * version_string; \
fprintf (STREAM, "%s Generated by gcc %s for ARM/elf\n", \
ASM_COMMENT_START, version_string); \
output_file_directive (STREAM, main_input_filename); \
#define ASM_FILE_START(STREAM) \
do \
{ \
- extern char * version_string; \
asm_fprintf (STREAM, "%@ Generated by gcc %s for ARM/pe\n",\
version_string); \
output_file_directive ((STREAM), main_input_filename); \
#undef ASM_FILE_START
#define ASM_FILE_START(STREAM) \
do { \
- extern char *version_string; \
fprintf ((STREAM), "%s Generated by gcc %s for Thumb/coff\n", \
ASM_COMMENT_START, version_string); \
fprintf ((STREAM), ASM_APP_OFF); \
#define ASM_FILE_START(STREAM) \
do \
{ \
- extern char * version_string; \
fprintf ((STREAM), "%s Generated by gcc %s for Thumb/elf\n", \
ASM_COMMENT_START, version_string); \
fprintf ((STREAM), ASM_APP_OFF); \
#undef ASM_FILE_START
#define ASM_FILE_START(STREAM) \
do { \
- extern char * version_string; \
fprintf ((STREAM), "%s Generated by gcc %s for Thumb/coff\n", \
ASM_COMMENT_START, version_string); \
fprintf ((STREAM), ASM_APP_OFF); \
#undef ASM_FILE_START
#define ASM_FILE_START(STREAM) \
do { \
- extern char * version_string; \
fprintf (STREAM, "%s Generated by gcc %s for ARM/pe\n", \
ASM_COMMENT_START, version_string); \
output_file_directive ((STREAM), main_input_filename); \
#define ASM_FILE_START(STREAM) \
do \
{ \
- extern char * version_string; \
fprintf (STREAM, "%s Generated by gcc %s for ARM/VxWorks\n", \
ASM_COMMENT_START, version_string); \
} while (0)
const char *p;
char c;
- extern char *version_string;
static char vers[4];
int i;
#include <time.h>
#include "i386/i386.c"
-
-extern char *version_string;
-
struct lang_independent_option
{
char *string;
#undef ASM_FILE_START
#define ASM_FILE_START(FILE) \
do { \
- extern char *version_string; \
{ \
int len = strlen (main_input_filename); \
char *na = main_input_filename + len; \
#include "toplev.h"
#include "tm_p.h"
-extern char *version_string;
extern int flag_traditional;
extern FILE *asm_out_file;
#define ASM_FILE_START(STREAM) \
do \
{ \
- extern char * version_string; \
fprintf (STREAM, "%s Generated by gcc %s for MCore/pe\n", \
ASM_COMMENT_START, version_string); \
output_file_directive ((STREAM), main_input_filename); \
extern int may_call_alloca;
extern char **save_argv;
extern int target_flags;
-extern char *version_string;
/* MIPS external variables defined in mips.c. */
/* Output at beginning of assembler file. */
#define ASM_FILE_START(FILE) \
-{ extern char *version_string; \
- const char *p; \
+{ const char *p; \
\
fprintf (FILE, "\t.globl .oVncs\n\t.set .oVncs,0\n") ; \
fprintf (FILE, "\t.globl .oVgcc"); \
/* Global variables from toplev.c and final.c that are used within, but
not declared in any header file. */
-extern char *version_string;
extern int *insn_addresses;
/* Global variables for machine-dependent things. */
#include "system.h"
#include "cpplib.h"
#include "cpphash.h"
+#include "version.h"
#undef abort
static unsigned int hashf PARAMS ((const U_CHAR *, int));
#define CPP_IS_MACRO_BUFFER(PBUF) ((PBUF)->data != NULL)
#define FORWARD(N) CPP_FORWARD (CPP_BUFFER (pfile), (N))
-extern char *version_string;
-
/* The arglist structure is built by create_definition to tell
collect_expansion where the argument names begin. That
is, for a define like "#define f(x,y,z) foo+x-bar*y", the arglist
#include "output.h"
#include "prefix.h"
#include "intl.h"
-
-/* XXX Should be in a header file. */
-extern char *version_string;
+#include "version.h"
/* Predefined symbols, built-in macros, and the default include path. */
language, and compiler version. */
extern int flag_traditional;
-extern char *version_string;
/* Fixed size portion of the DWARF compilation unit header. */
#define DWARF_COMPILE_UNIT_HEADER_SIZE (2 * DWARF_OFFSET_SIZE + 3)
&& decl == TYPE_STUB_DECL (TREE_TYPE (decl))))
extern int flag_traditional;
-extern char *version_string;
/* Maximum size (in bytes) of an artificially generated label. */
+Tue Feb 15 11:14:17 2000 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * g77spec.c: Don't declare `version_string'.
+
Sat Feb 5 23:27:25 2000 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* com.c (mark_tracker_head, mark_binding_level): Protoize.
static char **real_g77_newargv;
static const char **g77_newargv;
-extern char *version_string;
-
/* --- This comes from gcc.c (2.8.1) verbatim: */
/* This defines which switch letters take arguments. */
static struct rusage rus, prus;
#endif
-extern char *version_string;
-
/* Forward declaration for prototypes. */
struct path_prefix;
#ifndef __GCC_H__
#define __GCC_H__
+#include "version.h"
+
/* These are exported by gcc.c. */
extern int do_spec PARAMS ((const char *));
extern void fancy_abort PARAMS ((void)) ATTRIBUTE_NORETURN;
+2000-02-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * Makefile.in (jv-scan, jcf-dump, gcjh): Depend on and link with
+ version.o.
+ (jcf-dump.o, gjavah.o, jv-scan.o): Depend on version.h.
+
+ * gjavah.c: Include version.h.
+
+ * jcf-dump.c: Likewise.
+
+ * jv-scan.c: Likewise.
+
2000-02-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* except.c (check_start_handlers): Re-add prototype lost in last
../jc1$(exeext): $(P) $(JAVA_OBJS) $(OBJDEPS) $(LIBDEPS)
rm -f ../jc1$(exeext)
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(JAVA_OBJS) $(OBJS) $(LIBS)
-../jv-scan$(exeext): $(P) $(JAVA_OBJS_LITE) $(OBJDEPS) $(LIBDEPS)
+../jv-scan$(exeext): $(P) $(JAVA_OBJS_LITE) $(OBJDEPS) ../version.o $(LIBDEPS)
rm -f ../jv-scan$(exeext)
- $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(JAVA_OBJS_LITE) $(LIBS)
+ $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ $(JAVA_OBJS_LITE) ../version.o $(LIBS)
../jcf-dump$(exeext): jcf-dump.o jcf-io.o jcf-depend.o jcf-path.o \
- zextract.o $(LIBDEPS)
+ zextract.o ../version.o $(LIBDEPS)
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ jcf-dump.o jcf-io.o \
- jcf-depend.o jcf-path.o zextract.o ../errors.o $(LIBS)
+ jcf-depend.o jcf-path.o zextract.o ../errors.o ../version.o $(LIBS)
# Dependencies here must be kept in sync with dependencies in Make-lang.in.
../jvgenmain$(exeext): jvgenmain.o mangle.o $(LIBDEPS)
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ jvgenmain.o mangle.o $(LIBS)
../gcjh$(exeext): gjavah.o jcf-io.o jcf-depend.o jcf-path.o \
- zextract.o $(LIBDEPS)
+ zextract.o ../version.o $(LIBDEPS)
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ gjavah.o jcf-io.o \
- jcf-depend.o jcf-path.o zextract.o ../errors.o $(LIBS)
+ jcf-depend.o jcf-path.o zextract.o ../errors.o ../version.o $(LIBS)
Makefile: $(srcdir)/Makefile.in $(srcdir)/../configure
cd ..; $(SHELL) config.status
parse.o : $(PARSE_C) jcf-reader.c $(CONFIG_H) $(srcdir)/../system.h \
$(srcdir)/../function.h $(JAVA_TREE_H)
jcf-dump.o : $(CONFIG_H) $(srcdir)/../system.h $(JAVA_TREE_H) jcf-dump.c \
- jcf-reader.c jcf.h javaop.h javaop.def
+ jcf-reader.c jcf.h javaop.h javaop.def $(srcdir)/../version.h
gjavah.o : $(CONFIG_H) $(srcdir)/../system.h $(JAVA_TREE_H) gjavah.c \
- jcf-reader.c jcf.h javaop.h
+ jcf-reader.c jcf.h javaop.h $(srcdir)/../version.h
buffer.o : buffer.c $(CONFIG_H) buffer.h $(srcdir)/../gansidecl.h \
$(srcdir)/../system.h $(srcdir)/../toplev.h
check-init.o : check-init.c $(CONFIG_H) $(srcdir)/../gansidecl.h \
$(srcdir)/../toplev.h $(PARSE_H)
jcf-write.o : jcf-write.c $(CONFIG_H) $(JAVA_TREE_H) jcf.h $(RTL_H) \
java-opcodes.h parse.h buffer.h $(srcdir)/../system.h $(srcdir)/../toplev.h
-jv-scan.o : jv-scan.c $(CONFIG_H) $(srcdir)/../system.h
+jv-scan.o : jv-scan.c $(CONFIG_H) $(srcdir)/../system.h $(srcdir)/../version.h
jvgenmain.o : jvgenmain.c $(CONFIG_H) $(srcdir)/../system.h
lang.o : lang.c $(CONFIG_H) $(JAVA_TREE_H) jcf.h $(srcdir)/../input.h \
$(srcdir)/../toplev.h $(srcdir)/../system.h $(RTL_H) $(EXPR_H)
#include "java-tree.h"
#include "java-opcodes.h"
-#include "version.c"
-
#include <getopt.h>
\f
#include "tree.h"
#include "java-tree.h"
-#include "version.c"
+#include "version.h"
#include <getopt.h>
#include "obstack.h" /* We use obstacks in lex.c */
-#include "version.c"
+#include "version.h"
#include <getopt.h>
#include "config.h"
#include "system.h"
+#include "version.h"
#ifndef __SABER__
#define saber_stop()
extern char *optarg;
extern int optind;
extern int opterr;
-extern char *version_string;
\f
/* List of assembler pseudo ops and beginning sequences that need
special actions. Someday, this should be a hash table, and such,
#include <unistd.h>
#endif
#undef abort
+#include "version.h"
/* Include getopt.h for the sake of getopt_long. */
#include "getopt.h"
#define CPLUS_FILE_SUFFIX "C"
#endif
-extern char *version_string;
-
static void usage PARAMS ((void)) ATTRIBUTE_NORETURN;
static void aux_info_corrupted PARAMS ((void)) ATTRIBUTE_NORETURN;
static void declare_source_confusing PARAMS ((const char *)) ATTRIBUTE_NORETURN;
#ifdef NEED_DECLARATION_ENVIRON
extern char **environ;
#endif
-extern char *version_string;
/* Carry information from ASM_DECLARE_OBJECT_NAME
to ASM_FINISH_DECLARE_OBJECT. */
Boston, MA 02111-1307, USA. */
#include "machmode.h"
+#include "version.h"
#ifndef RTX_CODE
struct rtx_def;
-char *version_string = "2.96 20000215 (experimental)";
+const char *const version_string = "2.96 20000215 (experimental)";
--- /dev/null
+extern const char *const version_string;