Index: c/src/lib/libbsp/arm/gba/make/custom/gba.cfg
===================================================================
--- c/src/lib/libbsp/arm/gba/make/custom/gba.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/arm/gba/make/custom/gba.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -21,5 +21,5 @@
 	$(OBJCOPY) -O binary --remove-section=.comment \
 	    --remove-section=.note --strip-unneeded \
-	    $(basename $@).exe $(basename $@)$(DOWNEXT)
+	    $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
 endef
Index: c/src/lib/libbsp/arm/gp32/make/custom/gp32.cfg
===================================================================
--- c/src/lib/libbsp/arm/gp32/make/custom/gp32.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/arm/gp32/make/custom/gp32.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,5 +17,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
 endef
Index: c/src/lib/libbsp/arm/lm3s69xx/make/custom/lm3s69xx.inc
===================================================================
--- c/src/lib/libbsp/arm/lm3s69xx/make/custom/lm3s69xx.inc	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/arm/lm3s69xx/make/custom/lm3s69xx.inc	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -13,4 +13,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@).ralf
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/arm/nds/make/custom/nds.cfg
===================================================================
--- c/src/lib/libbsp/arm/nds/make/custom/nds.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/arm/nds/make/custom/nds.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -29,5 +29,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@).bin
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@).bin
 	$(NDSTOOL) -c $(basename $@).nds -9 $(basename $@).bin \
 	    -7 $(COPROC_ELF_PATH)/coproc.bin
Index: c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.cfg
===================================================================
--- c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/arm/raspberrypi/make/custom/raspberrypi.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,6 +17,6 @@
 define bsp-post-link
     $(OBJCOPY) -O binary --strip-all \
-        $(basename $@).exe $(basename $@)$(DOWNEXT)
-    $(SIZE) $(basename $@).exe
+        $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
+    $(SIZE) $(basename $@)$(EXEEXT)
 endef
 
Index: c/src/lib/libbsp/i386/pc386/make/custom/pc386.cfg
===================================================================
--- c/src/lib/libbsp/i386/pc386/make/custom/pc386.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/i386/pc386/make/custom/pc386.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -47,5 +47,5 @@
 	    --remove-section=.comment \
 	    --remove-section=.note \
-	    --strip-unneeded $(basename $@).exe $(basename $@).nxe
+	    --strip-unneeded $(basename $@)$(EXEEXT) $(basename $@).nxe
 	$(OBJCOPY) -O binary $(basename $@).nxe $(basename $@).bin
 	$(PROJECT_TOOLS)/bin2boot -v $(basename $@)$(DOWNEXT) $(HEADERADDR)\
Index: c/src/lib/libbsp/lm32/lm32_evr/make/custom/lm32_evr.cfg
===================================================================
--- c/src/lib/libbsp/lm32/lm32_evr/make/custom/lm32_evr.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/lm32/lm32_evr/make/custom/lm32_evr.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -22,5 +22,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O binary --strip-all $(basename $@).exe \
+	$(OBJCOPY) -O binary --strip-all $(basename $@)$(EXEEXT) \
 	    -R entry -R exceptions $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
Index: c/src/lib/libbsp/lm32/milkymist/make/custom/milkymist.cfg
===================================================================
--- c/src/lib/libbsp/lm32/milkymist/make/custom/milkymist.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/lm32/milkymist/make/custom/milkymist.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -22,5 +22,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O binary --strip-all $(basename $@).exe \
+	$(OBJCOPY) -O binary --strip-all $(basename $@)$(EXEEXT) \
 	    -R entry -R exceptions $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
Index: c/src/lib/libbsp/m68k/av5282/make/custom/av5282.cfg
===================================================================
--- c/src/lib/libbsp/m68k/av5282/make/custom/av5282.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/av5282/make/custom/av5282.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -23,4 +23,4 @@
 	$(default-bsp-post-link)
 	$(OBJCOPY) -O binary --strip-all \
