]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - mkconfig
SPEAr : emi controller initialization for CFI driver support
[karo-tx-uboot.git] / mkconfig
index 10755107900cf190e664596be862d196cd0a4f30..0f7f13e3a4d836d6bb8a1ab18b34e63a4125cc2c 100755 (executable)
--- a/mkconfig
+++ b/mkconfig
@@ -79,6 +79,13 @@ echo "BOARD  = $4" >> config.mk
 
 [ "$6" ] && [ "$6" != "NULL" ] && echo "SOC    = $6" >> config.mk
 
+# Assign board directory to BOARDIR variable
+if [ -z "$5" -o "$5" = "NULL" ] ; then
+    BOARDDIR=$4
+else
+    BOARDDIR=$5/$4
+fi
+
 #
 # Create board specific header file
 #
@@ -94,7 +101,11 @@ for i in ${TARGETS} ; do
        echo "#define CONFIG_MK_${i} 1" >>config.h ;
 done
 
-echo "#include <configs/$1.h>" >>config.h
-echo "#include <asm/config.h>" >>config.h
+cat << EOF >> config.h
+#define CONFIG_BOARDDIR board/$BOARDDIR
+#include <config_defaults.h>
+#include <configs/$1.h>
+#include <asm/config.h>
+EOF
 
 exit 0