summaryrefslogblamecommitdiffstats
path: root/tools/config-gen
blob: b7ccadd0a096d6c9495135cac9343f7b60533dc8 (plain) (tree)
1
2
3
4
5
6
         



                                                 
                              



















                                                                             

                        

  



                             

                 
#!/bin/sh
#
# Copyright (C) 2011 Karel Zak <kzak@redhat.com> 
# 

test -f sys-utils/mount.c || {
	echo
	echo "You must run this script in the top-level util-linux directory"
	echo
	exit 1
}

. tools/config-gen-functions.sh

while [ -n "$1" ]; do
	opts="$opts $(ul_get_configuration tools/config-gen.d/$1.conf)"
	shift
done

opts=$(echo $opts | tr " " "\n" | sort -u)
echo "Configure options:"
for x in $opts; do
	echo "	$x"
done
if [ -n "$CFLAGS" ]; then
	echo "CFLAGS:	$CFLAGS"
	CFLAGS="$CFLAGS"
	export CFLAGS
fi

if [ ! -f ./configure ]; then
	./autogen.sh
fi

echo
./configure $opts