[ELDK] [RFSB] problem with creating directories

Martin Krause Martin.Krause at tqs.de
Tue May 18 13:46:22 CEST 2010


OK, I found the Problem. If the 'SHELL' variable is not defined in
the Makefile, make uses 'bin/sh' as the default shell. And on my system
'bin/sh' is a symbolic link to 'bin/dash' (true for all ubuntu systems
since version 6.10). And the dash does not support {} brace expansion
for strings

I fixed this by setting SHELL to /bin/bash in the makefile:

diff --git a/Makefile b/Makefile
index eb69485..88de554 100644
--- a/Makefile
+++ b/Makefile
@@ -21,6 +21,7 @@
 # Just run 'make menuconfig', configure stuff, then run 'make'.
 # All hope abandon, ye who enter in!
 #############################################################
+SHELL             = /bin/bash
 TOPDIR		  := $(shell pwd)
 CONFIG_CONFIG_IN   = Config.in
 CONFIG_DEFCONFIG   = .defconfig

Regards,
Martin

Martin Krause wrote on :
> Hi Detlev,
> 
> when I use teh RFSB to create a ramdisk image, the resulting rootfs
> contains some "interesting" directories:
> 
> -sh-3.2# ls
> bb
> bin
> dev
> etc
> lib
> linuxrc
> lost+found
> sbin
> usr
> {bin,dev,etc,ftp,home,lib,proc,sbin,tmp}        <-
> {usr,usr                                        <-
> -sh-3.2#
> 
> It seems, that the Makefile does not call "mkdir_safe" for the
> directories /rootfs/bin, /rootfs/dev, ... separately, but calls
> it with "mkdir_safe rootfs/{bin,dev,etc,ftp,home,lib,proc,sbin,tmp}"
> directly. Do you have an idea, what could cause this? Is my make
> to old? I use GNU Make 3.81.
> 
> Regards,
> Martin
> 
> Entwicklung
> Tel. +49 8153 9308-157, Fax +49 8153 9308-7157
> mailto:martin.krause at tqs.de
> 
> TQ-Systems GmbH
> Mühlstraße 2, Gut Delling, D-82229 Seefeld
> Amtsgericht München, HRB 105 018, UST-IdNr. DE 811 607 913
> Sitz der Gesellschaft: Seefeld
> Geschäftsführer: Dipl.-Ing. (FH) Detlef Schneider, Dipl.-Ing. (FH)
> Rüdiger Stahl http://www.tq-group.com/
> _______________________________________________
> eldk mailing list
> eldk at lists.denx.de
> http://lists.denx.de/mailman/listinfo/eldk


More information about the eldk mailing list