aboutsummaryrefslogtreecommitdiff
path: root/sim
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-12-04 13:35:25 -0500
committerMike Frysinger <vapier@gentoo.org>2021-12-04 13:55:13 -0500
commit94f5dfed74985a1a8ff4b8bf1a383f46621e5f8c (patch)
tree866b2f65e89744e2568a2a15c03abaf856652123 /sim
parent520e19d589b558e569f4945f34f9ac67f550a542 (diff)
downloadfsf-binutils-gdb-94f5dfed74985a1a8ff4b8bf1a383f46621e5f8c.zip
fsf-binutils-gdb-94f5dfed74985a1a8ff4b8bf1a383f46621e5f8c.tar.gz
fsf-binutils-gdb-94f5dfed74985a1a8ff4b8bf1a383f46621e5f8c.tar.bz2
sim: moxie: hoist dtb rules up to common builds
These rules don't depend on the target compiler settings, so hoist the build logic up to the common builds for better parallelization.
Diffstat (limited to 'sim')
-rw-r--r--sim/Makefile.am3
-rw-r--r--sim/Makefile.in110
-rw-r--r--sim/moxie/Makefile.in20
-rw-r--r--sim/moxie/local.mk32
4 files changed, 116 insertions, 49 deletions
diff --git a/sim/Makefile.am b/sim/Makefile.am
index c3e7e76..b58f50a 100644
--- a/sim/Makefile.am
+++ b/sim/Makefile.am
@@ -107,6 +107,9 @@ endif
if SIM_ENABLE_ARCH_mn10300
include mn10300/local.mk
endif
+if SIM_ENABLE_ARCH_moxie
+include moxie/local.mk
+endif
if SIM_ENABLE_ARCH_or1k
include or1k/local.mk
endif
diff --git a/sim/Makefile.in b/sim/Makefile.in
index ff36e2d..f2abfb8 100644
--- a/sim/Makefile.in
+++ b/sim/Makefile.in
@@ -334,6 +334,23 @@
# See sim/Makefile.am
#
+# Copyright (C) 1993-2021 Free Software Foundation, Inc.
+#
+# 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/>.
+
+# See sim/Makefile.am
+#
# Copyright (C) 2017-2021 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
@@ -849,12 +866,12 @@ am__uninstall_files_from_dir = { \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
-am__installdirs = "$(DESTDIR)$(armdocdir)" "$(DESTDIR)$(erc32docdir)" \
- "$(DESTDIR)$(frvdocdir)" "$(DESTDIR)$(or1kdocdir)" \
- "$(DESTDIR)$(ppcdocdir)" "$(DESTDIR)$(rxdocdir)" \
- "$(DESTDIR)$(pkgincludedir)"
-DATA = $(armdoc_DATA) $(erc32doc_DATA) $(frvdoc_DATA) $(or1kdoc_DATA) \
- $(ppcdoc_DATA) $(rxdoc_DATA)
+am__installdirs = "$(DESTDIR)$(armdocdir)" "$(DESTDIR)$(dtbdir)" \
+ "$(DESTDIR)$(erc32docdir)" "$(DESTDIR)$(frvdocdir)" \
+ "$(DESTDIR)$(or1kdocdir)" "$(DESTDIR)$(ppcdocdir)" \
+ "$(DESTDIR)$(rxdocdir)" "$(DESTDIR)$(pkgincludedir)"
+DATA = $(armdoc_DATA) $(dtb_DATA) $(erc32doc_DATA) $(frvdoc_DATA) \
+ $(or1kdoc_DATA) $(ppcdoc_DATA) $(rxdoc_DATA)
am__pkginclude_HEADERS_DIST = $(srcroot)/include/sim/callback.h \
$(srcroot)/include/sim/sim.h
HEADERS = $(pkginclude_HEADERS)
@@ -1558,6 +1575,8 @@ testsuite_common_CPPFLAGS = \
@SIM_ENABLE_ARCH_mn10300_TRUE@mn10300_IGEN_INSN = $(srcdir)/mn10300/mn10300.igen
@SIM_ENABLE_ARCH_mn10300_TRUE@mn10300_IGEN_INSN_INC = mn10300/am33.igen mn10300/am33-2.igen
@SIM_ENABLE_ARCH_mn10300_TRUE@mn10300_IGEN_DC = $(srcdir)/mn10300/mn10300.dc
+@SIM_ENABLE_ARCH_moxie_TRUE@dtbdir = $(datadir)/gdb/dtb
+@SIM_ENABLE_ARCH_moxie_TRUE@dtb_DATA = moxie/moxie-gdb.dtb
@SIM_ENABLE_ARCH_or1k_TRUE@or1kdocdir = $(docdir)/or1k
@SIM_ENABLE_ARCH_or1k_TRUE@or1kdoc_DATA = or1k/README
@SIM_ENABLE_ARCH_or1k_TRUE@or1k_BUILD_OUTPUTS = \
@@ -1607,7 +1626,7 @@ all: config.h
.SUFFIXES: .c .lo .log .o .obj .test .test$(EXEEXT) .trs
am--refresh: Makefile
@:
-$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/common/local.mk $(srcdir)/igen/local.mk $(srcdir)/testsuite/local.mk $(srcdir)/testsuite/common/local.mk $(srcdir)/arm/local.mk $(srcdir)/bpf/local.mk $(srcdir)/cr16/local.mk $(srcdir)/cris/local.mk $(srcdir)/d10v/local.mk $(srcdir)/erc32/local.mk $(srcdir)/frv/local.mk $(srcdir)/iq2000/local.mk $(srcdir)/lm32/local.mk $(srcdir)/m32c/local.mk $(srcdir)/m32r/local.mk $(srcdir)/m68hc11/local.mk $(srcdir)/mn10300/local.mk $(srcdir)/or1k/local.mk $(srcdir)/ppc/local.mk $(srcdir)/rx/local.mk $(srcdir)/sh/local.mk $(srcdir)/v850/local.mk $(am__configure_deps)
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/common/local.mk $(srcdir)/igen/local.mk $(srcdir)/testsuite/local.mk $(srcdir)/testsuite/common/local.mk $(srcdir)/arm/local.mk $(srcdir)/bpf/local.mk $(srcdir)/cr16/local.mk $(srcdir)/cris/local.mk $(srcdir)/d10v/local.mk $(srcdir)/erc32/local.mk $(srcdir)/frv/local.mk $(srcdir)/iq2000/local.mk $(srcdir)/lm32/local.mk $(srcdir)/m32c/local.mk $(srcdir)/m32r/local.mk $(srcdir)/m68hc11/local.mk $(srcdir)/mn10300/local.mk $(srcdir)/moxie/local.mk $(srcdir)/or1k/local.mk $(srcdir)/ppc/local.mk $(srcdir)/rx/local.mk $(srcdir)/sh/local.mk $(srcdir)/v850/local.mk $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
@@ -1629,7 +1648,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
esac;
-$(srcdir)/common/local.mk $(srcdir)/igen/local.mk $(srcdir)/testsuite/local.mk $(srcdir)/testsuite/common/local.mk $(srcdir)/arm/local.mk $(srcdir)/bpf/local.mk $(srcdir)/cr16/local.mk $(srcdir)/cris/local.mk $(srcdir)/d10v/local.mk $(srcdir)/erc32/local.mk $(srcdir)/frv/local.mk $(srcdir)/iq2000/local.mk $(srcdir)/lm32/local.mk $(srcdir)/m32c/local.mk $(srcdir)/m32r/local.mk $(srcdir)/m68hc11/local.mk $(srcdir)/mn10300/local.mk $(srcdir)/or1k/local.mk $(srcdir)/ppc/local.mk $(srcdir)/rx/local.mk $(srcdir)/sh/local.mk $(srcdir)/v850/local.mk $(am__empty):
+$(srcdir)/common/local.mk $(srcdir)/igen/local.mk $(srcdir)/testsuite/local.mk $(srcdir)/testsuite/common/local.mk $(srcdir)/arm/local.mk $(srcdir)/bpf/local.mk $(srcdir)/cr16/local.mk $(srcdir)/cris/local.mk $(srcdir)/d10v/local.mk $(srcdir)/erc32/local.mk $(srcdir)/frv/local.mk $(srcdir)/iq2000/local.mk $(srcdir)/lm32/local.mk $(srcdir)/m32c/local.mk $(srcdir)/m32r/local.mk $(srcdir)/m68hc11/local.mk $(srcdir)/mn10300/local.mk $(srcdir)/moxie/local.mk $(srcdir)/or1k/local.mk $(srcdir)/ppc/local.mk $(srcdir)/rx/local.mk $(srcdir)/sh/local.mk $(srcdir)/v850/local.mk $(am__empty):
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
$(SHELL) ./config.status --recheck
@@ -2142,6 +2161,27 @@ uninstall-armdocDATA:
@list='$(armdoc_DATA)'; test -n "$(armdocdir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(armdocdir)'; $(am__uninstall_files_from_dir)
+install-dtbDATA: $(dtb_DATA)
+ @$(NORMAL_INSTALL)
+ @list='$(dtb_DATA)'; test -n "$(dtbdir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(dtbdir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(dtbdir)" || exit 1; \
+ fi; \
+ for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ echo "$$d$$p"; \
+ done | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(dtbdir)'"; \
+ $(INSTALL_DATA) $$files "$(DESTDIR)$(dtbdir)" || exit $$?; \
+ done
+
+uninstall-dtbDATA:
+ @$(NORMAL_UNINSTALL)
+ @list='$(dtb_DATA)'; test -n "$(dtbdir)" || list=; \
+ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
+ dir='$(DESTDIR)$(dtbdir)'; $(am__uninstall_files_from_dir)
install-erc32docDATA: $(erc32doc_DATA)
@$(NORMAL_INSTALL)
@list='$(erc32doc_DATA)'; test -n "$(erc32docdir)" || list=; \
@@ -2604,7 +2644,7 @@ check: check-recursive
all-am: Makefile $(LIBRARIES) $(DATA) $(HEADERS) config.h
installdirs: installdirs-recursive
installdirs-am:
- for dir in "$(DESTDIR)$(armdocdir)" "$(DESTDIR)$(erc32docdir)" "$(DESTDIR)$(frvdocdir)" "$(DESTDIR)$(or1kdocdir)" "$(DESTDIR)$(ppcdocdir)" "$(DESTDIR)$(rxdocdir)" "$(DESTDIR)$(pkgincludedir)"; do \
+ for dir in "$(DESTDIR)$(armdocdir)" "$(DESTDIR)$(dtbdir)" "$(DESTDIR)$(erc32docdir)" "$(DESTDIR)$(frvdocdir)" "$(DESTDIR)$(or1kdocdir)" "$(DESTDIR)$(ppcdocdir)" "$(DESTDIR)$(rxdocdir)" "$(DESTDIR)$(pkgincludedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-recursive
@@ -2684,8 +2724,8 @@ info: info-recursive
info-am:
-install-data-am: install-armdocDATA install-erc32docDATA \
- install-frvdocDATA install-or1kdocDATA \
+install-data-am: install-armdocDATA install-dtbDATA \
+ install-erc32docDATA install-frvdocDATA install-or1kdocDATA \
install-pkgincludeHEADERS install-ppcdocDATA install-rxdocDATA
install-dvi: install-dvi-recursive
@@ -2734,10 +2774,10 @@ ps: ps-recursive
ps-am:
-uninstall-am: uninstall-armdocDATA uninstall-erc32docDATA \
- uninstall-frvdocDATA uninstall-or1kdocDATA \
- uninstall-pkgincludeHEADERS uninstall-ppcdocDATA \
- uninstall-rxdocDATA
+uninstall-am: uninstall-armdocDATA uninstall-dtbDATA \
+ uninstall-erc32docDATA uninstall-frvdocDATA \
+ uninstall-or1kdocDATA uninstall-pkgincludeHEADERS \
+ uninstall-ppcdocDATA uninstall-rxdocDATA
.MAKE: $(am__recursive_targets) all check-am install-am install-strip
@@ -2749,20 +2789,20 @@ uninstall-am: uninstall-armdocDATA uninstall-erc32docDATA \
distclean-generic distclean-hdr distclean-libtool \
distclean-tags dvi dvi-am html html-am info info-am install \
install-am install-armdocDATA install-data install-data-am \
- install-dvi install-dvi-am install-erc32docDATA install-exec \
- install-exec-am install-frvdocDATA install-html \
- install-html-am install-info install-info-am install-man \
- install-or1kdocDATA install-pdf install-pdf-am \
- install-pkgincludeHEADERS install-ppcdocDATA install-ps \
- install-ps-am install-rxdocDATA install-strip installcheck \
- installcheck-am installdirs installdirs-am maintainer-clean \
- maintainer-clean-generic mostlyclean mostlyclean-compile \
- mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
- recheck tags tags-am uninstall uninstall-am \
- uninstall-armdocDATA uninstall-erc32docDATA \
- uninstall-frvdocDATA uninstall-or1kdocDATA \
- uninstall-pkgincludeHEADERS uninstall-ppcdocDATA \
- uninstall-rxdocDATA
+ install-dtbDATA install-dvi install-dvi-am \
+ install-erc32docDATA install-exec install-exec-am \
+ install-frvdocDATA install-html install-html-am install-info \
+ install-info-am install-man install-or1kdocDATA install-pdf \
+ install-pdf-am install-pkgincludeHEADERS install-ppcdocDATA \
+ install-ps install-ps-am install-rxdocDATA install-strip \
+ installcheck installcheck-am installdirs installdirs-am \
+ maintainer-clean maintainer-clean-generic mostlyclean \
+ mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
+ pdf pdf-am ps ps-am recheck tags tags-am uninstall \
+ uninstall-am uninstall-armdocDATA uninstall-dtbDATA \
+ uninstall-erc32docDATA uninstall-frvdocDATA \
+ uninstall-or1kdocDATA uninstall-pkgincludeHEADERS \
+ uninstall-ppcdocDATA uninstall-rxdocDATA
.PRECIOUS: Makefile
@@ -3106,6 +3146,18 @@ testsuite/common/bits64m63.c: testsuite/common/bits-gen$(EXEEXT) testsuite/commo
@SIM_ENABLE_ARCH_mn10300_TRUE@ $(AM_V_at)$(SHELL) $(srcroot)/move-if-change mn10300/tmp-irun.c mn10300/irun.c
@SIM_ENABLE_ARCH_mn10300_TRUE@ $(AM_V_at)touch $@
+@SIM_ENABLE_ARCH_moxie_TRUE@moxie/moxie-gdb.dtb: @MAINT@ moxie/moxie-gdb.dts moxie/$(am__dirstamp)
+@SIM_ENABLE_ARCH_moxie_TRUE@ $(AM_V_GEN) \
+@SIM_ENABLE_ARCH_moxie_TRUE@ if test "x$(DTC)" != x; then \
+@SIM_ENABLE_ARCH_moxie_TRUE@ $(DTC) -O dtb -o $@.tmp ${srcdir}/moxie/moxie-gdb.dts || exit 1; \
+@SIM_ENABLE_ARCH_moxie_TRUE@ $(SHELL) $(srcroot)/move-if-change $@.tmp ${srcdir}/moxie/moxie-gdb.dtb || exit 1; \
+@SIM_ENABLE_ARCH_moxie_TRUE@ touch ${srcdir}/moxie/moxie-gdb.dtb; \
+@SIM_ENABLE_ARCH_moxie_TRUE@ else \
+@SIM_ENABLE_ARCH_moxie_TRUE@ echo "Could not update the moxie-gdb.dtb file because the device "; \
+@SIM_ENABLE_ARCH_moxie_TRUE@ echo "tree compiler tool (dtc) is missing. Install the tool to "; \
+@SIM_ENABLE_ARCH_moxie_TRUE@ echo "update the device tree blob."; \
+@SIM_ENABLE_ARCH_moxie_TRUE@ fi
+
# FIXME: Use of `mono' is wip.
@SIM_ENABLE_ARCH_or1k_TRUE@or1k/mloop.c or1k/eng.h: or1k/stamp-mloop ; @true
@SIM_ENABLE_ARCH_or1k_TRUE@or1k/stamp-mloop: $(srccom)/genmloop.sh or1k/mloop.in
diff --git a/sim/moxie/Makefile.in b/sim/moxie/Makefile.in
index 6671389..0e8b20a 100644
--- a/sim/moxie/Makefile.in
+++ b/sim/moxie/Makefile.in
@@ -17,32 +17,12 @@
## COMMON_PRE_CONFIG_FRAG
-dtbdir = $(datadir)/gdb/dtb
-
SIM_OBJS = \
$(SIM_NEW_COMMON_OBJS) \
interp.o \
sim-resume.o
SIM_EXTRA_LIBS = -lm -lz
-SIM_EXTRA_INSTALL = install-dtb
SIM_EXTRA_CFLAGS = -DDTB="\"$(dtbdir)/moxie-gdb.dtb\""
## COMMON_POST_CONFIG_FRAG
-
-all: moxie-gdb.dtb
-
-moxie-gdb.dtb: $(MAINT) moxie-gdb.dts
- @echo Regenerating moxie-gdb.dtb
- if test "x$(DTC)" != x; then \
- $(DTC) -O dtb -o moxie-gdb.dtb ${srcdir}/moxie-gdb.dts || exit 1; \
- $(SHELL) $(srcroot)/move-if-change moxie-gdb.dtb ${srcdir}/moxie-gdb.dtb || exit 1; \
- else \
- echo "Could not update the moxie-gdb.dtb file because the device "; \
- echo "tree compiler tool (dtc) is missing. Install the tool to "; \
- echo "update the device tree blob."; \
- fi
-
-install-dtb: moxie-gdb.dtb
- $(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)$(dtbdir)
- $(INSTALL_DATA) $(srcdir)/moxie-gdb.dtb $(DESTDIR)$(dtbdir)/moxie-gdb.dtb
diff --git a/sim/moxie/local.mk b/sim/moxie/local.mk
new file mode 100644
index 0000000..b73bd85
--- /dev/null
+++ b/sim/moxie/local.mk
@@ -0,0 +1,32 @@
+# See sim/Makefile.am
+#
+# Copyright (C) 1993-2021 Free Software Foundation, Inc.
+#
+# 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/>.
+
+dtbdir = $(datadir)/gdb/dtb
+
+dtb_DATA = %D%/moxie-gdb.dtb
+
+%D%/moxie-gdb.dtb: @MAINT@ %D%/moxie-gdb.dts %D%/$(am__dirstamp)
+ $(AM_V_GEN) \
+ if test "x$(DTC)" != x; then \
+ $(DTC) -O dtb -o $@.tmp ${srcdir}/%D%/moxie-gdb.dts || exit 1; \
+ $(SHELL) $(srcroot)/move-if-change $@.tmp ${srcdir}/%D%/moxie-gdb.dtb || exit 1; \
+ touch ${srcdir}/%D%/moxie-gdb.dtb; \
+ else \
+ echo "Could not update the moxie-gdb.dtb file because the device "; \
+ echo "tree compiler tool (dtc) is missing. Install the tool to "; \
+ echo "update the device tree blob."; \
+ fi