-	    $(basename $@).exe $(basename $@)$(DOWNEXT)
+	    $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/m68k/genmcf548x/make/custom/genmcf548x.inc
===================================================================
--- c/src/lib/libbsp/m68k/genmcf548x/make/custom/genmcf548x.inc	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/genmcf548x/make/custom/genmcf548x.inc	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -16,5 +16,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O binary --strip-all $(basename $@).exe \
+	$(OBJCOPY) -O binary --strip-all $(basename $@)$(EXEEXT) \
 	    $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
Index: c/src/lib/libbsp/m68k/idp/make/custom/idp.cfg
===================================================================
--- c/src/lib/libbsp/m68k/idp/make/custom/idp.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/idp/make/custom/idp.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,5 +17,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@).srec
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@).srec
 	sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
 	    $(PACKHEX) > $(basename $@)$(DOWNEXT)
Index: c/src/lib/libbsp/m68k/mcf52235/make/custom/mcf52235.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mcf52235/make/custom/mcf52235.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mcf52235/make/custom/mcf52235.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -19,5 +19,5 @@
 define bsp-post-link
 	$(OBJCOPY) -O binary --strip-all \
-	    $(basename $@).exe $(basename $@)$(DOWNEXT)
-	$(SIZE) $(basename $@).exe
+	    $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
+	$(SIZE) $(basename $@)$(EXEEXT)
 endef
Index: c/src/lib/libbsp/m68k/mcf5225x/make/custom/mcf5225x.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mcf5225x/make/custom/mcf5225x.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mcf5225x/make/custom/mcf5225x.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -23,5 +23,5 @@
 define bsp-post-link
 	$(OBJCOPY) -O binary --strip-all \
-	    $(basename $@).exe $(basename $@)$(DOWNEXT)
-	$(SIZE) $(basename $@).exe
+	    $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
+	$(SIZE) $(basename $@)$(EXEEXT)
 endef
Index: c/src/lib/libbsp/m68k/mcf5235/make/custom/mcf5235.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mcf5235/make/custom/mcf5235.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mcf5235/make/custom/mcf5235.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -23,5 +23,5 @@
 define bsp-post-link
 	$(OBJCOPY) -O binary --strip-all \
-	    $(basename $@).exe $(basename $@)$(DOWNEXT)
-	$(SIZE) $(basename $@).exe
+	    $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
+	$(SIZE) $(basename $@)$(EXEEXT)
 endef
Index: c/src/lib/libbsp/m68k/mcf5329/make/custom/mcf5329.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mcf5329/make/custom/mcf5329.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mcf5329/make/custom/mcf5329.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -21,5 +21,5 @@
 define bsp-post-link
 	$(OBJCOPY) -O binary --strip-all \
-	    $(basename $@).exe $(basename $@)$(DOWNEXT)
-	$(SIZE) $(basename $@).exe
+	    $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
+	$(SIZE) $(basename $@)$(EXEEXT)
 endef
