diff options
author | Christoph Müllner <christoph.muellner@vrull.eu> | 2023-02-02 00:09:58 +0100 |
---|---|---|
committer | Christoph Müllner <christophm30@gmail.com> | 2023-02-20 10:25:25 +0100 |
commit | 31cbfd5b21b5e7c89b8803b9d65638584f926db8 (patch) | |
tree | b7be2f51bab3286b3002d6a3f2e3fcabced4c386 | |
parent | 8e7ce0e143d19dbbe7e93f4e5c29e64a997e1fa5 (diff) | |
download | riscv-gnu-toolchain-31cbfd5b21b5e7c89b8803b9d65638584f926db8.zip riscv-gnu-toolchain-31cbfd5b21b5e7c89b8803b9d65638584f926db8.tar.gz riscv-gnu-toolchain-31cbfd5b21b5e7c89b8803b9d65638584f926db8.tar.bz2 |
dejagnu: Allow source dir override
We have this feature for all other packages.
It is particularly useful to avoid pointless internet downloads
for automatic builds.
Signed-off-by: Christoph Müllner <christoph.muellner@vrull.eu>
-rw-r--r-- | Makefile.in | 9 | ||||
-rwxr-xr-x | configure | 22 | ||||
-rw-r--r-- | configure.ac | 1 |
3 files changed, 31 insertions, 1 deletions
diff --git a/Makefile.in b/Makefile.in index 71369ab..e9a6461 100644 --- a/Makefile.in +++ b/Makefile.in @@ -12,6 +12,7 @@ GDB_SRCDIR := @with_gdb_src@ QEMU_SRCDIR := @with_qemu_src@ SPIKE_SRCDIR := @with_spike_src@ PK_SRCDIR := @with_pk_src@ +DEJAGNU_SRCDIR := @with_dejagnu_src@ SIM ?= @WITH_SIM@ @@ -272,6 +273,12 @@ else SPIKE_SRC_GIT := endif +ifeq ($(findstring $(srcdir),$(DEJAGNU_SRCDIR)),$(srcdir)) +DEJAGNU_SRC_DIR := $(DEJAGNU_SRCDIR)/.git +else +DEJAGNU_SRC_DIR := +endif + ifneq ("$(wildcard $(GCC_SRCDIR)/.git)","") GCCPKGVER := g$(shell git -C $(GCC_SRCDIR) describe --always --dirty --exclude '*') else @@ -865,7 +872,7 @@ stamps/build-qemu: $(QEMU_SRCDIR) $(QEMU_SRC_GIT) mkdir -p $(dir $@) date > $@ -stamps/build-dejagnu: $(srcdir)/dejagnu $(srcdir)/dejagnu/.git +stamps/build-dejagnu: $(DEJAGNU_SRCDIR) $(DEJAGNU_SRC_GIT) rm -rf $@ $(notdir $@) mkdir $(notdir $@) cd $(notdir $@) && $</configure \ @@ -588,6 +588,7 @@ qemu_targets enable_libsanitizer with_linux_headers_src with_pk_src +with_dejagnu_src with_spike_src with_qemu_src with_gdb_src @@ -699,6 +700,7 @@ with_gdb_src with_qemu_src with_spike_src with_pk_src +with_dejagnu_src with_linux_headers_src enable_libsanitizer enable_qemu_system @@ -3730,6 +3732,26 @@ fi } +{ + +# Check whether --with-dejagnu-src was given. +if test "${with_dejagnu_src+set}" = set; then : + withval=$with_dejagnu_src; +else + with_dejagnu_src=default + +fi + + if test "x$with_dejagnu_src" != xdefault; then : + with_dejagnu_src=$with_dejagnu_src + +else + with_dejagnu_src="\$(srcdir)/dejagnu" + +fi + + } + # Check whether --with-linux-headers-src was given. if test "${with_linux_headers_src+set}" = set; then : diff --git a/configure.ac b/configure.ac index 16178c7..b838b64 100644 --- a/configure.ac +++ b/configure.ac @@ -244,6 +244,7 @@ AX_ARG_WITH_SRC(gdb, gdb) AX_ARG_WITH_SRC(qemu, qemu) AX_ARG_WITH_SRC(spike, spike) AX_ARG_WITH_SRC(pk, pk) +AX_ARG_WITH_SRC(dejagnu, dejagnu) AC_ARG_WITH(linux-headers-src, [AC_HELP_STRING([--with-linux-headers-src], |