From cff00a203897a28629486e87662c0444aa9549d7 Mon Sep 17 00:00:00 2001
From: Michael Frysinger <vapier@gentoo.org>
Date: Sat, 24 Mar 2012 03:38:28 +0000
Subject: [PATCH] libgloss: cris: respect DESTDIR when installing

---
 libgloss/ChangeLog        | 4 ++++
 libgloss/cris/Makefile.in | 2 +-
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/libgloss/ChangeLog b/libgloss/ChangeLog
index b4a386fc8..d668c1d37 100644
--- a/libgloss/ChangeLog
+++ b/libgloss/ChangeLog
@@ -1,3 +1,7 @@
+2012-03-23  Mike Frysinger  <vapier@gentoo.org>
+
+	* cris/Makefile.in (install-lin): Add $(DESTDIR) before ${tooldir}.
+
 2012-03-12  Mike Frysinger  <vapier@gentoo.org>
 
 	* libnosys/Makefile.in (NEWLIB_CFLAGS, NEWLIB_LDFLAGS,
diff --git a/libgloss/cris/Makefile.in b/libgloss/cris/Makefile.in
index 0ec0678d6..a5cd9e05d 100644
--- a/libgloss/cris/Makefile.in
+++ b/libgloss/cris/Makefile.in
@@ -228,7 +228,7 @@ install-lin:
           *) \
 	    set -e; \
 	    for x in ${LIN_BSP} ${LIN_SCRIPTS} ${LIN_EXTRA}; do \
-	      ${INSTALL_DATA} $$x ${tooldir}/lib${MULTISUBDIR}/$$x; \
+	      ${INSTALL_DATA} $$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; \
 	    done;; \
 	esac