X-Git-Url: https://git.kernel.dk/?a=blobdiff_plain;f=configure;h=1f4e50b130b57c284373d17ab40631e9428cbe7e;hb=b538f06cf2834d1770bec3dc70cc419e6a89067f;hp=5490e26ea70f2db55f86c2e49ec2f9f362568767;hpb=84a815f5535cc9ac56e6c45926f0a2f4fe7c4b3f;p=fio.git diff --git a/configure b/configure index 5490e26e..1f4e50b1 100755 --- a/configure +++ b/configure @@ -2272,6 +2272,29 @@ if test "$disable_native" = "no" && test "$disable_opt" != "yes" && \ fi print_config "Build march=native" "$build_native" +########################################## +# check for -lcunit +if test "$cunit" != "yes" ; then + cunit="no" +fi +cat > $TMPC << EOF +#include +#include +int main(void) +{ + if (CU_initialize_registry() != CUE_SUCCESS) + return CU_get_error(); + CU_basic_set_mode(CU_BRM_VERBOSE); + CU_basic_run_tests(); + CU_cleanup_registry(); + return CU_get_error(); +} +EOF +if compile_prog "" "-lcunit" "CUnit"; then + cunit="yes" +fi +print_config "CUnit" "$cunit" + ############################################################################# if test "$wordsize" = "64" ; then @@ -2537,6 +2560,9 @@ fi if test "$march_set" = "no" && test "$build_native" = "yes" ; then output_sym "CONFIG_BUILD_NATIVE" fi +if test "$cunit" = "yes" ; then + output_sym "CONFIG_HAVE_CUNIT" +fi echo "LIBS+=$LIBS" >> $config_host_mak echo "GFIO_LIBS+=$GFIO_LIBS" >> $config_host_mak