Created
March 1, 2015 15:39
-
-
Save prologic/e87b93ed6333e2acb769 to your computer and use it in GitHub Desktop.
created by github.com/tr3buchet/gister
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
cd work/busybox | |
# Change to the first directory ls finds, e.g. 'busybox-1.23.1' | |
cd $(ls -d *) | |
# Setup Cross Comiler | |
export PATH=$HOME/x-tools/x86_64-unknown-linux-uclibc/bin:$PATH | |
# Remove previously generated artefacts | |
make ARCH=x86_64 CROSS_COMPILE=x86_64-unknown-linux-uclibc- clean | |
# Create a default configuration file | |
make ARCH=x86_64 CROSS_COMPILE=x86_64-unknown-linux-uclibc- defconfig | |
# Change the configuration, so that busybox is statically compiled | |
# You could do this manually with 'make menuconfig' | |
sed -i "s/.*CONFIG_STATIC.*/CONFIG_STATIC=y/" .config | |
# Compile busybox | |
make | |
# Create the symlinks for busybox | |
# It uses the file 'busybox.links' for this | |
make install | |
cd ../../.. | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment