]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - mkconfig
s3c64xx: move s3c64xx header files to asm-arm/arch-s3c64xx
[karo-tx-uboot.git] / mkconfig
index b0bbbd1e7f41fb0ecdf6918b306680d91b647994..bdc9d91d17198cd3e2d5252a8bdae902ff14bff2 100755 (executable)
--- a/mkconfig
+++ b/mkconfig
 
 APPEND=no      # Default: Create new config file
 BOARD_NAME=""  # Name to print in make output
+TARGETS=""
 
 while [ $# -gt 0 ] ; do
        case "$1" in
        --) shift ; break ;;
        -a) shift ; APPEND=yes ;;
        -n) shift ; BOARD_NAME="${1%%_config}" ; shift ;;
+       -t) shift ; TARGETS="`echo $1 | sed 's:_: :g'` ${TARGETS}" ; shift ;;
        *)  break ;;
        esac
 done
@@ -72,6 +74,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
 #
@@ -82,6 +91,13 @@ else
        > config.h              # Create new config file
 fi
 echo "/* Automatically generated - do not edit */" >>config.h
+
+for i in ${TARGETS} ; do
+       echo "#define CONFIG_MK_${i} 1" >>config.h ;
+done
+
+echo "#define CONFIG_BOARDDIR board/$BOARDDIR" >>config.h
+
 echo "#include <configs/$1.h>" >>config.h
 echo "#include <asm/config.h>" >>config.h