crossmenuconfig.sh 1.3 KB

123456789101112131415161718192021222324252627282930313233
  1. #!/bin/sh -xe
  2. #Runs Make menuconfig with the proper enviroment vars for cross compiling arm
  3. #Grabs the file named config in resources/BuildResources directory, and updates it
  4. # This file is part of PrawnOS (http://www.prawnos.com)
  5. # Copyright (c) 2018 Hal Emmerich <hal@halemmerich.com>
  6. # PrawnOS is free software: you can redistribute it and/or modify
  7. # it under the terms of the GNU General Public License version 2
  8. # as published by the Free Software Foundation.
  9. # PrawnOS is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. # GNU General Public License for more details.
  13. # You should have received a copy of the GNU General Public License
  14. # along with PrawnOS. If not, see <https://www.gnu.org/licenses/>.
  15. KVER=4.17.2
  16. ROOT_DIR=`pwd`
  17. RESOURCES=$ROOT_DIR/resources/BuildResources
  18. [ ! -d build ] && mkdir build
  19. cd build
  20. [ ! -f linux-libre-$KVER-gnu.tar.lz ] && wget https://www.linux-libre.fsfla.org/pub/linux-libre/releases/$KVER-gnu/linux-libre-$KVER-gnu.tar.lz
  21. [ ! -d linux-$KVER ] && tar --lzip -xvf linux-libre-$KVER-gnu.tar.lz
  22. cd linux-$KVER
  23. cp $RESOURCES/config .config
  24. make menuconfig ARCH=arm CROSS_COMPILE=arm-none-eabi- .config
  25. cp .config $RESOURCES/config