aboutsummaryrefslogtreecommitdiff
path: root/sim
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2024-01-02 09:58:07 -0500
committerMike Frysinger <vapier@gentoo.org>2024-01-03 01:21:48 -0500
commit2c3bcf2537c2eddbdfc5d9f8e5e285b310c9fe7f (patch)
treef0355d21c57bac3f91a8aa4dd80e36ffc712b6f1 /sim
parent10e1edb7373416dfd76906f230c9411317162fb8 (diff)
downloadbinutils-2c3bcf2537c2eddbdfc5d9f8e5e285b310c9fe7f.zip
binutils-2c3bcf2537c2eddbdfc5d9f8e5e285b310c9fe7f.tar.gz
binutils-2c3bcf2537c2eddbdfc5d9f8e5e285b310c9fe7f.tar.bz2
sim: ppc: hoist compilation up to top-level
This removes all recursive makes from the ppc port.
Diffstat (limited to 'sim')
-rw-r--r--sim/Makefile.in30
-rwxr-xr-xsim/configure3
-rw-r--r--sim/configure.ac2
-rw-r--r--sim/ppc/Makefile.in576
-rw-r--r--sim/ppc/local.mk7
5 files changed, 16 insertions, 602 deletions
diff --git a/sim/Makefile.in b/sim/Makefile.in
index 3ef3fad..9a6dec4 100644
--- a/sim/Makefile.in
+++ b/sim/Makefile.in
@@ -281,14 +281,15 @@ TESTS = testsuite/common/bits32m0$(EXEEXT) \
@SIM_ENABLE_ARCH_or1k_TRUE@am__append_88 = $(or1k_BUILD_OUTPUTS)
@SIM_ENABLE_ARCH_ppc_TRUE@am__append_89 = ppc/libsim.a
@SIM_ENABLE_ARCH_ppc_TRUE@am__append_90 = ppc/run
-@SIM_ENABLE_ARCH_ppc_TRUE@am__append_91 = ppc/defines.h \
+@SIM_ENABLE_ARCH_ppc_TRUE@am__append_91 = ppc/defines.h ppc/icache.h \
+@SIM_ENABLE_ARCH_ppc_TRUE@ ppc/idecode.h ppc/semantics.h \
+@SIM_ENABLE_ARCH_ppc_TRUE@ ppc/model.h ppc/support.h \
+@SIM_ENABLE_ARCH_ppc_TRUE@ ppc/itable.h ppc/hw.h
+@SIM_ENABLE_ARCH_ppc_TRUE@am__append_92 = ppc/defines.h \
@SIM_ENABLE_ARCH_ppc_TRUE@ ppc/stamp-defines \
@SIM_ENABLE_ARCH_ppc_TRUE@ $(ppc_BUILD_OUTPUTS) \
@SIM_ENABLE_ARCH_ppc_TRUE@ $(ppc_IGEN_TOOLS) ppc/libigen.a
-@SIM_ENABLE_ARCH_ppc_TRUE@am__append_92 = ppc/libigen.a
-@SIM_ENABLE_ARCH_ppc_TRUE@am__append_93 = ppc/icache.h ppc/idecode.h \
-@SIM_ENABLE_ARCH_ppc_TRUE@ ppc/semantics.h ppc/model.h \
-@SIM_ENABLE_ARCH_ppc_TRUE@ ppc/support.h ppc/itable.h ppc/hw.h
+@SIM_ENABLE_ARCH_ppc_TRUE@am__append_93 = ppc/libigen.a
@SIM_ENABLE_ARCH_ppc_TRUE@am__append_94 = $(ppc_IGEN_TOOLS)
@SIM_ENABLE_ARCH_pru_TRUE@am__append_95 = pru/libsim.a
@SIM_ENABLE_ARCH_pru_TRUE@am__append_96 = pru/run
@@ -362,10 +363,9 @@ CONFIG_CLEAN_FILES = aarch64/.gdbinit arm/.gdbinit avr/.gdbinit \
iq2000/.gdbinit lm32/.gdbinit m32c/.gdbinit m32r/.gdbinit \
m68hc11/.gdbinit mcore/.gdbinit microblaze/.gdbinit \
mips/.gdbinit mn10300/.gdbinit moxie/.gdbinit msp430/.gdbinit \
- or1k/.gdbinit ppc/Makefile ppc/.gdbinit pru/.gdbinit \
- riscv/.gdbinit rl78/.gdbinit rx/.gdbinit sh/.gdbinit \
- erc32/.gdbinit v850/.gdbinit example-synacor/.gdbinit \
- arch-subdir.mk .gdbinit
+ or1k/.gdbinit ppc/.gdbinit pru/.gdbinit riscv/.gdbinit \
+ rl78/.gdbinit rx/.gdbinit sh/.gdbinit erc32/.gdbinit \
+ v850/.gdbinit example-synacor/.gdbinit arch-subdir.mk .gdbinit
CONFIG_CLEAN_VPATH_FILES =
LIBRARIES = $(noinst_LIBRARIES)
ARFLAGS = cru
@@ -1849,7 +1849,7 @@ GNULIB_PARENT_DIR = ..
srccom = $(srcdir)/common
srcroot = $(srcdir)/..
pkginclude_HEADERS = $(am__append_1)
-EXTRA_LIBRARIES = igen/libigen.a $(am__append_92)
+EXTRA_LIBRARIES = igen/libigen.a $(am__append_93)
noinst_LIBRARIES = common/libcommon.a $(am__append_3) $(am__append_5) \
$(am__append_7) $(am__append_9) $(am__append_11) \
$(am__append_13) $(am__append_18) $(am__append_23) \
@@ -1864,7 +1864,7 @@ noinst_LIBRARIES = common/libcommon.a $(am__append_3) $(am__append_5) \
BUILT_SOURCES = $(am__append_15) $(am__append_21) $(am__append_25) \
$(am__append_36) $(am__append_44) $(am__append_48) \
$(am__append_56) $(am__append_71) $(am__append_79) \
- $(am__append_87) $(am__append_93) $(am__append_105) \
+ $(am__append_87) $(am__append_91) $(am__append_105) \
$(am__append_110)
CLEANFILES = common/version.c common/version.c-stamp \
testsuite/common/bits-gen testsuite/common/bits32m0.c \
@@ -1881,7 +1881,7 @@ MOSTLYCLEANFILES = core $(SIM_ENABLED_ARCHES:%=%/*.o) \
$(am__append_37) $(am__append_45) $(am__append_49) \
$(am__append_53) $(am__append_57) $(am__append_61) \
$(am__append_75) $(am__append_80) $(am__append_88) \
- $(am__append_91) $(am__append_107) $(am__append_111)
+ $(am__append_92) $(am__append_107) $(am__append_111)
CONFIG_STATUS_DEPENDENCIES = $(srcroot)/bfd/development.sh
AM_CFLAGS = \
$(WERROR_CFLAGS) \
@@ -2942,6 +2942,7 @@ testsuite_common_CPPFLAGS = \
@SIM_ENABLE_ARCH_ppc_TRUE@ $(sim_ppc_model) $(sim_ppc_default_model) $(sim_ppc_model_issue) \
@SIM_ENABLE_ARCH_ppc_TRUE@ $(sim_ppc_switch)
+@SIM_ENABLE_ARCH_ppc_TRUE@AM_CPPFLAGS_ppc_options.o = '-DOPCODE_RULES="$(IGEN_OPCODE_RULES)"' '-DIGEN_FLAGS="$(ppc_IGEN_FLAGS)"'
@SIM_ENABLE_ARCH_ppc_TRUE@ppc_libsim_a_SOURCES = \
@SIM_ENABLE_ARCH_ppc_TRUE@ $(common_libcommon_a_SOURCES)
@@ -3322,8 +3323,6 @@ msp430/.gdbinit: $(top_builddir)/config.status $(top_srcdir)/common/gdbinit.in
cd $(top_builddir) && $(SHELL) ./config.status $@
or1k/.gdbinit: $(top_builddir)/config.status $(top_srcdir)/common/gdbinit.in
cd $(top_builddir) && $(SHELL) ./config.status $@
-ppc/Makefile: $(top_builddir)/config.status $(top_srcdir)/ppc/Makefile.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
ppc/.gdbinit: $(top_builddir)/config.status $(top_srcdir)/common/gdbinit.in
cd $(top_builddir) && $(SHELL) ./config.status $@
pru/.gdbinit: $(top_builddir)/config.status $(top_srcdir)/common/gdbinit.in
@@ -5820,9 +5819,6 @@ testsuite/common/bits64m63.c: testsuite/common/bits-gen$(EXEEXT) testsuite/commo
@SIM_ENABLE_ARCH_ppc_TRUE@ppc/%.o: common/%.c ; $(SIM_COMPILE)
@SIM_ENABLE_ARCH_ppc_TRUE@-@am__include@ ppc/$(DEPDIR)/*.Po
-@SIM_ENABLE_ARCH_ppc_TRUE@ppc/%.o: ppc/%.c | common/libcommon.a ppc/defines.h ppc/stamp-igen ppc/hw.c ppc/hw.h
-@SIM_ENABLE_ARCH_ppc_TRUE@ $(AM_V_at)$(MAKE) $(AM_MAKEFLAGS) -C $(@D) $(@F)
-
@SIM_ENABLE_ARCH_ppc_TRUE@ppc/defines.h: ppc/stamp-defines ; @true
@SIM_ENABLE_ARCH_ppc_TRUE@ppc/stamp-defines: config.h Makefile
@SIM_ENABLE_ARCH_ppc_TRUE@ $(AM_V_GEN)sed -n -e '/^#define HAVE_/s/ 1$$/",/' -e '/^#define HAVE_/s//"HAVE_/p' < config.h > ppc/defines.hin
diff --git a/sim/configure b/sim/configure
index f813d91..b5637e5 100755
--- a/sim/configure
+++ b/sim/configure
@@ -15496,8 +15496,6 @@ fi
fi
ENABLE_SIM=yes
as_fn_append SIM_ENABLED_ARCHES " ppc"
- ac_config_files="$ac_config_files ppc/Makefile"
-
ac_config_files="$ac_config_files ppc/.gdbinit:common/gdbinit.in"
@@ -18299,7 +18297,6 @@ do
"moxie/.gdbinit") CONFIG_FILES="$CONFIG_FILES moxie/.gdbinit:common/gdbinit.in" ;;
"msp430/.gdbinit") CONFIG_FILES="$CONFIG_FILES msp430/.gdbinit:common/gdbinit.in" ;;
"or1k/.gdbinit") CONFIG_FILES="$CONFIG_FILES or1k/.gdbinit:common/gdbinit.in" ;;
- "ppc/Makefile") CONFIG_FILES="$CONFIG_FILES ppc/Makefile" ;;
"ppc/.gdbinit") CONFIG_FILES="$CONFIG_FILES ppc/.gdbinit:common/gdbinit.in" ;;
"pru/.gdbinit") CONFIG_FILES="$CONFIG_FILES pru/.gdbinit:common/gdbinit.in" ;;
"riscv/.gdbinit") CONFIG_FILES="$CONFIG_FILES riscv/.gdbinit:common/gdbinit.in" ;;
diff --git a/sim/configure.ac b/sim/configure.ac
index 937571a..0bb7f7d 100644
--- a/sim/configure.ac
+++ b/sim/configure.ac
@@ -119,7 +119,7 @@ if test "${enable_sim}" != no; then
SIM_TARGET([moxie-*-*], [moxie])
SIM_TARGET([msp430*-*-*], [msp430])
SIM_TARGET([or1k*-*-*], [or1k])
- SIM_TARGET([powerpc*-*-*], [ppc], [true])
+ SIM_TARGET([powerpc*-*-*], [ppc])
SIM_TARGET([pru*-*-*], [pru])
SIM_TARGET([riscv*-*-*], [riscv])
SIM_TARGET([rl78-*-*], [rl78])
diff --git a/sim/ppc/Makefile.in b/sim/ppc/Makefile.in
deleted file mode 100644
index 8c05568..0000000
--- a/sim/ppc/Makefile.in
+++ /dev/null
@@ -1,576 +0,0 @@
-#
-# This file is part of the program psim.
-#
-# Copyright 1994, 1995, 1996, 1997, 2003 Andrew Cagney
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, see <http://www.gnu.org/licenses/>.
-#
-
-default: all
-
-VPATH = @srcdir@
-srcdir = @srcdir@
-srccom = $(srcdir)/../common
-srcroot = $(srcdir)/../..
-srcsim = $(srcdir)/..
-
-include $(srcroot)/gdb/silent-rules.mk
-
-# Helper code from gnulib.
-GNULIB_PARENT_DIR = ../..
-include $(GNULIB_PARENT_DIR)/gnulib/Makefile.gnulib.inc
-
-# Settings from top-level configure.
-include ../arch-subdir.mk
-
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-datarootdir = @datarootdir@
-datadir = @datadir@
-mandir = @mandir@
-man1dir = $(mandir)/man1
-man2dir = $(mandir)/man2
-man3dir = $(mandir)/man3
-man4dir = $(mandir)/man4
-man5dir = $(mandir)/man5
-man6dir = $(mandir)/man6
-man7dir = $(mandir)/man7
-man8dir = $(mandir)/man8
-man9dir = $(mandir)/man9
-infodir = @infodir@
-includedir = @includedir@
-
-# This can be referenced by the gettext configuration code.
-top_builddir = ..
-
-SHELL = /bin/sh
-
-BISON = bison
-MAKEINFO = makeinfo
-
-INLINE_CFLAGS = $(SIM_INLINE)
-SMP_CFLAGS = @sim_ppc_smp@
-XOR_ENDIAN_CFLAGS = @sim_ppc_xor_endian@
-BITSIZE_CFLAGS = @sim_ppc_bitsize@
-TIMEBASE_CFLAGS = @sim_ppc_timebase@
-FLOAT_CFLAGS = @sim_ppc_float@
-MONITOR_CFLAGS = @sim_ppc_monitor@
-MODEL_CFLAGS = @sim_ppc_model@ @sim_ppc_default_model@ @sim_ppc_model_issue@
-SWITCH_CFLAGS = @sim_ppc_switch@
-CONFIG_CFLAGS = \
- -DHAVE_CONFIG_H \
- $(SMP_CFLAGS) \
- $(XOR_ENDIAN_CFLAGS) \
- $(BITSIZE_CFLAGS) \
- $(TIMEBASE_CFLAGS) \
- $(FLOAT_CFLAGS) \
- $(MONITOR_CFLAGS) \
- $(MODEL_CFLAGS) \
- $(SWITCH_CFLAGS)
-SIM_FPU_CFLAGS = -DHAVE_COMMON_FPU -I../common -I${srcdir}/../common
-
-STD_CFLAGS = $(CFLAGS) $(WERROR_CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(WARN_CFLAGS) $(INCLUDES) $(INCGNU) $(SIM_FPU_CFLAGS)
-NOWARN_CFLAGS = $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(INCLUDES) $(SIM_FPU_CFLAGS)
-
-LIBS = $(COMMON_LIBS) @LIBS@ $(LIBGNU) $(LIBGNU_EXTRA_LIBS)
-
-.NOEXPORT:
-MAKEOVERRIDES=
-
-LIB_INCLUDES = -I$(srcdir)/../../include
-BFD_INCLUDES = -I../../bfd -I$(srcdir)/../../bfd
-
-INCLUDES = -I. -I$(srcdir) $(LIB_INCLUDES) $(BFD_INCLUDES) -I../..
-
-LIBIBERTY_LIB = ../../libiberty/libiberty.a
-BFD_LIB = ../../bfd/libbfd.la
-
-all:
-
-.c.o:
- $(ECHO_CC) $(CC) -c $(STD_CFLAGS) $<
-
-
-# Headers outside sim/ppc.
-ANSIDECL_H = $(srcroot)/include/ansidecl.h
-BFD_H = ../../bfd/bfd.h
-GDB_CALLBACK_H = $(srcroot)/include/sim/callback.h
-GDB_REMOTE_SIM_H = $(srcroot)/include/sim/sim.h
-GDB_SIM_PPC_H = $(srcroot)/include/sim/sim-ppc.h
-COMMON_SIM_BASE_H = $(srcroot)/sim/common/sim-base.h
-COMMON_SIM_BASICS_H = $(srcroot)/sim/common/sim-basics.h
-COMMON_SIM_FPU_H = $(srcroot)/sim/common/sim-fpu.h
-COMMON_SIM_INLINE_H = $(srcroot)/sim/common/sim-inline.h
-COMMON_SIM_SIGNAL_H = $(srcroot)/sim/common/sim-signal.h
-
-# Headers in sim/ppc.
-ALTIVEC_EXPRESSION_H = \
- altivec_expression.h
-
-ALTIVEC_REGISTERS_H = \
- altivec_registers.h
-
-BASICS_H = \
- basics.h \
- $(INLINE_H) \
- $(SIM_CALLBACKS_H) \
- $(DEBUG_H) \
- $(WORDS_H) \
- $(BITS_H) \
- $(SIM_ENDIAN_H)
-
-BITS_H = \
- bits.h \
- bits.c
-
-CAP_H = \
- cap.h \
- $(BASICS_H)
-
-COREFILE_H = \
- corefile.h
-
-COREFILE_N_H = \
- corefile-n.h
-
-CPU_H = \
- cpu.h \
- $(BASICS_H) \
- $(REGISTERS_H) \
- $(DEVICE_H) \
- $(COREFILE_H) \
- $(VM_H) \
- $(EVENTS_H) \
- $(INTERRUPTS_H) \
- $(PSIM_H) \
- $(IDECODE_H) \
- $(ITABLE_H) \
- $(OS_EMUL_H) \
- $(MON_H) \
- $(MODEL_H) \
- cpu.c
-
-DEBUG_H = \
- debug.h
-
-DEVICE_H = \
- device.h
-
-DEVICE_TABLE_H = \
- device_table.h \
- $(BASICS_H) \
- $(DEVICE_H) \
- $(TREE_H) \
- $(HW_H)
-
-E500_EXPRESSION_H = \
- e500_expression.h
-
-E500_REGISTERS_H = \
- e500_registers.h
-
-EMUL_BUGAPI_H = \
- emul_bugapi.h
-
-EMUL_CHIRP_H = \
- emul_chirp.h
-
-EMUL_GENERIC_H = \
- emul_generic.h \
- $(CPU_H) \
- $(IDECODE_H) \
- $(OS_EMUL_H) \
- $(TREE_H) \
- $(BFD_H)
-
-EMUL_NETBSD_H = \
- emul_netbsd.h
-
-EMUL_UNIX_H = \
- emul_unix.h
-
-EVENTS_H = \
- events.h
-
-FILTER_H = \
- filter.h
-
-GEN_ICACHE_H = \
- gen-icache.h
-
-GEN_IDECODE_H = \
- gen-idecode.h
-
-GEN_ITABLE_H = \
- gen-itable.h
-
-GEN_MODEL_H = \
- gen-model.h
-
-GEN_SEMANTICS_H = \
- gen-semantics.h
-
-GEN_SUPPORT_H = \
- gen-support.h
-
-HW_CPU_H = \
- hw_cpu.h
-
-HW_PHB_H = \
- hw_phb.h
-
-IDECODE_BRANCH_H = \
- idecode_branch.h
-
-IDECODE_EXPRESSION_H = \
- idecode_expression.h \
- $(ALTIVEC_EXPRESSION_H) \
- $(E500_EXPRESSION_H)
-
-IDECODE_FIELDS_H = \
- idecode_fields.h
-
-INLINE_H = \
- inline.h
-
-INTERRUPTS_H = \
- interrupts.h
-
-LD_CACHE_H = \
- ld-cache.h
-
-LD_DECODE_H = \
- ld-decode.h
-
-LD_INSN_H = \
- ld-insn.h
-
-LF_H = \
- lf.h
-
-MISC_H = \
- misc.h
-
-MON_H = \
- mon.h \
- $(BASICS_H) \
- $(ITABLE_H)
-
-OPTIONS_H = \
- options.h
-
-OS_EMUL_H = \
- os_emul.h
-
-PSIM_H = \
- psim.h \
- $(BASICS_H)
-
-REGISTERS_H = \
- registers.h \
- $(E500_REGISTERS_H) \
- $(ALTIVEC_REGISTERS_H) \
- $(SPREG_H)
-
-SIM_CALLBACKS_H = \
- sim_callbacks.h
-
-SIM_ENDIAN_H = \
- sim-endian.h \
- sim-endian.c
-
-SIM_ENDIAN_N_H = \
- sim-endian-n.h
-
-SIM_MAIN_H = \
- sim-main.h \
- $(COMMON_SIM_BASICS_H) \
- $(COMMON_SIM_SIGNAL_H) \
- $(COMMON_SIM_BASE_H)
-
-STD_CONFIG_H = \
- std-config.h
-
-TABLE_H = \
- table.h
-
-TREE_H = \
- tree.h
-
-VM_H = \
- vm.h
-
-VM_N_H = \
- vm_n.h
-
-WORDS_H = \
- words.h
-
-
-# Generated headers.
-DEFINES_H = \
- defines.h
-
-HW_H = \
- hw.h
-
-ICACHE_H = \
- icache.h
-
-IDECODE_H = \
- idecode.h \
- $(IDECODE_EXPRESSION_H) \
- $(IDECODE_FIELDS_H) \
- $(IDECODE_BRANCH_H)
-
-ITABLE_H = \
- itable.h
-
-MODEL_H = \
- model.h
-
-PK_H = \
- pk.h
-
-SEMANTICS_H = \
- semantics.h
-
-SPREG_H = \
- spreg.h
-
-SUPPORT_H = \
- support.h \
- support.c
-
-INLINE = \
- inline.h \
- inline.c
-
-LIB_INLINE_SRC = \
- psim.c \
- bits.c \
- debug.c \
- sim-endian.c \
- sim-endian.h \
- sim-endian-n.h \
- vm.c \
- vm_n.h \
- corefile.c \
- events.c \
- os_emul.c \
- registers.c \
- cpu.c \
- interrupts.c \
- device.c \
- tree.c \
- device_table.c \
- cap.c \
- mon.c \
- options.c
-
-LIB_SRC = \
- $(PACKAGE_SRC) \
- $(HW_SRC) \
- $(LIB_INLINE_SRC)
-
-COMMON_OBJS_NAMES = \
- callback.o \
- target-newlib-errno.o \
- target-newlib-open.o \
- target-newlib-signal.o \
- target-newlib-syscall.o \
- version.o
-COMMON_OBJS = $(COMMON_OBJS_NAMES:%=../common/%)
-
-# NOTE: semantics, idecode and psim put last so smaller files are compiled
-# first
-LIB_OBJ = \
- debug.o \
- bits.o \
- sim-endian.o \
- os_emul.o \
- emul_generic.o \
- emul_bugapi.o \
- emul_chirp.o \
- emul_netbsd.o \
- emul_unix.o \
- registers.o \
- vm.o \
- corefile.o \
- model.o \
- spreg.o \
- cpu.o \
- interrupts.o \
- events.o \
- cap.o \
- device.o \
- tree.o \
- device_table.o \
- itable.o \
- mon.o \
- icache.o \
- semantics.o \
- idecode.o \
- support.o \
- sim-fpu.o \
- psim.o \
- $(COMMON_OBJS) \
- $(PACKAGE_OBJ) \
- $(HW_OBJ) \
- options.o
-
-
-GDB_OBJ = gdb-sim.o sim_calls.o
-
-HW_SRC = @sim_ppc_hw_src@
-HW_OBJ = @sim_ppc_hw_obj@
-
-PACKAGE_SRC = pk_disklabel.c
-PACKAGE_OBJ = $(PACKAGE_SRC:.c=.o)
-
-
-psim.o: psim.c $(CPU_H) $(IDECODE_H) $(OPTIONS_H) $(TREE_H) $(BFD_H)
-
-bits.o: bits.c $(BASICS_H)
-
-debug.o: debug.c $(BASICS_H)
-
-sim-endian.o: sim-endian.c $(BASICS_H) $(SIM_ENDIAN_N_H)
-
-os_emul.o: os_emul.c $(CPU_H) $(IDECODE_H) $(OS_EMUL_H) $(EMUL_GENERIC_H) $(EMUL_NETBSD_H) $(EMUL_UNIX_H) $(EMUL_CHIRP_H) $(EMUL_BUGAPI_H)
-emul_generic.o: emul_generic.c $(EMUL_GENERIC_H)
-
-emul_bugapi.o: emul_bugapi.c $(EMUL_GENERIC_H) $(EMUL_BUGAPI_H)
-emul_chirp.o: emul_chirp.c $(EMUL_GENERIC_H) $(EMUL_CHIRP_H)
-emul_netbsd.o: emul_netbsd.c $(EMUL_GENERIC_H) $(EMUL_NETBSD_H)
-emul_unix.o: emul_unix.c $(EMUL_GENERIC_H) $(EMUL_UNIX_H)
-
-registers.o: registers.c $(BASICS_H) $(REGISTERS_H)
-
-cpu.o: cpu.c $(CPU_H) $(IDECODE_H)
-
-interrupts.o: interrupts.c $(CPU_H) $(IDECODE_H) $(OS_EMUL_H)
-
-# Given that inlines are turned on now, rebuild idecode whenever
-# anything changes.
-idecode.o: idecode.c $(CPU_H) $(IDECODE_H) $(SEMANTICS_H) $(LIB_INLINE_SRC)
-
-# double.o: double.c dp-bit.c
-
-vm.o: vm.c $(BASICS_H) $(REGISTERS_H) $(DEVICE_H) $(COREFILE_H) $(VM_H) $(INTERRUPTS_H) $(MON_H) $(CPU_H) $(VM_N_H)
-
-corefile.o: corefile.c $(BASICS_H) $(DEVICE_TABLE_H) $(COREFILE_H) $(COREFILE_N_H)
-
-model.o: model.c $(CPU_H) $(MON_H)
-
-events.o: events.c $(BASICS_H) $(EVENTS_H)
-
-sim_calls.o: sim_calls.c $(PSIM_H) $(OPTIONS_H) $(DEFS_H) $(BFD_H) $(GDB_CALLBACK_H) $(GDB_REMOTE_SIM_H)
-
-gdb-sim.o: gdb-sim.c $(PSIM_H) $(OPTIONS_H) $(REGISTERS_H) $(GDB_REMOTE_SIM_H) $(GDB_SIM_PPC_H) $(SIM_CALLBACK_H)
-
-spreg.o: spreg.c $(BASICS_H) $(SPREG_H)
-
-device.o: device.c $(DEVICE_TABLE_H) $(CAP_H) $(EVENTS_H) $(PSIM_H)
-
-tree.o: tree.c $(BASICS_H) $(DEVICE_H) $(TREE_H)
-
-device_table.o: device_table.c $(DEVICE_TABLE_H) hw.c
-
-cap.o: cap.c $(CAP_H)
-
-semantics.o: semantics.c $(CPU_H) $(IDECODE_H) $(SEMANTICS_H) $(COMMON_SIM_INLINE_H) $(COMMON_SIM_FPU_H) $(SUPPORT_H)
-
-icache.o: icache.c $(CPU_H) $(IDECODE_H) $(SEMANTICS_H) $(ICACHE_H) $(COMMON_SIM_INLINE_H) $(COMMON_SIM_FPU_H) $(SUPPORT_H)
-
-support.o: support.c $(CPU_H) $(IDECODE_H) $(COMMON_SIM_INLINE_H) $(COMMON_SIM_FPU_H) $(SUPPORT_H)
-
-itable.o: itable.c $(ITABLE_H)
-
-mon.o: mon.c $(BASICS_H) $(CPU_H) $(MON_H)
-
-sim-fpu.o: $(srcdir)/../common/sim-fpu.c
- $(ECHO_CC) $(CC) -c $(STD_CFLAGS) -DHAVE_CONFIG_H $(srcdir)/../common/sim-fpu.c
-
-# Rebuild options whenever something changes so the date/time is up to date.
-options.o: options.c $(CPU_H) $(OPTIONS_H) $(DEFINES_H) $(BASICS_H) $(IDECODE_H) $(INLINE) $(LIB_SRC) ../config.status Makefile
- $(ECHO_CC) $(CC) -c $(STD_CFLAGS) '-DOPCODE_RULES="@sim_ppc_opcode@"' '-DIGEN_FLAGS="$(ppc_IGEN_FLAGS)"' $(srcdir)/options.c
-
-hw_cpu.o: hw_cpu.c $(DEVICE_TABLE_H) $(HW_CPU_H) $(INTERRUPTS_H) $(CPU_H)
-hw_com.o: hw_com.c $(DEVICE_TABLE_H)
-hw_core.o: hw_core.c $(DEVICE_TABLE_H) $(COREFILE_H)
-hw_disk.o: hw_disk.c $(DEVICE_TABLE_H) $(PK_H)
-hw_eeprom.o: hw_eeprom.c $(DEVICE_TABLE_H)
-hw_glue.o: hw_glue.c $(DEVICE_TABLE_H)
-hw_htab.o: hw_htab.c $(DEVICE_TABLE_H) $(BFD_H)
-hw_ide.o: hw_ide.c $(DEVICE_TABLE_H)
-hw_init.o: hw_init.c $(DEVICE_TABLE_H) $(BFD_H) $(PSIM_H)
-hw_iobus.o: hw_iobus.c $(DEVICE_TABLE_H)
-hw_memory.o: hw_memory.c $(DEVICE_TABLE_H)
-hw_nvram.o: hw_nvram.c $(DEVICE_TABLE_H)
-hw_opic.o: hw_opic.c $(DEVICE_TABLE_H)
-hw_pal.o: hw_pal.c $(DEVICE_TABLE_H) $(CPU_H)
-hw_phb.o: hw_phb.c $(DEVICE_TABLE_H) $(HW_PHB_H) $(COREFILE_H)
-hw_register.o: hw_register.c $(DEVICE_TABLE_H) $(PSIM_H)
-hw_sem.o: hw_sem.c $(DEVICE_TABLE_H) $(PSIM_H)
-hw_shm.o: hw_shm.c $(DEVICE_TABLE_H) $(PSIM_H)
-hw_trace.o: hw_trace.c $(DEVICE_TABLE_H)
-hw_vm.o: hw_vm.c $(DEVICE_TABLE_H) $(CPU_H)
-# ignore this line, it stops make from getting confused
-
-
-
-pk_disklabel.o: pk_disklabel.c $(DEVICE_TABLE_H) $(PK_H)
-# ignore this line, it stops make from getting confused
-
-
-
-tags etags: TAGS
-
-TAGS:
- etags $(srcdir)/*.h $(srcdir)/*.c
-
-clean mostlyclean:
- rm -f tmp-* *.[oasi] core
-
-distclean realclean: clean
- rm -f TAGS Makefile
-
-maintainer-clean: distclean
- rm -f *~ *.log core *.core
-
-Makefile: Makefile.in ../config.status
- cd .. && $(SHELL) ./config.status ppc/Makefile
-
-../config.status: ../configure
- cd .. && $(SHELL) ./config.status --recheck
-
-check:
-
-html:
-clean-html:
-install-html:
-
-info:
-clean-info:
-install-info:
-
-pdf:
-clean-pdf:
-install-pdf:
-
-install:
-installdirs:
-uninstall:
diff --git a/sim/ppc/local.mk b/sim/ppc/local.mk
index 90f9489..01cc125 100644
--- a/sim/ppc/local.mk
+++ b/sim/ppc/local.mk
@@ -25,6 +25,7 @@ AM_CPPFLAGS_%C% = \
$(sim_ppc_monitor) \
$(sim_ppc_model) $(sim_ppc_default_model) $(sim_ppc_model_issue) \
$(sim_ppc_switch)
+AM_CPPFLAGS_%C%_options.o = '-DOPCODE_RULES="$(IGEN_OPCODE_RULES)"' '-DIGEN_FLAGS="$(ppc_IGEN_FLAGS)"'
%C%_libsim_a_SOURCES = \
$(common_libcommon_a_SOURCES)
@@ -79,11 +80,6 @@ noinst_LIBRARIES += %D%/libsim.a
%D%/libsim.a \
$(SIM_COMMON_LIBS)
-## This makes sure common parts are available before building the arch-subdirs
-## which will refer to these.
-%D%/%.o: %D%/%.c | common/libcommon.a %D%/defines.h %D%/stamp-igen %D%/hw.c %D%/hw.h
- $(AM_V_at)$(MAKE) $(AM_MAKEFLAGS) -C $(@D) $(@F)
-
noinst_PROGRAMS += %D%/run
%D%/defines.h: %D%/stamp-defines ; @true
@@ -92,6 +88,7 @@ noinst_PROGRAMS += %D%/run
$(AM_V_at)$(SHELL) $(srcroot)/move-if-change %D%/defines.hin %D%/defines.h
$(AM_V_at)touch $@
+BUILT_SOURCES += %D%/defines.h
MOSTLYCLEANFILES += %D%/defines.h %D%/stamp-defines
%D%/spreg.c: @MAINT@ %D%/ppc-spr-table %D%/spreg-gen.py %D%/$(am__dirstamp)