Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Richard Earnshaw <rearnsha@gcc.gnu.org>
To: Hans-Peter Nilsson <hans-peter.nilsson@axis.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: ARM Simulator build broken
Date: Wed, 17 Nov 2004 16:06:00 -0000	[thread overview]
Message-ID: <1100707579.22014.47.camel@pc960.cambridge.arm.com> (raw)
In-Reply-To: <1100703804.22014.42.camel@pc960.cambridge.arm.com>

[-- Attachment #1: Type: text/plain, Size: 1728 bytes --]

On Wed, 2004-11-17 at 15:03, Richard Earnshaw wrote:
> On Tue, 2004-11-16 at 15:35, Hans-Peter Nilsson wrote:
> > > From: Richard Earnshaw <rearnsha@gcc.gnu.org>
> > > Cc: gdb-patches@sources.redhat.com
> > 
> > > Here's my proposed patch:
> > > 
> > > <date> Richard Earnshaw  <rearnsha@arm.com>
> > > 
> > > 	* Make-common.in (sim_basics_headers): New.
> > > 	(sim_main_headers): Move basics headers and sub-dependencies
> > > 	to sim_basics_headers).  Add the dependencies through that.
> > > 	(sim-load.c): Depend on sim_basics_headers not 
> > > 	sim_main_headers.
> > > 
> > > OK?
> > 
> > I was preparing almost the same patch, just naming the macro
> > sim_basics_h_headers!
> > 
> > BTW, you shouldn't have edited out sim-arange.c, a gcc -MM says
> > it's actually included from sim-basics.h (and from looking at
> > the code).  For the same reason sim-assert.h should be in
> > sim_basics_headers.  Maybe all files should use the
> > $(sim-assert_h) et al macros.
> 
> The list of headers I used was the list directly in sim-basics.h.  I
> only moved existing includes from sim_main_headers and then added
> further ones at the first level that were obviously missing.  So if it's
> wrong now it was wrong before.
> 
> The best way to do all this is to define a series of macros
> sim-basics_h, sim-assert-h etc, and for each of these to list the macros
> that form the direct dependencies.
> 
> But that's a fair bit of work... :-(  ... and it needs active
> maintenance to keep it up to date.
> 
> R.

Attached is a revised version of the patch that implements this for
sim-*.h.  Really further work should be done so that the C files depend
on the correct headers rather than all depending on sim_main_headers.

R.

