mirror of https://github.com/OpenTTD/OpenTTD
(svn r7959) [Configure] -Fix: OS2-gcc needs to get stripping via gcc, because it needs to be feed to emxbind at link-time.
emxbind changes 'emx a.out' format to 'LX for OS/2 (MS-DOS)'. After this, all gcc and binutils tools for emx can no longer read the binary. Therefor emxbind needs to do the stripping while converting it. Logic, aint it? :)release/0.6
parent
98f0c0f428
commit
c6da059f7b
|
@ -449,6 +449,10 @@ check_params() {
|
||||||
strip_arg="--strip-all --strip-unneeded --remove-section .comment"
|
strip_arg="--strip-all --strip-unneeded --remove-section .comment"
|
||||||
elif [ "$os" = "OSX" ]; then
|
elif [ "$os" = "OSX" ]; then
|
||||||
strip_arg=""
|
strip_arg=""
|
||||||
|
elif [ "$os" = "OS2" ]; then
|
||||||
|
strip_arg=""
|
||||||
|
# OS2 uses strip via gcc, because it needs to be feed to emxbind
|
||||||
|
LDFLAGS="$LDFLAGS -s"
|
||||||
else
|
else
|
||||||
strip_arg="-s"
|
strip_arg="-s"
|
||||||
fi
|
fi
|
||||||
|
@ -988,7 +992,10 @@ check_windres() {
|
||||||
}
|
}
|
||||||
|
|
||||||
check_strip() {
|
check_strip() {
|
||||||
if [ "$os" = "OSX" ]; then
|
if [ "$os" = "OS2" ]; then
|
||||||
|
# OS2 via gcc is a bit weird.. stripping HAS to be done via emxbind, which is via gcc directly
|
||||||
|
echo "checking for host strip... using gcc -s option"
|
||||||
|
elif [ "$os" = "OSX" ]; then
|
||||||
# Most targets have -V in strip, to see if they exists... OSX doesn't.. so execute something
|
# Most targets have -V in strip, to see if they exists... OSX doesn't.. so execute something
|
||||||
echo "int main(int argc, char *argv[]) { }" > strip.test.c
|
echo "int main(int argc, char *argv[]) { }" > strip.test.c
|
||||||
$cc_host strip.test.c -o strip.test
|
$cc_host strip.test.c -o strip.test
|
||||||
|
|
Loading…
Reference in New Issue