1999-09-13 14:30:21 +04:00
|
|
|
#! /bin/sh
|
|
|
|
|
|
|
|
# just helping for cross compilation.
|
|
|
|
|
2001-01-04 10:09:47 +03:00
|
|
|
MACHINE=evbsh3
|
2001-01-04 10:50:23 +03:00
|
|
|
MACHINE_ARCH=sh3el
|
2001-02-26 11:24:20 +03:00
|
|
|
MACHINE_CPU=sh3
|
1999-09-13 14:30:21 +04:00
|
|
|
# just in case you forgot to specify this when you built gcc...
|
2001-01-04 11:39:53 +03:00
|
|
|
CFLAGS="-D__NetBSD__"
|
1999-09-13 14:30:21 +04:00
|
|
|
export MACHINE MACHINE_ARCH CFLAGS
|
2001-02-27 17:05:53 +03:00
|
|
|
# modify following TARGET name to meet your environment
|
|
|
|
TARGET=shel-unknown-netbsdcoff
|
2001-02-26 11:46:15 +03:00
|
|
|
|
|
|
|
# XXX following definition is absolutely incorrect.
|
|
|
|
# Our cpp is not /usr/libexec/cpp but /usr/bin/cpp.
|
|
|
|
# True solution is:
|
|
|
|
# 1) copy /usr/bin/cpp into /usr/local/bin/shel-*-*-cpp
|
|
|
|
# 2) Edit CPP in shel-*-*-cpp correctly
|
|
|
|
# (e.g. "CPP=`$CC -print-prog-name=cpp`").
|
|
|
|
# 3) Edit STDINCDIR in shel-*-*-cpp correctly
|
|
|
|
# (e.g. STDINCDIR=/usr/local/shel-unknown-netbsdcoff/include)
|
|
|
|
|
|
|
|
# BROKEN
|
2001-01-09 05:31:37 +03:00
|
|
|
CPP=`$TARGET-gcc -print-prog-name=cpp`
|
1999-09-13 14:30:21 +04:00
|
|
|
|
2001-02-26 11:46:15 +03:00
|
|
|
# EXAMPLE
|
|
|
|
#CPP=/usr/local/bin/shel-unknown-netbsdcoff-cpp
|
|
|
|
#CPP=/usr/local/bin/shel-unknown-netbsdelf-cpp
|
|
|
|
|
2001-01-17 09:03:54 +03:00
|
|
|
make AR=$TARGET-ar AS="$TARGET-as -little" CC=$TARGET-gcc LD=$TARGET-ld NM=$TARGET-nm \
|
2001-01-04 10:09:47 +03:00
|
|
|
RANLIB=$TARGET-ranlib SIZE=$TARGET-size \
|
|
|
|
STRIP=$TARGET-strip OBJCOPY=$TARGET-objcopy \
|
2001-01-09 05:31:37 +03:00
|
|
|
CXX=$TARGET-c++ CPP=$CPP $*
|