Mercurial > projects > ldc
view find-alt-triple.sh @ 1054:a3d7288c4473
Future-proof the code to classify static array members of structs.
I made sure to create a merge conflict with the code attached to ticket #229
(which comments this code out due to changes in the DMD 'Type' type hierarchy)
so that if it gets committed as-is there will be a human looking at it.
author | Frits van Bommel <fvbommel wxs.nl> |
---|---|
date | Sun, 08 Mar 2009 01:26:30 +0100 |
parents | ca191c141cec |
children |
line wrap: on
line source
#!/bin/bash HOST_TARGET=$1 [ "$HOST_TARGET" = "" ] && exit 1 REST=`echo $HOST_TARGET | sed -e 's/[a-zA-Z0-9_]*\(\-.*\)/\1/'` X86=`echo $HOST_TARGET | sed -e 's/\(i[3-9]86\)\-.*/\1/'` X86_64=`echo $HOST_TARGET | sed -e 's/\(x86_64\)\-.*/\1/'` ALT= if [ "$X86_64" != "$HOST_TARGET" ]; then ALT="i686$REST" elif [ "$X86" != "$HOST_TARGET" ]; then ALT="x86_64$REST" fi echo $ALT