Index: gcc/ada/gcc-interface/Make-lang.in
===================================================================
--- gcc/ada/gcc-interface/Make-lang.in.orig	2011-11-03 16:26:46.000000000 +0100
+++ gcc/ada/gcc-interface/Make-lang.in	2011-11-03 17:08:13.000000000 +0100
@@ -758,6 +758,21 @@ doc/gnat-style.pdf: ada/gnat-style.texi
 # likewise for gnatf, gnatchop, and gnatlink, gnatkr, gnatmake, gnat,
 # gnatprep, gnatls, gnatxref, gnatfind, gnatname, gnatclean,
 # gnatsym
+GNATBIND_INSTALL_NAME := $(shell echo gnatbind|sed '$(program_transform_name)')
+GNATCHOP_INSTALL_NAME := $(shell echo gnatchop|sed '$(program_transform_name)')
+GNAT_INSTALL_NAME := $(shell echo gnat|sed '$(program_transform_name)')
+GNATKR_INSTALL_NAME := $(shell echo gnatkr|sed '$(program_transform_name)')
+GNATLINK_INSTALL_NAME := $(shell echo gnatlink|sed '$(program_transform_name)')
+GNATLS_INSTALL_NAME := $(shell echo gnatls|sed '$(program_transform_name)')
+GNATMAKE_INSTALL_NAME := $(shell echo gnatmake|sed '$(program_transform_name)')
+GNATNAME_INSTALL_NAME := $(shell echo gnatname|sed '$(program_transform_name)')
+GNATPREP_INSTALL_NAME := $(shell echo gnatprep|sed '$(program_transform_name)')
+GNATXREF_INSTALL_NAME := $(shell echo gnatxref|sed '$(program_transform_name)')
+GNATFIND_INSTALL_NAME := $(shell echo gnatfind|sed '$(program_transform_name)')
+GNATCLEAN_INSTALL_NAME := $(shell echo gnatclean|sed '$(program_transform_name)')
+GNATSYM_INSTALL_NAME := $(shell echo gnatsym|sed '$(program_transform_name)')
+GNATDLL_INSTALL_NAME := $(shell echo gnatdll|sed '$(program_transform_name)')
+VXADDR2LINE_INSTALL_NAME := $(shell echo vxaddr2line|sed '$(program_transform_name)')
 ada.install-common:
 	$(MKDIR) $(DESTDIR)$(bindir)
 	-if [ -f gnat1$(exeext) ] ; \
@@ -771,8 +786,8 @@ ada.install-common:
 	      $(INSTALL_PROGRAM) gnatbind-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnatbind$(exeext); \
 	    fi; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatbind$(exeext); \
