split_by_variant.sh 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. #!/bin/sh
  2. # ---------------------------------------------------------
  3. # Set the core module defines according to Core Module
  4. # ---------------------------------------------------------
  5. CC=$(CROSS_COMPILE)gcc
  6. config="versatilepb_config"
  7. if [ "$2" == "" ]
  8. then
  9. echo "$0:: No preprocessor parameter - using $(CROSS_COMPILE)gcc"
  10. else
  11. CC=$2
  12. fi
  13. # ---------------------------------------------------------
  14. # Set up the Versatile type define
  15. # ---------------------------------------------------------
  16. if [ "$1" == "" ]
  17. then
  18. echo "$0:: No parameters - using $(CROSS_COMPILE)gcc versatilepb_config"
  19. else
  20. case "$config" in
  21. versatilepb_config | \
  22. versatile_config)
  23. echo "#define CONFIG_ARCH_VERSATILE_PB" > ./include/config.h
  24. ;;
  25. versatileab_config)
  26. echo "#define CONFIG_ARCH_VERSATILE_AB" > ./include/config.h
  27. ;;
  28. *)
  29. echo "$0:: Unrecognised config - using versatilepb_config"
  30. ;;
  31. esac
  32. fi
  33. # ---------------------------------------------------------
  34. # Complete the configuration
  35. # ---------------------------------------------------------
  36. ./mkconfig -a versatile arm arm926ejs versatile