From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14972 invoked by alias); 19 Aug 2002 00:22:54 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 14965 invoked from network); 19 Aug 2002 00:22:50 -0000 Received: from unknown (HELO crushed.velvet.net) (62.49.231.23) by sources.redhat.com with SMTP; 19 Aug 2002 00:22:50 -0000 Received: from aidan by crushed.velvet.net with local (Exim 3.33 #1) id 17gaJk-0000wN-00 for gdb-patches@sources.redhat.com; Mon, 19 Aug 2002 01:22:48 +0100 Date: Sun, 18 Aug 2002 17:22:00 -0000 From: Aidan Skinner To: gdb-patches@sources.redhat.com Subject: [RFA] Makefile.in: add rules for ada files Message-ID: <20020819012247.A20006@velvet.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="BOKacYhQ+x31HxR3" Content-Disposition: inline User-Agent: Mutt/1.2.5.1i X-SW-Source: 2002-08/txt/msg00534.txt.bz2 --BOKacYhQ+x31HxR3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-length: 5590 This patch adds the fules for building the ada files, but doesn't actually cause them to be built or linked. ChangeLog: * Makefile.in (SFILES): Add ada-exp.y ada-lang.c ada-typeprint.c ada-valprint.c ada-tasks.c. (YYFILES): Add ada-exp.y. (ada-exp.tab.c ada-lex.c ada-lang.o)o): New target. (ada-tasks.o ada-typeprint.o ada-valprint.o): New target. (ada-exp.tab.o): New target. Patch: Index: Makefile.in =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /cvs/src/src/gdb/Makefile.in,v retrieving revision 1.240 diff -u -p -r1.240 Makefile.in --- Makefile.in 17 Aug 2002 00:04:36 -0000 1.240 +++ Makefile.in 19 Aug 2002 00:04:18 -0000 @@ -79,6 +79,11 @@ VPATH =3D @srcdir@ =20 YACC=3D@YACC@ =20 +# This is used to rebuild ada-lex.c from ada-lex.l. If the program is=20 +# not defined, but ada-lex.c is present, compilation will continue, +# possibly with a warning. +FLEX =3D flex + YLWRAP =3D $(srcdir)/../ylwrap =20 # where to find makeinfo, preferably one designed for texinfo-2 @@ -518,7 +523,8 @@ TARGET_FLAGS_TO_PASS =3D \ # Links made at configuration time should not be specified here, since # SFILES is used in building the distribution archive. =20 -SFILES =3D ax-general.c ax-gdb.c bcache.c blockframe.c breakpoint.c \ +SFILES =3D ada-exp.y ada-lang.c ada-typeprint.c ada-valprint.c ada-tasks.c= \ + ax-general.c ax-gdb.c bcache.c blockframe.c breakpoint.c \ buildsym.c c-exp.y c-lang.c c-typeprint.c c-valprint.c \ coffread.c \ complaints.c completer.c corefile.c cp-valprint.c dbxread.c \ @@ -764,6 +770,7 @@ SUBDIRS =3D @SUBDIRS@ =20 # For now, shortcut the "configure GDB for fewer languages" stuff. YYFILES =3D c-exp.tab.c \ + ada-exp.tab.c \ jv-exp.tab.c \ f-exp.tab.c m2-exp.tab.c p-exp.tab.c YYOBJ =3D c-exp.tab.o \ @@ -1025,6 +1032,7 @@ local-maintainer-clean: @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." rm -f c-exp.tab.c \ + ada-lex.c ada-exp.tab.c \ jv-exp.tab \ f-exp.tab.c m2-exp.tab.c p-exp.tab.c rm -f TAGS $(INFOFILES) @@ -1160,6 +1168,33 @@ m2-exp.tab.c: m2-exp.y -rm m2-exp.tmp mv m2-exp.new ./m2-exp.tab.c =20 +# ada-exp.tab.c is generated in objdir from ada-exp.y if it doesn't exist +# in srcdir, then compiled in objdir to ada-exp.tab.o. +# Remove bogus decls for malloc/realloc/free which conflict with everything +# else. +ada-exp.tab.c: ada-exp.y=20 + $(YACC) $(YFLAGS) $(srcdir)/ada-exp.y + -sed -e '/extern.*malloc/d' \ + -e '/extern.*realloc/d' \ + -e '/extern.*free/d' \ + -e '/include.*malloc.h/d' \ + -e 's/malloc/xmalloc/g' \ + -e 's/realloc/xrealloc/g' \ + < y.tab.c > ada-exp.new + -rm y.tab.c + mv ada-exp.new ./ada-exp.tab.c + +ada-lex.c: ada-lex.l + @if [ "$(FLEX)" ] && $(FLEX) --version >/dev/null 2>&1; then \ + echo $(FLEX) -Isit $(srcdir)/ada-lex.l ">" ada-lex.c; \ + $(FLEX) -Isit $(srcdir)/ada-lex.l > ada-lex.c; \ + elif [ ! -f ada-lex.c -a ! -f $(srcdir)/ada-lex.c ]; then \ + echo "ada-lex.c missing and flex not available."; \ + false; \ + elif [ ! -f ada-lex.c ]; then \ + echo "Warning: ada-lex.c older than ada-lex.l and flex not available.= "; \ + fi + # p-exp.tab.c is generated in objdir from p-exp.y if it doesn't exist # in srcdir, then compiled in objdir to p-exp.tab.o. # Remove bogus decls for malloc/realloc/free which conflict with everything @@ -1180,7 +1215,7 @@ p-exp.tab.c: p-exp.y =20 # These files are updated atomically, so make never has to remove them .PRECIOUS: m2-exp.tab.c f-exp.tab.c c-exp.tab.c -.PRECIOUS: jv-exp.tab.c p-exp.tab.c +.PRECIOUS: jv-exp.tab.c p-exp.tab.c ada-exp.tab.c =20 lint: $(LINTFILES) $(LINT) $(INCLUDE_CFLAGS) $(LINTFLAGS) $(LINTFILES) \ @@ -1306,6 +1341,21 @@ aix-thread.o: aix-thread.c $(defs_h) $(g $(inferior_h) $(target_h) $(regcache_h) $(gdbcmd_h) $(gdb_assert_h) \ $(ppc_tdep_h) $(language_h) =20 +ada-lang.o: ada-lang.c ada-lang.h c-lang.h $(defs_h) $(expression_h) \ + $(gdbtypes_h) $(inferior_h) language.h parser-defs.h $(symtab_h) \ + $(gdbcmd_h) $(ui_out_h) symfile.h objfiles.h $(gdbcore_h) + +ada-tasks.o: ada-tasks.c ada-lang.h $(defs_h) language.h $(value_h) \ + $(command_h) $(value_h) $(gdbcore_h) + +ada-typeprint.o: ada-typeprint.c ada-lang.h $(defs_h) $(expression_h) \ + $(gdbcmd_h) $(gdbcore_h) $(gdbtypes_h) language.h $(symtab_h) \ + target.h typeprint.h $(value_h) ada-lang.h + +ada-valprint.o: ada-valprint.c $(defs_h) $(expression_h) $(gdbtypes_h) \ + language.h $(symtab_h) valprint.h $(value_h) c-lang.h ada-lang.h \ + annotate.h + alpha-nat.o: alpha-nat.c $(defs_h) $(gdbcore_h) $(inferior_h) $(target_h) \ $(regcache_h) $(alpha_tdep_h) =20 @@ -2278,6 +2328,11 @@ m2-exp.tab.o: m2-exp.tab.c $(defs_h) $(e p-exp.tab.o: p-exp.tab.c $(defs_h) $(expression_h) $(gdbtypes_h) \ $(language_h) p-lang.h $(parser_defs_h) $(symtab_h) $(value_h) \ $(bfd_h) $(objfiles_h) $(symfile_h) + +ada-exp.tab.o: ada-exp.tab.c ada-lex.c ada-lang.h \ + $(defs_h) $(expression_h) \ + $(gdbtypes_h) language.h parser-defs.h $(symtab_h) $(value_h) \ + $(bfd_h) objfiles.h symfile.h =20 gdb-events.o: gdb-events.c $(gdb_events_h) $(defs_h) $(gdbcmd_h) =20 - Aidan --=20 aidan@velvet.net http://www.velvet.net/~aidan/ aim:aidans42 finger for pgp key fingerprint |- - - - - - - - - - - - - - - - - 01AA 1594 2DB0 09E3 B850 | Marklar Domination, one marklar=20 C2D0 9A2C 4CC9 3EC4 75E1 | smoking marklar at at time=20 --BOKacYhQ+x31HxR3 Content-Type: application/pgp-signature Content-Disposition: inline Content-length: 230 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (OpenBSD) Comment: For info see http://www.gnupg.org iD8DBQE9YDpWmixMyT7EdeERAtIPAJ9iTAnzsCSqj5N/xoOeJZ1ac71Y6gCfXNma /yAo0FUyGHv4X9AmNVmnGWQ= =fOcH -----END PGP SIGNATURE----- --BOKacYhQ+x31HxR3--