aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/strace/strace/strace-add-configure-options.patch
blob: 84b9f9cab5f8adcfbe4cd924dfa28b3c689d99a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
Add option "aio" to enable/disable libaio support.

Upstream-Status: Pending

Signed-off-by: Kai Kang <kai.kang@windriver.com>
Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
---
 configure.ac |   26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)

diff --git a/configure.ac b/configure.ac
index e73958c..9099370 100644
--- a/configure.ac
+++ b/configure.ac
@@ -303,11 +303,6 @@ AC_CHECK_MEMBERS([struct sysinfo.totalhi
 
 AC_CHECK_TYPES([struct flock64],,, [#include <fcntl.h>])
 
-AC_CHECK_HEADERS([libaio.h], [
-	AC_CHECK_MEMBERS([struct iocb.u.c.flags],,, [#include <libaio.h>])
-	AC_CHECK_DECLS([IO_CMD_PWRITE, IO_CMD_PWRITEV],,, [#include <libaio.h>])
-])
-
 AC_CHECK_HEADERS([linux/input.h], [
 	AC_CHECK_MEMBERS([struct input_absinfo.resolution],,, [#include <linux/input.h>])
 ])
@@ -745,6 +740,20 @@ if test "x$ac_cv_lib_dl_dladdr" = xyes;
 fi
 AC_SUBST(dl_LIBS)
 
+AC_ARG_ENABLE([aio],
+	[AS_HELP_STRING([--enable-aio], [turn on libaio support])],
+	[case $enableval in
+	yes)
+	AC_CHECK_HEADERS([libaio.h], [
+		AC_CHECK_MEMBERS([struct iocb.u.c.flags],,, [#include <libaio.h>])
+		AC_CHECK_DECLS([IO_CMD_PWRITE, IO_CMD_PWRITEV],,, [#include <libaio.h>])
+	])
+	;;
+	no)  ;;
+	*)   AC_MSG_ERROR([bad value $enableval for aio option]) ;;
+	esac]
+)
+
 AC_PATH_PROG([PERL], [perl])
 
 dnl stack trace with libunwind
--
1.9.1