Blame strip_non_asm_libtool_args.sh

Packit 8f7830
#!/bin/sh
Packit 8f7830
#
Packit 8f7830
# libtool assumes that the compiler can handle the -fPIC flag.
Packit 8f7830
# This isn't always true (for example, nasm can't handle it).
Packit 8f7830
# Also, on some versions of OS X it tries to pass -fno-common
Packit 8f7830
# to 'as' which causes problems.
Packit 8f7830
command=""
Packit 8f7830
while [ $1 ]; do
Packit 8f7830
	if [ "$1" != "-fPIC" ]; then
Packit 8f7830
		if [ "$1" != "-DPIC" ]; then
Packit 8f7830
			if [ "$1" != "-fno-common" ]; then
Packit 8f7830
				command="$command $1"
Packit 8f7830
			fi
Packit 8f7830
		fi
Packit 8f7830
	fi
Packit 8f7830
	shift
Packit 8f7830
done
Packit 8f7830
echo $command
Packit 8f7830
exec $command