diff options
author | Jeremy Huddleston <jeremy@vincent.local> | 2009-12-20 21:34:27 -0800 |
---|---|---|
committer | Jeremy Huddleston <jeremy@vincent.local> | 2009-12-20 21:34:27 -0800 |
commit | ad7f9d71e22fb7667c90dbbc0558939b89a45154 (patch) | |
tree | 947236e0b8aaab4510219f7c755489cf4940b21f /bin/mklib | |
parent | 4a1e103858a1db0fb037891b8d4a9426eff32b98 (diff) | |
download | external_mesa3d-ad7f9d71e22fb7667c90dbbc0558939b89a45154.zip external_mesa3d-ad7f9d71e22fb7667c90dbbc0558939b89a45154.tar.gz external_mesa3d-ad7f9d71e22fb7667c90dbbc0558939b89a45154.tar.bz2 |
darwin: mklib: Use lipo rather than file to figure out architectures of object files
Diffstat (limited to 'bin/mklib')
-rwxr-xr-x | bin/mklib | 20 |
1 files changed, 4 insertions, 16 deletions
@@ -724,22 +724,10 @@ case $ARCH in # examine first object to determine ABI set ${OBJECTS} - ABI_PPC=`file $1 | grep ' ppc'` - ABI_I386=`file $1 | grep ' i386'` - ABI_PPC64=`file $1 | grep ' ppc64'` - ABI_X86_64=`file $1 | grep ' x86_64'` - if [ "${ABI_PPC}" ] ; then - OPTS="${OPTS} -arch ppc" - fi - if [ "${ABI_I386}" ] ; then - OPTS="${OPTS} -arch i386" - fi - if [ "${ABI_PPC64}" ] ; then - OPTS="${OPTS} -arch ppc64" - fi - if [ "${ABI_X86_64}" ] ; then - OPTS="${OPTS} -arch x86_64" - fi + ABIS=`lipo -info $1 | sed s/.*://` + for ABI in $ABIS; do + OPTS="${OPTS} -arch ${ABI}" + done if [ "${ALTOPTS}" ] ; then OPTS=${ALTOPTS} |