[-- Attachment #2: sim2.patch --]
[-- Type: text/x-patch, Size: 4461 bytes --]

Index: Make-common.in
===================================================================
RCS file: /cvs/src/src/sim/common/Make-common.in,v
retrieving revision 1.14
diff -p -r1.14 Make-common.in
*** Make-common.in	16 Nov 2004 07:02:26 -0000	1.14
--- Make-common.in	17 Nov 2004 16:02:17 -0000
*************** stamp-tvals: gentmap
*** 298,341 ****
  
  sim_main_headers = \
  	sim-main.h \
! 	$(srccom)/sim-assert.h \
! 	$(srccom)/sim-base.h \
! 	$(srccom)/sim-basics.h \
! 	$(srccom)/sim-config.h \
! 	$(srccom)/sim-cpu.h \
! 	$(srccom)/sim-engine.h \
! 	$(srccom)/sim-events.h \
! 	$(srccom)/sim-inline.h \
! 	$(srccom)/sim-memopt.h \
! 	$(srccom)/sim-model.h \
! 	$(srccom)/sim-module.h \
! 	$(srccom)/sim-profile.h \
! 	$(srccom)/sim-signal.h \
! 	$(srccom)/sim-trace.h \
! 	$(srccom)/sim-utils.h \
! 	$(srccom)/sim-watch.h \
! 	tconfig.h \
  	$(SIM_EXTRA_DEPS)
  
  # Exported version of sim_main_headers.
  SIM_MAIN_DEPS = \
  	$(sim_main_headers)
  
  sim-assert_h = $(srccom)/sim-assert.h
! sim-endian_h = $(srccom)/sim-endian.h
! sim-n-endian_h = $(srccom)/sim-n-endian.h
! sim-arange_h = $(srccom)/sim-arange.h
! sim-bits_h = $(srccom)/sim-bits.h
  sim-config_h = $(srccom)/sim-config.h
- sim-n-bits_h = $(srccom)/sim-n-bits.h
  sim-core_h = $(srccom)/sim-core.h
! sim-n-core_h = $(srccom)/sim-n-core.h
  sim-engine_h = $(srccom)/sim-engine.h
  sim-events_h = $(srccom)/sim-events.h
  sim-fpu_h = $(srccom)/sim-fpu.h
  sim-io_h = $(srccom)/sim-io.h
  sim-options_h = $(srccom)/sim-options.h
  sim-signal_h = $(srccom)/sim-signal.h
  
  hw-alloc_h = $(srccom)/hw-alloc.h
  hw-base_h = $(srccom)/hw-base.h
--- 298,374 ----
  
  sim_main_headers = \
  	sim-main.h \
! 	$(sim-assert_h) \
! 	$(sim-base_h) \
! 	$(sim-cpu_h) \
! 	$(sim-engine_h) \
! 	$(sim-events_h) \
! 	$(sim-memopt_h) \
! 	$(sim-model_h) \
! 	$(sim-module_h) \
! 	$(sim-profile_h) \
! 	$(sim-trace_h) \
! 	$(sim-watch_h) \
! 	$(sim-basics_h) \
  	$(SIM_EXTRA_DEPS)
  
  # Exported version of sim_main_headers.
  SIM_MAIN_DEPS = \
  	$(sim_main_headers)
  
+ sim-alu_h = $(srccom)/sim-alu.h
+ sim-arange_h = $(srccom)/sim-arange.h \
+ 		$(srccom)/sim-arange.c
  sim-assert_h = $(srccom)/sim-assert.h
! sim-base_h = $(srccom)/sim-base.h \
! 		$(sim-module_h) \
! 		$(sim-trace_h) \
! 		$(sim-core_h) \
! 		$(sim-events_h) \
! 		$(sim-profile_h) \
! 		$(sim-model_h) \
! 		$(sim-io_h) \
! 		$(sim-engine_h) \
! 		$(sim-watch_h) \
! 		$(sim-memopt_h) \
! 		$(sim-cpu_h)
! sim-basics_h = $(srccom)/sim-basics.h \
! 		cconfig_h \
! 		tconfig_h \
! 		$(sim-config_h) \
! 		$(sim-inline_h) \
! 		$(sim-types_h) \
! 		$(sim-bits_h) \
! 		$(sim-endian_h) \
! 		$(sim-signal_h) \
! 		$(sim-arange_h) \
! 		$(sim-utils_h)
! sim-bits_h = $(srccom)/sim-bits.h \
! 		$(srccom)/sim-bits.c
  sim-config_h = $(srccom)/sim-config.h
  sim-core_h = $(srccom)/sim-core.h
! sim-cpu_h = $(srccom)/sim-cpu.h
! sim-endian_h = $(srccom)/sim-endian.h \
! 		$(srccom)/sim-endian.c
  sim-engine_h = $(srccom)/sim-engine.h
  sim-events_h = $(srccom)/sim-events.h
  sim-fpu_h = $(srccom)/sim-fpu.h
+ sim-hw_h = $(srccom)/sim-hw.h
+ sim-inline_h = $(srccom)/sim-inline.h
  sim-io_h = $(srccom)/sim-io.h
+ sim-memopt_h = $(srccom)/sim-memopt.h
+ sim-model_h = $(srccom)/sim-model.h
+ sim-module_h = $(srccom)/sim-module.h
+ sim-n-bits_h = $(srccom)/sim-n-bits.h
+ sim-n-core_h = $(srccom)/sim-n-core.h
+ sim-n-endian_h = $(srccom)/sim-n-endian.h
  sim-options_h = $(srccom)/sim-options.h
+ sim-profile_h = $(srccom)/sim-profile.h
  sim-signal_h = $(srccom)/sim-signal.h
+ sim-trace_h = $(srccom)/sim-trace.h
+ sim-types_h = $(srccom)/sim-types.h
+ sim-utils_h = $(srccom)/sim-utils.h
+ sim-watch_h = $(srccom)/sim-watch.h
  
  hw-alloc_h = $(srccom)/hw-alloc.h
  hw-base_h = $(srccom)/hw-base.h
*************** sim-utils.o: $(srccom)/sim-utils.c $(sim
*** 473,479 ****
  sim-watch.o: $(srccom)/sim-watch.c $(sim_main_headers)
  	$(CC) -c $(srccom)/sim-watch.c $(ALL_CFLAGS)
  
! sim-load.o: $(srccom)/sim-load.c $(callback_h) $(sim_main_headers) $(remote_sim_h)
  	$(CC) -c $(srccom)/sim-load.c $(ALL_CFLAGS)
  
  
--- 506,512 ----
  sim-watch.o: $(srccom)/sim-watch.c $(sim_main_headers)
  	$(CC) -c $(srccom)/sim-watch.c $(ALL_CFLAGS)
  
! sim-load.o: $(srccom)/sim-load.c $(callback_h) $(sim_basics_h) $(remote_sim_h)
  	$(CC) -c $(srccom)/sim-load.c $(ALL_CFLAGS)
  
  

  reply	other threads:[~2004-11-17 16:06 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-16 12:40 Richard Earnshaw
2004-11-16 15:24 ` Richard Earnshaw
2004-11-16 15:36   ` Hans-Peter Nilsson
2004-11-17 15:04     ` Richard Earnshaw
2004-11-17 16:06       ` Richard Earnshaw [this message]
2004-11-17 18:25         ` Hans-Peter Nilsson
2004-11-17 20:38           ` Andrew Cagney
2004-11-18  0:08             ` Hans-Peter Nilsson
2004-11-18 10:22               ` Richard Earnshaw
2004-11-24 18:42         ` Alexandre Oliva
2004-11-25 10:31           ` Richard Earnshaw
2004-11-25 10:48           ` Richard Earnshaw
2004-11-29 18:27             ` Alexandre Oliva

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1100707579.22014.47.camel@pc960.cambridge.arm.com \
    --to=rearnsha@gcc.gnu.org \
    --cc=gdb-patches@sources.redhat.com \
    --cc=hans-peter.nilsson@axis.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox