add support for building psp toolchain
[rofl0r-mmix-cross.git] / configs / psp464
blob8e016ec22d943f58798d8aa8396820b975138d43
1 GCC_VERSION=4.6.4 
2 NEWLIB_VERSION=1.20.0
3 NEWLIB_VERSION=4.1.0
4 LANG_CXX=no
5 BINUTILS_URL=http://mirrors.kernel.org/sourceware/binutils/releases/binutils-2.23.2.tar.bz2
6 # http://mirrors.kernel.org/sourceware/binutils/snapshots/binutils-2.24.90.tar.bz2
7 ARCH=mips
8 TRIPLE=mipsallegrexel-psp-elf
9 GCC_CONFFLAGS=--with-float=hard
11 ENABLE_POST_BUILD_HOOK=1
13 post_build_hook() {
14 cd $CC_BASE_PREFIX/$TRIPLE/bin
15 for x in mips* ; do
16  shn=$(printf "%s\n" "$x" | awk '{split($0, a, "-"); print(a[4]); }')
17  test "$shn" = gcc || ln -sf "$x" psp-"$shn"
18 done
19 cat << EOF1 > psp-gcc
20 #!/bin/sh
21 DIR=\$(dirname \$(readlink -f "\$0"))
22 "\$DIR"/mipsallegrexel-psp-elf-gcc "\$@" -lgcc -lm \
23 -Wl,--start-group -lcglue -lc -Wl,--end-group \
24 -lpsputility -lpsprtc -lpspnet_inet -lpspnet_resolver -lpspmodinfo \
25 -lpspuser -lpspkernel -lgcc
26 EOF1
27 chmod +x psp-gcc
29 cat << EOF
30 *****************************************************************************
31 toolchain installed, now you gotta fetch https://github.com/pspdev/pspsdk and
32 run:
33 git checkout cc887d731f635e06fba85118eb5c7ee87746cbc8 # known good version
34 export PATH="\$PATH:$CC_BASE_PREFIX/$TRIPLE/bin"
35 ./configure --with-pspdev=$CC_BASE_PREFIX/$TRIPLE
36 make && make install-data install
37 *****************************************************************************
38 EOF