view strip_fPIC.sh @ 688:c0522010bb6d

Date: Tue, 12 Aug 2003 14:26:19 +0200 (MEST) From: "Mattias Engdeg?rd" Subject: bug in SDL_GetRGB/GetRGBA There's an embarrassing bug in GetRGB/GetRGBA which apparently has been there for years. It incorrectly converts colours with < 8 bits/channel. It came to my attention today in #sdl. What it does now is (for each channel): rv = (pixel & fmt->Rmask) >> fmt->Rshift; *r = (rv << fmt->Rloss) + (rv >> (8 - fmt->Rloss)); which is wrong; the last line should be *r = (rv << fmt->Rloss) + (rv >> (8 - (fmt->Rloss << 1)));
author Sam Lantinga <slouken@libsdl.org>
date Tue, 12 Aug 2003 15:17:20 +0000
parents 48c34d68918e
children
line wrap: on
line source

#!/bin/sh
#
# libtool assumes that the compiler can handle the -fPIC flag
# This isn't always true (for example, nasm can't handle it)
command=""
while [ $# -gt 0 ]; do
    case "$1" in
        -?PIC)
            # Ignore -fPIC and -DPIC options
            ;;
        *)
            command="$command $1"
            ;;
    esac
    shift
done
echo $command
exec $command