diff options
author | Mike Frysinger <vapier@gentoo.org> | 2024-01-02 00:24:22 -0500 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2024-01-02 00:35:59 -0500 |
commit | 93c0f1cf94b4fc70a02567018477d75b8771ab27 (patch) | |
tree | 30cb39e9c904dbf4af853f9cbc33c5512a0fbd9a /sim/ppc | |
parent | 82931068f4d6e82e686e384fde89c3b2eb3e349a (diff) | |
download | gdb-93c0f1cf94b4fc70a02567018477d75b8771ab27.zip gdb-93c0f1cf94b4fc70a02567018477d75b8771ab27.tar.gz gdb-93c0f1cf94b4fc70a02567018477d75b8771ab27.tar.bz2 |
sim: ppc: move defines.h generation to the top-level
Since we rely on the top-level config.h now, the defines.h generation
step should live here too.
Diffstat (limited to 'sim/ppc')
-rw-r--r-- | sim/ppc/Makefile.in | 10 | ||||
-rw-r--r-- | sim/ppc/local.mk | 9 |
2 files changed, 11 insertions, 8 deletions
diff --git a/sim/ppc/Makefile.in b/sim/ppc/Makefile.in index 71199fc..2f638b0 100644 --- a/sim/ppc/Makefile.in +++ b/sim/ppc/Makefile.in @@ -489,7 +489,7 @@ PACKAGE_SRC = pk_disklabel.c PACKAGE_OBJ = $(PACKAGE_SRC:.c=.o) -$(TARGETLIB): tmp-igen tmp-hw tmp-defines $(LIB_OBJ) $(GDB_OBJ) +$(TARGETLIB): tmp-igen tmp-hw defines.h $(LIB_OBJ) $(GDB_OBJ) $(ECHO_AR) $(AR) $(AR_FLAGS) $(TARGETLIB) $(LIB_OBJ) $(GDB_OBJ) $(ECHO_RANLIB) $(RANLIB) $(TARGETLIB) @@ -562,12 +562,6 @@ sim-fpu.o: $(srcdir)/../common/sim-fpu.c options.o: options.c $(CPU_H) $(OPTIONS_H) $(DEFINES_H) $(BASICS_H) $(IDECODE_H) $(INLINE) $(LIB_SRC) $(BUILT_SRC) config.status Makefile $(ECHO_CC) $(CC) -c $(STD_CFLAGS) '-DOPCODE_RULES="@sim_opcode@"' '-DIGEN_FLAGS="$(IGEN_FLAGS)"' $(srcdir)/options.c -defines.h: tmp-defines; @true -tmp-defines: Makefile - $(ECHO_GEN) sed -n -e '/^#define HAVE_/s/ 1$$/",/' -e '/^#define HAVE_/s//"HAVE_/p' < ../config.h > tmp-defines.h - $(SILENCE) $(SHELL) $(srcroot)/move-if-change tmp-defines.h defines.h - $(SILENCE) touch $@ - # # Rules to create the built c source code files # @@ -685,7 +679,7 @@ clean mostlyclean: rm -f tmp-* *.[oasi] core $(BUILT_SRC_WO_CONFIG) distclean realclean: clean - rm -f TAGS Makefile config.cache config.status defines.h stamp-h config.log + rm -f TAGS Makefile config.cache config.status stamp-h config.log maintainer-clean: distclean rm -f *~ *.log core *.core diff --git a/sim/ppc/local.mk b/sim/ppc/local.mk index 8bcc7e7..e2d6197 100644 --- a/sim/ppc/local.mk +++ b/sim/ppc/local.mk @@ -33,6 +33,15 @@ SIM_ALL_RECURSIVE_DEPS += common/libcommon.a noinst_PROGRAMS += %D%/run +SIM_ALL_RECURSIVE_DEPS += %D%/defines.h +%D%/defines.h: %D%/stamp-defines ; @true +%D%/stamp-defines: config.h Makefile + $(AM_V_GEN)sed -n -e '/^#define HAVE_/s/ 1$$/",/' -e '/^#define HAVE_/s//"HAVE_/p' < config.h > %D%/defines.hin + $(AM_V_at)$(SHELL) $(srcroot)/move-if-change %D%/defines.hin %D%/defines.h + $(AM_V_at)touch $@ + +MOSTLYCLEANFILES += %D%/defines.h %D%/stamp-defines + %D%/spreg.c: @MAINT@ %D%/ppc-spr-table %D%/spreg-gen.py %D%/$(am__dirstamp) $(AM_V_GEN)$(srcdir)/%D%/spreg-gen.py --source $@.tmp $(AM_V_at)$(SHELL) $(srcroot)/move-if-change $@.tmp $(srcdir)/%D%/spreg.c |