/usr/src/gcc-4.7/debian/patches/libgo-testsuite.diff is in gcc-4.7-source 4.7.3-12ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | # DP: Only run the libgo testsuite for flags configured in RUNTESTFLAGS
--- a/src/libgo/Makefile.am
+++ b/src/libgo/Makefile.am
@@ -1809,6 +1809,12 @@
export LD_LIBRARY_PATH; \
$(MKDIR_P) $(@D); \
rm -f $@-testsum $@-testlog; \
+ run_check=yes; \
+ MULTILIBDIR="$(MULTILIBDIR)"; \
+ case "$$MULTILIBDIR" in /64|/x32) \
+ echo "$$RUNTESTFLAGS" | grep -q "$${MULTILIBDIR#/*}" || run_check=; \
+ esac; \
+ if test "$$run_check" = "yes"; then \
if test "$(use_dejagnu)" = "yes"; then \
$(SHELL) $(srcdir)/testsuite/gotest --dejagnu=yes --basedir=$(srcdir) --srcdir=$(srcdir)/go/$(@D) --pkgpath="$(@D)" --pkgfiles="$(go_$(subst /,_,$(@D))_files)" --testname="$(@D)" --goarch="$(GOARCH)" $(GOTESTFLAGS); \
else \
@@ -1822,6 +1828,7 @@
echo "FAIL: $(@D)" > $@-testsum; \
exit 1; \
fi; \
+ fi; \
fi
# Build all packages before checking any.
--- a/src/libgo/Makefile.in
+++ b/src/libgo/Makefile.in
@@ -1964,6 +1964,12 @@
export LD_LIBRARY_PATH; \
$(MKDIR_P) $(@D); \
rm -f $@-testsum $@-testlog; \
+ run_check=yes; \
+ MULTILIBDIR="$(MULTILIBDIR)"; \
+ case "$$MULTILIBDIR" in /64|/x32) \
+ echo "$$RUNTESTFLAGS" | grep -q "$${MULTILIBDIR#/*}" || run_check=; \
+ esac; \
+ if test "$$run_check" = "yes"; then \
if test "$(use_dejagnu)" = "yes"; then \
$(SHELL) $(srcdir)/testsuite/gotest --dejagnu=yes --basedir=$(srcdir) --srcdir=$(srcdir)/go/$(@D) --pkgpath="$(@D)" --pkgfiles="$(go_$(subst /,_,$(@D))_files)" --testname="$(@D)" --goarch="$(GOARCH)" $(GOTESTFLAGS); \
else \
@@ -1977,6 +1983,7 @@
echo "FAIL: $(@D)" > $@-testsum; \
exit 1; \
fi; \
+ fi; \
fi
|