-	    $(INSTALL_PROGRAM) gnatbind$(exeext) $(DESTDIR)$(bindir)/gnatbind$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATBIND_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatbind$(exeext) $(DESTDIR)$(bindir)/$(GNATBIND_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -786,8 +801,8 @@ ada.install-common:
 	       $(INSTALL_PROGRAM) gnatchop-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnatchop$(exeext); \
 	    fi ; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatchop$(exeext); \
-	    $(INSTALL_PROGRAM) gnatchop$(exeext) $(DESTDIR)$(bindir)/gnatchop$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATCHOP_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatchop$(exeext) $(DESTDIR)$(bindir)/$(GNATCHOP_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -801,8 +816,8 @@ ada.install-common:
 	       $(INSTALL_PROGRAM) gnat-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnat$(exeext); \
 	    fi; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnat$(exeext); \
-	    $(INSTALL_PROGRAM) gnat$(exeext) $(DESTDIR)$(bindir)/gnat$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNAT_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnat$(exeext) $(DESTDIR)$(bindir)/$(GNAT_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -816,8 +831,8 @@ ada.install-common:
 	       $(INSTALL_PROGRAM) gnatkr-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnatkr$(exeext); \
 	    fi; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatkr$(exeext); \
-	    $(INSTALL_PROGRAM) gnatkr$(exeext) $(DESTDIR)$(bindir)/gnatkr$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATKR_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatkr$(exeext) $(DESTDIR)$(bindir)/$(GNATKR_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -831,8 +846,8 @@ ada.install-common:
 	       $(INSTALL_PROGRAM) gnatlink-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnatlink$(exeext); \
 	    fi; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatlink$(exeext); \
-	    $(INSTALL_PROGRAM) gnatlink$(exeext) $(DESTDIR)$(bindir)/gnatlink$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATLINK_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatlink$(exeext) $(DESTDIR)$(bindir)/$(GNATLINK_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -846,8 +861,8 @@ ada.install-common:
 	       $(INSTALL_PROGRAM) gnatls-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnatls$(exeext); \
 	    fi; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatls$(exeext); \
-	    $(INSTALL_PROGRAM) gnatls$(exeext) $(DESTDIR)$(bindir)/gnatls$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATLS_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatls$(exeext) $(DESTDIR)$(bindir)/$(GNATLS_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -861,8 +876,8 @@ ada.install-common:
 	       $(INSTALL_PROGRAM) gnatmake-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnatmake$(exeext); \
 	    fi; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatmake$(exeext); \
-	    $(INSTALL_PROGRAM) gnatmake$(exeext) $(DESTDIR)$(bindir)/gnatmake$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATMAKE_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatmake$(exeext) $(DESTDIR)$(bindir)/$(GNATMAKE_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -872,8 +887,8 @@ ada.install-common:
 	    $(RM) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatname$(exeext); \
 	    $(INSTALL_PROGRAM) gnatname-cross$(exeext) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatname$(exeext); \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatname$(exeext); \
-	    $(INSTALL_PROGRAM) gnatname$(exeext) $(DESTDIR)$(bindir)/gnatname$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATNAME_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatname$(exeext) $(DESTDIR)$(bindir)/$(GNATNAME_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -887,8 +902,8 @@ ada.install-common:
 	       $(INSTALL_PROGRAM) gnatprep-cross$(exeext) $(DESTDIR)$(tooldir)/bin/gnatprep$(exeext); \
 	    fi; \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatprep$(exeext); \
-	    $(INSTALL_PROGRAM) gnatprep$(exeext) $(DESTDIR)$(bindir)/gnatprep$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATPREP_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatprep$(exeext) $(DESTDIR)$(bindir)/$(GNATPREP_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -898,8 +913,8 @@ ada.install-common:
 	    $(RM) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatxref$(exeext); \
 	    $(INSTALL_PROGRAM) gnatxref-cross$(exeext) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatxref$(exeext); \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatxref$(exeext); \
-	    $(INSTALL_PROGRAM) gnatxref$(exeext) $(DESTDIR)$(bindir)/gnatxref$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATXREF_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatxref$(exeext) $(DESTDIR)$(bindir)/$(GNATXREF_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -909,8 +924,8 @@ ada.install-common:
 	    $(RM) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatfind$(exeext); \
 	    $(INSTALL_PROGRAM) gnatfind-cross$(exeext) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatfind$(exeext); \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatfind$(exeext); \
-	    $(INSTALL_PROGRAM) gnatfind$(exeext) $(DESTDIR)$(bindir)/gnatfind$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATFIND_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatfind$(exeext) $(DESTDIR)$(bindir)/$(GNATFIND_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 	-if [ -f gnat1$(exeext) ] ; \
@@ -920,8 +935,8 @@ ada.install-common:
 	    $(RM) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatclean$(exeext); \
 	    $(INSTALL_PROGRAM) gnatclean-cross$(exeext) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatclean$(exeext); \
 	  else \
-	    $(RM) $(DESTDIR)$(bindir)/gnatclean$(exeext); \
-	    $(INSTALL_PROGRAM) gnatclean$(exeext) $(DESTDIR)$(bindir)/gnatclean$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATCLEAN_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatclean$(exeext) $(DESTDIR)$(bindir)/$(GNATCLEAN_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 #
@@ -935,7 +950,7 @@ ada.install-common:
 	    $(INSTALL_PROGRAM) gnatsym-cross$(exeext) $(DESTDIR)$(bindir)/$(target_noncanonical)-gnatsym$(exeext); \
 	  else \
 	    $(RM) $(DESTDIR)$(bindir)/gnatsym$(exeext); \
-	    $(INSTALL_PROGRAM) gnatsym$(exeext) $(DESTDIR)$(bindir)/gnatsym$(exeext); \
+	    $(INSTALL_PROGRAM) gnatsym$(exeext) $(DESTDIR)$(bindir)/$(GNATSYM_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 #
@@ -943,8 +958,8 @@ ada.install-common:
 #
 	-if [ -f gnat1$(exeext) ] ; \
 	then \
-	    $(RM) $(DESTDIR)$(bindir)/gnatdll$(exeext); \
-	    $(INSTALL_PROGRAM) gnatdll$(exeext) $(DESTDIR)$(bindir)/gnatdll$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(GNATDLL_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) gnatdll$(exeext) $(DESTDIR)$(bindir)/$(GNATDLL_INSTALL_NAME)$(exeext); \
 	fi
 #
 # vxaddr2line is only used for cross ports (it calls the underlying cross
@@ -954,8 +969,8 @@ ada.install-common:
 	then \
 	  if [ -f vxaddr2line$(exeext) ] ; \
 	  then \
-	    $(RM) $(DESTDIR)$(bindir)/vxaddr2line$(exeext); \
-	    $(INSTALL_PROGRAM) vxaddr2line$(exeext) $(DESTDIR)$(bindir)/vxaddr2line$(exeext); \
+	    $(RM) $(DESTDIR)$(bindir)/$(VXADDR2LINE_INSTALL_NAME)$(exeext); \
+	    $(INSTALL_PROGRAM) vxaddr2line$(exeext) $(DESTDIR)$(bindir)/$(VXADDR2LINE_INSTALL_NAME)$(exeext); \
 	  fi ; \
 	fi
 
@@ -1019,8 +1034,6 @@ ada.uninstall:
 	-$(RM) $(DESTDIR)$(tooldir)/bin/gnatxref$(exeext)
 	-$(RM) $(DESTDIR)$(tooldir)/bin/gnatclean$(exeext)
 	-$(RM) $(DESTDIR)$(tooldir)/bin/gnatsym$(exeext)
-# Gnatchop is only used on VMS
-	-$(RM) $(DESTDIR)$(bindir)/gnatchop$(exeext)
 
 # Clean hooks:
 # A lot of the ancillary files are deleted by the main makefile.
