3 # Fio configure script. Heavily influenced by the manual qemu configure
4 # script. Sad this this is easier than autoconf and enemies.
7 # set temporary file name
8 if test ! -z "$TMPDIR" ; then
10 elif test ! -z "$TEMPDIR" ; then
16 TMPC="${TMPDIR1}/fio-conf-${RANDOM}-$$-${RANDOM}.c"
17 TMPO="${TMPDIR1}/fio-conf-${RANDOM}-$$-${RANDOM}.o"
18 TMPE="${TMPDIR1}/fio-conf-${RANDOM}-$$-${RANDOM}.exe"
20 # NB: do not call "exit" in the trap handler; this is buggy with some shells;
21 # see <1285349658-3122-1-git-send-email-loic.minier@linaro.org>
22 trap "rm -f $TMPC $TMPO $TMPE" EXIT INT QUIT TERM
26 config_host_mak="config-host.mak"
27 config_host_h="config-host.h"
29 rm -rf $config_host_mak
34 echo "Configure failed, check config.log and/or the above output"
35 rm -rf $config_host_mak
41 CFLAGS="-D_GNU_SOURCE -include config-host.h"
44 # Print a helpful header at the top of config.log
45 echo "# FIO configure log $(date)" >> config.log
46 printf "# Configured with:" >> config.log
47 printf " '%s'" "$0" "$@" >> config.log
49 echo "#" >> config.log
51 # Print configure header at the top of $config_host_h
52 echo "/*" > $config_host_h
53 echo " * Automatically generated by configure - do not modify" >> $config_host_h
54 printf " * Configured with:" >> $config_host_h
55 printf " * '%s'" "$0" "$@" >> $config_host_h
56 echo "" >> $config_host_h
57 echo " */" >> $config_host_h
60 # Run the compiler, capturing its output to the log.
61 echo $cc "$@" >> config.log
62 $cc "$@" >> config.log 2>&1 || return $?
63 # Test passed. If this is an --enable-werror build, rerun
64 # the test with -Werror and bail out if it fails. This
65 # makes warning-generating-errors in configure test code
66 # obvious to developers.
67 if test "$werror" != "yes"; then
70 # Don't bother rerunning the compile if we were already using -Werror
76 echo $cc -Werror "$@" >> config.log
77 $cc -Werror "$@" >> config.log 2>&1 && return $?
78 echo "ERROR: configure test passed without -Werror but failed with -Werror."
79 echo "This is probably a bug in the configure script. The failing command"
80 echo "will be at the bottom of config.log."
81 fatal "You can run configure with --disable-werror to bypass this check."
85 do_cc $CFLAGS -c -o $TMPO $TMPC
90 local_ldflags="$2 $LIBS"
91 echo "Compiling test case $3" >> config.log
92 do_cc $CFLAGS $local_cflags -o $TMPE $TMPC $LDFLAGS $local_ldflags
100 echo "ERROR: User requested feature $feature"
101 if test ! -z "$packages" ; then
102 echo "ERROR: That feature needs $packages installed"
104 echo "ERROR: configure was not able to find it"
109 type "$1" >/dev/null 2>&1
115 #error $1 not defined
126 echo "$1=y" >> $config_host_mak
127 echo "#define $1" >> $config_host_h
133 cross_prefix=${cross_prefix-${CROSS_COMPILE}}
134 cc="${CC-${cross_prefix}gcc}"
143 optarg=`expr "x$opt" : 'x[^=]*=\(.*\)'`
145 --cpu=*) cpu="$optarg"
149 --extra-cflags=*) CFLAGS="$CFLAGS $optarg"
151 --build-32bit-win) build_32bit_win="yes"
156 --disable-numa) disable_numa="yes"
162 echo "Bad option $opt"
168 if test "$show_help" = "yes" ; then
169 echo "--cpu= Specify target CPU if auto-detect fails"
170 echo "--cc= Specify compiler to use"
171 echo "--extra-cflags= Specify extra CFLAGS to pass to compiler"
172 echo "--build-32bit-win Enable 32-bit build on Windows"
173 echo "--enable-gfio Enable building of gtk gfio"
174 echo "--disable-numa Disable libnuma even if found"
178 if check_define __ANDROID__ ; then
180 elif check_define __linux__ ; then
182 elif check_define __OpenBSD__ ; then
184 elif check_define __sun__ ; then
186 CFLAGS="$CFLAGS -D_REENTRANT"
191 echo "# Automatically generated by configure - do not modify" > $config_host_mak
192 printf "# Configured with:" >> $config_host_mak
193 printf " '%s'" "$0" "$@" >> $config_host_mak
194 echo >> $config_host_mak
195 echo "CONFIG_TARGET_OS=$targetos" >> $config_host_mak
197 # Some host OSes need non-standard checks for which CPU to use.
198 # Note that these checks are broken for cross-compilation: if you're
199 # cross-compiling to one of these OSes then you'll need to specify
200 # the correct CPU with the --cpu option.
203 # on Leopard most of the system is 32-bit, so we have to ask the kernel if
204 # we can run 64-bit userspace code.
205 # If the user didn't specify a CPU explicitly and the kernel says this is
206 # 64 bit hw, then assume x86_64. Otherwise fall through to the usual
208 if test -z "$cpu" && test "$(sysctl -n hw.optional.x86_64)" = "1"; then
213 # `uname -m` returns i86pc even on an x86_64 box, so default based on isainfo
214 if test -z "$cpu" && test "$(isainfo -k)" = "amd64"; then
217 LIBS="-lnsl -lsocket"
220 echo "Forcing known good options on Windows"
221 if test -z "$CC" ; then
222 if test ! -z "$build_32bit_win" && test "$build_32bit_win" = "yes"; then
223 CC="i686-w64-mingw32-gcc"
225 CC="x86_64-w64-mingw32-gcc"
228 output_sym "CONFIG_LITTLE_ENDIAN"
229 if test ! -z "$build_32bit_win" && test "$build_32bit_win" = "yes"; then
230 output_sym "CONFIG_32BIT"
232 output_sym "CONFIG_64BIT_LLP64"
234 output_sym "CONFIG_FADVISE"
235 output_sym "CONFIG_SOCKLEN_T"
236 output_sym "CONFIG_FADVISE"
237 output_sym "CONFIG_SFAA"
238 output_sym "CONFIG_RUSAGE_THREAD"
239 output_sym "CONFIG_WINDOWSAIO"
240 output_sym "CONFIG_FDATASYNC"
241 output_sym "CONFIG_CLOCK_MONOTONIC"
242 output_sym "CONFIG_GETTIMEOFDAY"
243 output_sym "CONFIG_CLOCK_GETTIME"
244 output_sym "CONFIG_SCHED_IDLE"
245 output_sym "CONFIG_TCP_NODELAY"
246 output_sym "CONFIG_TLS_THREAD"
247 echo "CC=$CC" >> $config_host_mak
248 echo "BUILD_CFLAGS=$CFLAGS -include config-host.h -D_GNU_SOURCE" >> $config_host_mak
253 if test ! -z "$cpu" ; then
254 # command line argument
256 elif check_define __i386__ ; then
258 elif check_define __x86_64__ ; then
260 elif check_define __sparc__ ; then
261 if check_define __arch64__ ; then
266 elif check_define _ARCH_PPC ; then
267 if check_define _ARCH_PPC64 ; then
272 elif check_define __mips__ ; then
274 elif check_define __ia64__ ; then
276 elif check_define __s390__ ; then
277 if check_define __s390x__ ; then
282 elif check_define __arm__ ; then
284 elif check_define __hppa__ ; then
290 # Normalise host CPU name and set ARCH.
292 ia64|ppc|ppc64|s390|s390x|sparc64)
295 i386|i486|i586|i686|i86pc|BePC)
304 hppa|parisc|parisc64)
318 if test -z "$CC" ; then
319 if test "$targetos" = "FreeBSD"; then
328 cc="${CC-${cross_prefix}gcc}"
330 ##########################################
331 # check cross compile
340 if compile_prog "" "" "cross"; then
341 $TMPE 2>/dev/null || cross_compile="yes"
343 fatal "compile test failed"
346 ##########################################
349 if test "$cross_compile" = "no" ; then
351 #include <inttypes.h>
354 volatile uint32_t i=0x01234567;
355 return (*((uint8_t*)(&i))) == 0x67;
358 if compile_prog "" "" "endian"; then
359 $TMPE && bigendian="yes"
362 # If we're cross compiling, try our best to work it out and rely on the
363 # run-time check to fail if we get it wrong.
368 #if __BYTE_ORDER != __BIG_ENDIAN
369 # error "Unknown endianness"
373 compile_prog "" "" "endian" && bigendian="yes"
374 check_define "__ARMEB__" && bigendian="yes"
375 check_define "__MIPSEB__" && bigendian="yes"
379 echo "Operating system $targetos"
381 echo "Big endian $bigendian"
383 echo "Cross compile $cross_compile"
386 ##########################################
391 #define BUILD_BUG_ON(condition) ((void)sizeof(char[1 - 2*!!(condition)]))
394 BUILD_BUG_ON(sizeof(long)*CHAR_BIT != WORDSIZE);
398 if compile_prog "-DWORDSIZE=32" "" "wordsize"; then
400 elif compile_prog "-DWORDSIZE=64" "" "wordsize"; then
403 fatal "Unknown wordsize"
405 echo "Wordsize $wordsize"
407 ##########################################
415 if (inflateInit(&stream) != Z_OK)
420 if compile_prog "" "-lz" "zlib" ; then
426 ##########################################
438 if compile_prog "" "-laio" "libaio" ; then
442 if test "$libaio" = "yes" ; then
443 feature_not_found "linux AIO" "libaio-dev or libaio-devel"
447 echo "Linux AIO support $libaio"
449 ##########################################
462 if compile_prog "" "" "posixaio" ; then
464 elif compile_prog "" "-lrt" "posixaio"; then
469 echo "POSIX AIO support $posix_aio"
470 echo "POSIX AIO support needs -lrt $posix_aio_lrt"
472 ##########################################
473 # posix aio fsync probe
475 if test "$posix_aio" = "yes" ; then
482 return aio_fsync(O_SYNC, &cb);
486 if compile_prog "" "$LIBS" "posix_aio_fsync" ; then
490 echo "POSIX AIO fsync $posix_aio_fsync"
492 ##########################################
496 #include <sys/types.h>
497 #include <sys/asynch.h>
502 return aioread(0, NULL, 0, 0, SEEK_SET, &res);
506 if compile_prog "" "-laio" "solarisaio" ; then
510 echo "Solaris AIO support $solaris_aio"
512 ##########################################
513 # __sync_fetch_and_and test
516 static int sfaa(int *ptr)
518 return __sync_fetch_and_add(ptr, 0);
521 int main(int argc, char **argv)
528 if compile_prog "" "" "__sync_fetch_and_add()" ; then
531 echo "__sync_fetch_and_add $sfaa"
533 ##########################################
538 #include <infiniband/arch.h>
539 int main(int argc, char **argv)
541 struct ibv_pd *pd = ibv_alloc_pd(NULL);
545 if compile_prog "" "-libverbs" "libverbs" ; then
547 LIBS="-libverbs $LIBS"
549 echo "libverbs $libverbs"
551 ##########################################
556 #include <rdma/rdma_cma.h>
557 int main(int argc, char **argv)
559 rdma_destroy_qp(NULL);
563 if compile_prog "" "-lrdmacm" "rdma"; then
565 LIBS="-lrdmacm $LIBS"
567 echo "rdmacm $rdmacm"
569 ##########################################
570 # Linux fallocate probe
575 #include <linux/falloc.h>
576 int main(int argc, char **argv)
578 int r = fallocate(0, FALLOC_FL_KEEP_SIZE, 0, 1024);
582 if compile_prog "" "" "linux_fallocate"; then
583 linux_fallocate="yes"
585 echo "Linux fallocate $linux_fallocate"
587 ##########################################
588 # POSIX fadvise probe
593 int main(int argc, char **argv)
595 int r = posix_fadvise(0, 0, 0, POSIX_FADV_NORMAL);
599 if compile_prog "" "" "posix_fadvise"; then
602 echo "POSIX fadvise $posix_fadvise"
604 ##########################################
605 # POSIX fallocate probe
610 int main(int argc, char **argv)
612 int r = posix_fallocate(0, 0, 1024);
616 if compile_prog "" "" "posix_fallocate"; then
617 posix_fallocate="yes"
619 echo "POSIX fallocate $posix_fallocate"
621 ##########################################
622 # sched_set/getaffinity 2 or 3 argument test
623 linux_2arg_affinity="no"
624 linux_3arg_affinity="no"
627 int main(int argc, char **argv)
630 return sched_setaffinity(0, sizeof(mask), &mask);
633 if compile_prog "" "" "sched_setaffinity(,,)"; then
634 linux_3arg_affinity="yes"
638 int main(int argc, char **argv)
641 return sched_setaffinity(0, &mask);
644 if compile_prog "" "" "sched_setaffinity(,)"; then
645 linux_2arg_affinity="yes"
648 echo "sched_setaffinity(3 arg) $linux_3arg_affinity"
649 echo "sched_setaffinity(2 arg) $linux_2arg_affinity"
651 ##########################################
652 # clock_gettime probe
657 int main(int argc, char **argv)
659 return clock_gettime(0, NULL);
662 if compile_prog "" "" "clock_gettime"; then
664 elif compile_prog "" "-lrt" "clock_gettime"; then
668 echo "clock_gettime $clock_gettime"
670 ##########################################
671 # CLOCK_MONOTONIC probe
673 if test "$clock_gettime" = "yes" ; then
677 int main(int argc, char **argv)
679 return clock_gettime(CLOCK_MONOTONIC, NULL);
682 if compile_prog "" "$LIBS" "clock monotonic"; then
683 clock_monotonic="yes"
686 echo "CLOCK_MONOTONIC $clock_monotonic"
688 ##########################################
689 # CLOCK_MONOTONIC_PRECISE probe
690 clock_monotonic_precise="no"
691 if test "$clock_gettime" = "yes" ; then
695 int main(int argc, char **argv)
697 return clock_gettime(CLOCK_MONOTONIC_PRECISE, NULL);
700 if compile_prog "" "$LIBS" "clock monotonic precise"; then
701 clock_monotonic_precise="yes"
704 echo "CLOCK_MONOTONIC_PRECISE $clock_monotonic_precise"
706 ##########################################
707 # gettimeofday() probe
710 #include <sys/time.h>
712 int main(int argc, char **argv)
715 return gettimeofday(&tv, NULL);
718 if compile_prog "" "" "gettimeofday"; then
721 echo "gettimeofday $gettimeofday"
723 ##########################################
729 int main(int argc, char **argv)
734 if compile_prog "" "" "fdatasync"; then
737 echo "fdatasync $fdatasync"
739 ##########################################
740 # sync_file_range() probe
746 #include <linux/fs.h>
747 int main(int argc, char **argv)
749 unsigned int flags = SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE |
750 SYNC_FILE_RANGE_WAIT_AFTER;
751 return sync_file_range(0, 0, 0, flags);
754 if compile_prog "" "" "sync_file_range"; then
755 sync_file_range="yes"
757 echo "sync_file_range $sync_file_range"
759 ##########################################
760 # ext4 move extent probe
764 #include <sys/ioctl.h>
765 int main(int argc, char **argv)
767 struct move_extent me;
768 return ioctl(0, EXT4_IOC_MOVE_EXT, &me);
771 if compile_prog "" "" "ext4 move extent" ; then
773 elif test $targetos = "Linux" ; then
774 # On Linux, just default to it on and let it error at runtime if we really
775 # don't have it. None of my updated systems have it defined, but it does
776 # work. Takes a while to bubble back.
779 echo "EXT4 move extent $ext4_me"
781 ##########################################
787 int main(int argc, char **argv)
789 return splice(0, NULL, 0, NULL, 0, SPLICE_F_NONBLOCK);
792 if compile_prog "" "" "linux splice"; then
795 echo "Linux splice(2) $linux_splice"
797 ##########################################
802 #include <guasi_syscalls.h>
803 int main(int argc, char **argv)
805 guasi_t ctx = guasi_create(0, 0, 0);
809 if compile_prog "" "" "guasi"; then
814 ##########################################
818 #include <nvm/nvm_primitives.h>
819 int main(int argc, char **argv)
821 nvm_version_t ver_info;
824 handle = nvm_get_handle(0, &ver_info);
825 return nvm_atomic_write(handle, 0, 0, 0);
828 if compile_prog "" "-L/usr/lib/fio -L/usr/lib/nvm -lnvm-primitives -lvsl -ldl" "fusion-aw"; then
829 LIBS="-L/usr/lib/fio -L/usr/lib/nvm -lnvm-primitives -lvsl -ldl $LIBS"
832 echo "Fusion-io atomic engine $fusion_aw"
834 ##########################################
839 int main(int argc, char **argv)
841 return numa_available();
844 if test "$disable_numa" != "yes" && compile_prog "" "-lnuma" "libnuma"; then
848 echo "libnuma $libnuma"
850 ##########################################
851 # libnuma 2.x version API
852 if test "$libnuma" = "yes" ; then
856 int main(int argc, char **argv)
858 struct bitmask *mask = numa_parse_nodestring(NULL);
862 if compile_prog "" "" "libnuma api"; then
865 echo "libnuma v2 $libnuma_v2"
868 ##########################################
873 int main(int argc, char **argv)
879 if compile_prog "" "" "strsep"; then
882 echo "strsep $strsep"
884 ##########################################
889 int main(int argc, char **argv)
891 return strcasestr(argv[0], argv[1]) != NULL;
894 if compile_prog "" "" "strcasestr"; then
897 echo "strcasestr $strcasestr"
899 ##########################################
900 # getopt_long_only() probe
901 getopt_long_only="no"
906 int main(int argc, char **argv)
908 int c = getopt_long_only(argc, argv, NULL, NULL, NULL);
912 if compile_prog "" "" "getopt_long_only"; then
913 getopt_long_only="yes"
915 echo "getopt_long_only() $getopt_long_only"
917 ##########################################
921 #include <sys/socket.h>
922 #include <arpa/inet.h>
924 int main(int argc, char **argv)
927 return inet_aton(NULL, &in);
930 if compile_prog "" "" "inet_aton"; then
933 echo "inet_aton $inet_aton"
935 ##########################################
939 #include <sys/socket.h>
940 int main(int argc, char **argv)
946 if compile_prog "" "" "socklen_t"; then
949 echo "socklen_t $socklen_t"
951 ##########################################
952 # Whether or not __thread is supported for TLS
956 static __thread int ret;
957 int main(int argc, char **argv)
962 if compile_prog "" "" "__thread"; then
965 echo "__thread $tls_thread"
967 ##########################################
968 # Check if we have required gtk/glib support for gfio
969 if test "$gfio" = "yes" ; then
979 printf("%d", GTK_CHECK_VERSION(2, 18, 0));
982 GTK_CFLAGS=$(pkg-config --cflags gtk+-2.0 gthread-2.0)
983 if test "$?" != "0" ; then
984 echo "configure: gtk and gthread not found"
987 GTK_LIBS=$(pkg-config --libs gtk+-2.0 gthread-2.0)
988 if test "$?" != "0" ; then
989 echo "configure: gtk and gthread not found"
992 if compile_prog "$GTK_CFLAGS" "$GTK_LIBS" "gfio" ; then
994 if test "$r" != "0" ; then
996 LIBS="$LIBS $GTK_LIBS"
997 CFLAGS="$CFLAGS $GTK_CFLAGS"
999 echo "GTK found, but need version 2.18 or higher"
1003 echo "Please install gtk and gdk libraries"
1008 echo "gtk 2.18 or higher $gfio"
1010 # Check whether we have getrusage(RUSAGE_THREAD)
1013 #include <sys/time.h>
1014 #include <sys/resource.h>
1015 int main(int argc, char **argv)
1018 getrusage(RUSAGE_THREAD, &ru);
1022 if compile_prog "" "" "RUSAGE_THREAD"; then
1025 echo "RUSAGE_THREAD $rusage_thread"
1027 ##########################################
1028 # Check whether we have SCHED_IDLE
1032 int main(int argc, char **argv)
1034 struct sched_param p;
1035 return sched_setscheduler(0, SCHED_IDLE, &p);
1038 if compile_prog "" "" "SCHED_IDLE"; then
1041 echo "SCHED_IDLE $sched_idle"
1043 ##########################################
1044 # Check whether we have TCP_NODELAY
1048 #include <sys/types.h>
1049 #include <sys/socket.h>
1050 #include <netinet/tcp.h>
1051 int main(int argc, char **argv)
1053 return getsockopt(0, 0, TCP_NODELAY, NULL, NULL);
1056 if compile_prog "" "" "TCP_NODELAY"; then
1059 echo "TCP_NODELAY $tcp_nodelay"
1061 ##########################################
1062 # Check whether we have RLIMIT_MEMLOCK
1065 #include <sys/time.h>
1066 #include <sys/resource.h>
1067 int main(int argc, char **argv)
1070 return getrlimit(RLIMIT_MEMLOCK, &rl);
1073 if compile_prog "" "" "RLIMIT_MEMLOCK"; then
1074 rlimit_memlock="yes"
1076 echo "RLIMIT_MEMLOCK $rlimit_memlock"
1078 ##########################################
1079 # Check whether we have pwritev/preadv
1083 #include <sys/uio.h>
1084 int main(int argc, char **argv)
1086 return pwritev(0, NULL, 1, 0) + preadv(0, NULL, 1, 0);
1089 if compile_prog "" "" "pwritev"; then
1092 echo "pwritev/preadv $pwritev"
1094 ##########################################
1095 # Check whether we have the required functions for ipv6
1098 #include <sys/types.h>
1099 #include <sys/socket.h>
1102 int main(int argc, char **argv)
1104 struct addrinfo hints;
1105 struct in6_addr addr;
1108 ret = getaddrinfo(NULL, NULL, &hints, NULL);
1110 printf("%s\n", gai_strerror(ret));
1115 if compile_prog "" "" "ipv6"; then
1118 echo "IPv6 helpers $ipv6"
1120 #############################################################################
1122 if test "$wordsize" = "64" ; then
1123 output_sym "CONFIG_64BIT"
1124 elif test "$wordsize" = "32" ; then
1125 output_sym "CONFIG_32BIT"
1127 fatal "Unknown wordsize!"
1129 if test "$bigendian" = "yes" ; then
1130 output_sym "CONFIG_BIG_ENDIAN"
1132 output_sym "CONFIG_LITTLE_ENDIAN"
1134 if test "$zlib" = "yes" ; then
1135 output_sym "CONFIG_ZLIB"
1137 if test "$libaio" = "yes" ; then
1138 output_sym "CONFIG_LIBAIO"
1140 if test "$posix_aio" = "yes" ; then
1141 output_sym "CONFIG_POSIXAIO"
1143 if test "$posix_aio_fsync" = "yes" ; then
1144 output_sym "CONFIG_POSIXAIO_FSYNC"
1146 if test "$linux_fallocate" = "yes" ; then
1147 output_sym "CONFIG_LINUX_FALLOCATE"
1149 if test "$posix_fallocate" = "yes" ; then
1150 output_sym "CONFIG_POSIX_FALLOCATE"
1152 if test "$fdatasync" = "yes" ; then
1153 output_sym "CONFIG_FDATASYNC"
1155 if test "$sync_file_range" = "yes" ; then
1156 output_sym "CONFIG_SYNC_FILE_RANGE"
1158 if test "$sfaa" = "yes" ; then
1159 output_sym "CONFIG_SFAA"
1161 if test "$libverbs" = "yes" -a "$rdmacm" = "yes" ; then
1162 output_sym "CONFIG_RDMA"
1164 if test "$clock_gettime" = "yes" ; then
1165 output_sym "CONFIG_CLOCK_GETTIME"
1167 if test "$clock_monotonic" = "yes" ; then
1168 output_sym "CONFIG_CLOCK_MONOTONIC"
1170 if test "$clock_monotonic_precise" = "yes" ; then
1171 output_sym "CONFIG_CLOCK_MONOTONIC_PRECISE"
1173 if test "$gettimeofday" = "yes" ; then
1174 output_sym "CONFIG_GETTIMEOFDAY"
1176 if test "$posix_fadvise" = "yes" ; then
1177 output_sym "CONFIG_POSIX_FADVISE"
1179 if test "$linux_3arg_affinity" = "yes" ; then
1180 output_sym "CONFIG_3ARG_AFFINITY"
1181 elif test "$linux_2arg_affinity" = "yes" ; then
1182 output_sym "CONFIG_2ARG_AFFINITY"
1184 if test "$strsep" = "yes" ; then
1185 output_sym "CONFIG_STRSEP"
1187 if test "$strcasestr" = "yes" ; then
1188 output_sym "CONFIG_STRCASESTR"
1190 if test "$getopt_long_only" = "yes" ; then
1191 output_sym "CONFIG_GETOPT_LONG_ONLY"
1193 if test "$inet_aton" = "yes" ; then
1194 output_sym "CONFIG_INET_ATON"
1196 if test "$socklen_t" = "yes" ; then
1197 output_sym "CONFIG_SOCKLEN_T"
1199 if test "$ext4_me" = "yes" ; then
1200 output_sym "CONFIG_LINUX_EXT4_MOVE_EXTENT"
1202 if test "$linux_splice" = "yes" ; then
1203 output_sym "CONFIG_LINUX_SPLICE"
1205 if test "$guasi" = "yes" ; then
1206 output_sym "CONFIG_GUASI"
1208 if test "$fusion_aw" = "yes" ; then
1209 output_sym "CONFIG_FUSION_AW"
1211 if test "$libnuma_v2" = "yes" ; then
1212 output_sym "CONFIG_LIBNUMA"
1214 if test "$solaris_aio" = "yes" ; then
1215 output_sym "CONFIG_SOLARISAIO"
1217 if test "$tls_thread" = "yes" ; then
1218 output_sym "CONFIG_TLS_THREAD"
1220 if test "$rusage_thread" = "yes" ; then
1221 output_sym "CONFIG_RUSAGE_THREAD"
1223 if test "$gfio" = "yes" ; then
1224 echo "CONFIG_GFIO=y" >> $config_host_mak
1226 if test "$sched_idle" = "yes" ; then
1227 output_sym "CONFIG_SCHED_IDLE"
1229 if test "$tcp_nodelay" = "yes" ; then
1230 output_sym "CONFIG_TCP_NODELAY"
1232 if test "$rlimit_memlock" = "yes" ; then
1233 output_sym "CONFIG_RLIMIT_MEMLOCK"
1235 if test "$pwritev" = "yes" ; then
1236 output_sym "CONFIG_PWRITEV"
1238 if test "$ipv6" = "yes" ; then
1239 output_sym "CONFIG_IPV6"
1242 echo "LIBS+=$LIBS" >> $config_host_mak
1243 echo "CFLAGS+=$CFLAGS" >> $config_host_mak
1244 echo "CC=$cc" >> $config_host_mak
1245 echo "BUILD_CFLAGS=$BUILD_CFLAGS $CFLAGS" >> $config_host_mak