Index: c/src/lib/libbsp/m68k/mrm332/make/custom/mrm332.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mrm332/make/custom/mrm332.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mrm332/make/custom/mrm332.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -32,6 +32,6 @@
 	        /\.text/ { base = $$4 ; size = $$3 };\
 	        END { printf("0x%x", h2d(base) + h2d(size)) }'\
-	       ` $(basename $@).pxe $(basename $@).exe
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@).srec
+	       ` $(basename $@).pxe $(basename $@)$(EXEEXT)
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@).srec
 	sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
 	    $(PACKHEX) > $(basename $@)$(DOWNEXT)
@@ -42,5 +42,5 @@
 else
 define bsp-post-link
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@).srec
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@).srec
 	sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
 	    $(PACKHEX) > $(basename $@)$(DOWNEXT)
Index: c/src/lib/libbsp/m68k/mvme136/make/custom/mvme136.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mvme136/make/custom/mvme136.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mvme136/make/custom/mvme136.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -18,5 +18,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@).srec
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@).srec
 	sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
 	    $(PACKHEX) > $(basename $@)$(DOWNEXT)
Index: c/src/lib/libbsp/m68k/mvme147/make/custom/mvme147.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mvme147/make/custom/mvme147.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mvme147/make/custom/mvme147.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -16,5 +16,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@).srec
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@).srec
 	sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
 	    $(PACKHEX) > $(basename $@)$(DOWNEXT)
Index: c/src/lib/libbsp/m68k/mvme147s/make/custom/mvme147s.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mvme147s/make/custom/mvme147s.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mvme147s/make/custom/mvme147s.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -16,5 +16,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@).srec
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@).srec
 	sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
 	    $(PACKHEX) > $(basename $@)$(DOWNEXT)
Index: c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -21,5 +21,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 
Index: c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -26,5 +26,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 
Index: c/src/lib/libbsp/m68k/mvme167/make/custom/mvme167.cfg
===================================================================
--- c/src/lib/libbsp/m68k/mvme167/make/custom/mvme167.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/mvme167/make/custom/mvme167.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -37,4 +37,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-    $(OBJCOPY) -O binary -R .comment -S $(basename $@).exe $(basename $@)$(DOWNEXT)
+    $(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/m68k/sim68000/make/custom/sim68000.cfg
===================================================================
--- c/src/lib/libbsp/m68k/sim68000/make/custom/sim68000.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/sim68000/make/custom/sim68000.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,4 +17,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/m68k/sim68000/make/custom/simcpu32.cfg
===================================================================
--- c/src/lib/libbsp/m68k/sim68000/make/custom/simcpu32.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/sim68000/make/custom/simcpu32.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,4 +17,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/m68k/uC5282/make/custom/uC5282.cfg
===================================================================
--- c/src/lib/libbsp/m68k/uC5282/make/custom/uC5282.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/m68k/uC5282/make/custom/uC5282.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,4 +17,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/nios2/nios2_iss/make/custom/nios2_iss.cfg
===================================================================
--- c/src/lib/libbsp/nios2/nios2_iss/make/custom/nios2_iss.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/nios2/nios2_iss/make/custom/nios2_iss.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -22,5 +22,5 @@
 
 define bsp-post-link
-	$(OBJCOPY) -O binary --strip-all $(basename $@).exe \
+	$(OBJCOPY) -O binary --strip-all $(basename $@)$(EXEEXT) \
 	    -R entry -R exceptions $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
Index: c/src/lib/libbsp/powerpc/haleakala/make/custom/haleakala.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/haleakala/make/custom/haleakala.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/haleakala/make/custom/haleakala.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -21,4 +21,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/powerpc/mbx8xx/make/custom/mbx8xx.inc
===================================================================
--- c/src/lib/libbsp/powerpc/mbx8xx/make/custom/mbx8xx.inc	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/mbx8xx/make/custom/mbx8xx.inc	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -50,5 +50,5 @@
 
 define bsp-post-link
-	cp $(basename $@).exe $(basename $@)$(DOWNEXT) 
+	cp $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT) 
 	$(STRIP) $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
Index: c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mcp750.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mcp750.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mcp750.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -18,9 +18,9 @@
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe rtems
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) rtems
  	gzip -vf9 rtems
  	$(LD) -o $(basename $@)$(DOWNEXT) \
 	    $ $(PROJECT_RELEASE)/lib/bootloader.o \
-	    --just-symbols=$(basename $@).exe \
+	    --just-symbols=$(basename $@)$(EXEEXT) \
  	    -b binary rtems.gz -T $(PROJECT_RELEASE)/lib/ppcboot.lds \
  	    -Map $(basename $@).map && chmod 755 $@
Index: c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mtx603e.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mtx603e.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mtx603e.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,9 +17,9 @@
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe rtems
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) rtems
  	gzip -vf9 rtems
  	$(LD) -o $(basename $@)$(DOWNEXT) \
 	   $(PROJECT_RELEASE)/lib/bootloader.o \
-	    --just-symbols=$(basename $@).exe \
+	    --just-symbols=$(basename $@)$(EXEEXT) \
  	    -b binary rtems.gz -T $(PROJECT_RELEASE)/lib/ppcboot.lds \
  	    -Map $(basename $@).map && chmod 755 $@
Index: c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mvme2100.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mvme2100.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mvme2100.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,9 +17,9 @@
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe rtems
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) rtems
  	gzip -vf9 rtems
  	$(LD) -o $(basename $@)$(DOWNEXT) \
 	    $(PROJECT_RELEASE)/lib/bootloader.o \
-	    --just-symbols=$(basename $@).exe \
+	    --just-symbols=$(basename $@)$(EXEEXT) \
  	    -b binary rtems.gz -T $(PROJECT_RELEASE)/lib/ppcboot.lds \
  	    -Map $(basename $@).map && chmod 755 $@
Index: c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mvme2307.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mvme2307.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/mvme2307.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -18,8 +18,8 @@
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe rtems
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) rtems
  	gzip -vf9 rtems
  	$(LD) -o $(basename $@)$(DOWNEXT)  $(PROJECT_RELEASE)/lib/bootloader.o \
-	    --just-symbols=$(basename $@).exe \
+	    --just-symbols=$(basename $@)$(EXEEXT) \
  	    -b binary rtems.gz -T $(PROJECT_RELEASE)/lib/ppcboot.lds \
  	    -Map $(basename $@).map && chmod 755 $@
Index: c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/qemuprep-altivec.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/qemuprep-altivec.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/qemuprep-altivec.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -19,13 +19,13 @@
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe $(basename $@)$(DOWNEXT)
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 else
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe rtems
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) rtems
  	gzip -vf9 rtems
  	$(LD) -o $(basename $@)$(DOWNEXT)  $(PROJECT_RELEASE)/lib/bootloader.o \
-	    --just-symbols=$(basename $@).exe \
+	    --just-symbols=$(basename $@)$(EXEEXT) \
  	    -b binary rtems.gz -T $(PROJECT_RELEASE)/lib/ppcboot.lds \
  	    -Map $(basename $@).map && chmod 755 $@
Index: c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/qemuprep.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/qemuprep.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/motorola_powerpc/make/custom/qemuprep.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -19,13 +19,13 @@
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe $(basename $@)$(DOWNEXT)
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 else
 define bsp-post-link
 	$(default-bsp-post-link)
- 	$(OBJCOPY) -O binary -R .comment -S $(basename $@).exe rtems
+ 	$(OBJCOPY) -O binary -R .comment -S $(basename $@)$(EXEEXT) rtems
  	gzip -vf9 rtems
  	$(LD) -o $(basename $@)$(DOWNEXT)  $(PROJECT_RELEASE)/lib/bootloader.o \
-	    --just-symbols=$(basename $@).exe \
+	    --just-symbols=$(basename $@)$(EXEEXT) \
  	    -b binary rtems.gz -T $(PROJECT_RELEASE)/lib/ppcboot.lds \
  	    -Map $(basename $@).map && chmod 755 $@
Index: c/src/lib/libbsp/powerpc/mvme3100/make/custom/mvme3100.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/mvme3100/make/custom/mvme3100.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/mvme3100/make/custom/mvme3100.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -18,4 +18,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/powerpc/mvme5500/make/custom/mvme5500.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/mvme5500/make/custom/mvme5500.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/mvme5500/make/custom/mvme5500.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -20,5 +20,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 
Index: c/src/lib/libbsp/powerpc/qemuppc/make/custom/qemuppc.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/qemuppc/make/custom/qemuppc.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/qemuppc/make/custom/qemuppc.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -17,4 +17,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O binary $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O binary $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/powerpc/score603e/make/custom/score603e.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/score603e/make/custom/score603e.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/score603e/make/custom/score603e.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -23,5 +23,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@).s1
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@).s1
 	sed -e 's/.$$//' $(basename $@).s1 | \
 	  $(PACKHEX) >$(basename $@)$(DOWNEXT)
Index: c/src/lib/libbsp/powerpc/ss555/make/custom/ss555.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/ss555/make/custom/ss555.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/ss555/make/custom/ss555.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -24,5 +24,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	cp $(basename $@).exe $(basename $@)$(DOWNEXT) 
+	cp $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT) 
 	$(STRIP) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/powerpc/tqm8xx/make/custom/tqm8xx.inc
===================================================================
--- c/src/lib/libbsp/powerpc/tqm8xx/make/custom/tqm8xx.inc	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/tqm8xx/make/custom/tqm8xx.inc	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -16,5 +16,5 @@
 
 define bsp-post-link
-	cp $(basename $@).exe $(basename $@)$(DOWNEXT) 
+	cp $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT) 
 	$(STRIP) $(basename $@)$(DOWNEXT)
 	$(default-bsp-post-link)
Index: c/src/lib/libbsp/powerpc/virtex/make/custom/virtex.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/virtex/make/custom/virtex.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/virtex/make/custom/virtex.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -20,4 +20,4 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
Index: c/src/lib/libbsp/powerpc/virtex4/make/custom/virtex4.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/virtex4/make/custom/virtex4.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/virtex4/make/custom/virtex4.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -15,5 +15,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 
Index: c/src/lib/libbsp/powerpc/virtex5/make/custom/virtex5.cfg
===================================================================
--- c/src/lib/libbsp/powerpc/virtex5/make/custom/virtex5.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/lib/libbsp/powerpc/virtex5/make/custom/virtex5.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -15,5 +15,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	$(OBJCOPY) -O srec $(basename $@).exe $(basename $@)$(DOWNEXT)
+	$(OBJCOPY) -O srec $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 
Index: c/src/make/leaf.cfg
===================================================================
--- c/src/make/leaf.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ c/src/make/leaf.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -9,9 +9,6 @@
 endif
 
-## what to do about $(EXEEXT) --> $(EXEEXT)
-##    -o $(basename $@)$(EXEEXT)             OR
-##    -o $(basename $@)$(EXEEXT)                  OR
-
-DOWNEXT=.ralf
+EXEEXT?=.exe
+DOWNEXT?=.ralf
 
 define bsp-link-c
Index: make/leaf.cfg
===================================================================
--- make/leaf.cfg	(revision 98bcf4ff6ed89b01f0adaa04e53bafc22468bad5)
+++ make/leaf.cfg	(revision efdda56546011b906f8332d25def5a929b14d0b7)
@@ -79,18 +79,15 @@
 endif
 
-## what to do about $(EXEEXT) --> $(EXEEXT)
-##    -o $(basename $@)$(EXEEXT)             OR
-##    -o $(basename $@)$(EXEEXT)                  OR
-
-DOWNEXT=.ralf
+EXEEXT?=.exe
+DOWNEXT?=.ralf
 
 define bsp-link-c
 	$(LINK.c) $(CPU_CFLAGS) $(AM_CFLAGS) $(AM_LDFLAGS) \
-	    -o $(basename $@).exe $(LINK_OBJS) $(LINK_LIBS)
+	    -o $(basename $@)$(EXEEXT) $(LINK_OBJS) $(LINK_LIBS)
 endef
 
 define bsp-link-cxx
 	$(LINK.cc) $(CPU_CFLAGS) $(AM_CFLAGS) $(AM_LDFLAGS) \
-	    -o $(basename $@).exe $(LINK_OBJS) $(LINK_LIBS)
+	    -o $(basename $@)$(EXEEXT) $(LINK_OBJS) $(LINK_LIBS)
 endef
 
@@ -103,5 +100,5 @@
 define bsp-post-link
 	$(default-bsp-post-link)
-	cp $(basename $@).exe $(basename $@)$(DOWNEXT)
+	cp $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
 endef
 endif
