Prepare OSX Leopard system to build OpenWRT

# Copyright: Djarvur group, 2009, info@djarvir.net
# License: FreeBSD
#
# Tested on Snow Leopard 10.6.2

# Case-sensitive FS is required to build OpenWRT
# But it is very unlikely your OSX partition formatted as such
# So let's create a case sensitive storage for OpenWRT build box
hdiutil create -size 10g -fs HFSX -volname buildOpenWRT ~/buildOpenWRT.dmg &&
hdiutil attach ~/buildOpenWRT.dmg
#
# At this point you should have a storage mounted on
# /Volumes/buildOpenWRT
# Please use this path instead of ~/new/openwrt

# Now install Darwin ports

# And all the packages required
# Usefull info: http://laufer.cs.luc.edu/2009/09/prerequisites-for-building-openwrt-sdk.html

sudo port -v install e2fsprogs gcc45 binutils gpatch bzip2 flex bison gmake \
                     gettext pkgconfig unzip libzip wget coreutils gawk \
                     findutils getopt gnutar md5sha1sum

# Some OSX tools are incompatible with OpenWRT build system
# so they must be replaced
# Check you have /opt/loca/bin in your PATH before the /usr/bin
sudo ln -s gawk     /opt/local/bin/awk
sudo ln -s ginstall /opt/local/bin/install
hash -r

Comments