diff options
Diffstat (limited to 'meta-networking/recipes-connectivity/freeradius/files/0005-configure.ac-add-option-for-libcap.patch')
| -rw-r--r-- | meta-networking/recipes-connectivity/freeradius/files/0005-configure.ac-add-option-for-libcap.patch | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/meta-networking/recipes-connectivity/freeradius/files/0005-configure.ac-add-option-for-libcap.patch b/meta-networking/recipes-connectivity/freeradius/files/0005-configure.ac-add-option-for-libcap.patch new file mode 100644 index 0000000000..8ef3c4bdf9 --- /dev/null +++ b/meta-networking/recipes-connectivity/freeradius/files/0005-configure.ac-add-option-for-libcap.patch | |||
| @@ -0,0 +1,70 @@ | |||
| 1 | From 9548dc5e1a6c835cd4f387ba384d8f3f14c3fc8b Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Changqing Li <changqing.li@windriver.com> | ||
| 3 | Date: Thu, 22 Aug 2019 10:50:21 +0800 | ||
| 4 | Subject: [PATCH] configure.ac: add option for libcap | ||
| 5 | |||
| 6 | Upstream-Status: Pending | ||
| 7 | |||
| 8 | Signed-off-by: Jackie Huang <jackie.huang@windriver.com> | ||
| 9 | Signed-off-by: Changqing Li <changqing.li@windriver.com> | ||
| 10 | --- | ||
| 11 | configure.ac | 36 +++++++++++++++++++++++++++--------- | ||
| 12 | 1 file changed, 27 insertions(+), 9 deletions(-) | ||
| 13 | |||
| 14 | diff --git a/configure.ac b/configure.ac | ||
| 15 | index ef8fced680..263098f7fd 100644 | ||
| 16 | --- a/configure.ac | ||
| 17 | +++ b/configure.ac | ||
| 18 | @@ -1161,6 +1161,22 @@ fi | ||
| 19 | dnl Set by FR_SMART_CHECKLIB | ||
| 20 | LIBS="${old_LIBS}" | ||
| 21 | |||
| 22 | +dnl # | ||
| 23 | +dnl # extra argument: --with-libcap | ||
| 24 | +dnl # | ||
| 25 | +WITH_LIBCAP=yes | ||
| 26 | +AC_ARG_WITH(libcap, | ||
| 27 | +[ --with-licap use licap for debugger checks. (default=yes)], | ||
| 28 | +[ case "$withval" in | ||
| 29 | + no) | ||
| 30 | + WITH_LIBCAP=no | ||
| 31 | + ;; | ||
| 32 | + *) | ||
| 33 | + WITH_LIBCAP=yes | ||
| 34 | + ;; | ||
| 35 | + esac ] | ||
| 36 | +) | ||
| 37 | + | ||
| 38 | dnl Check for cap | ||
| 39 | dnl extra argument: --with-cap-lib-dir=DIR | ||
| 40 | cap_lib_dir= | ||
| 41 | @@ -1194,15 +1210,17 @@ AC_ARG_WITH(cap-include-dir, | ||
| 42 | ;; | ||
| 43 | esac]) | ||
| 44 | |||
| 45 | -smart_try_dir="$cap_lib_dir" | ||
| 46 | -FR_SMART_CHECK_LIB(cap, cap_get_proc) | ||
| 47 | -if test "x$ac_cv_lib_cap_cap_get_proc" != "xyes"; then | ||
| 48 | - AC_MSG_WARN([cap library not found, debugger checks will not be enabled. Use --with-cap-lib-dir=<path>.]) | ||
| 49 | -else | ||
| 50 | - AC_DEFINE(HAVE_LIBCAP, 1, | ||
| 51 | - [Define to 1 if you have the `cap' library (-lcap).] | ||
| 52 | - ) | ||
| 53 | - HAVE_LIBCAP=1 | ||
| 54 | +if test "x$WITH_LIBCAP" = xyes; then | ||
| 55 | + smart_try_dir="$cap_lib_dir" | ||
| 56 | + FR_SMART_CHECK_LIB(cap, cap_get_proc) | ||
| 57 | + if test "x$ac_cv_lib_cap_cap_get_proc" != "xyes"; then | ||
| 58 | + AC_MSG_WARN([cap library not found, debugger checks will not be enabled. Use --with-cap-lib-dir=<path>.]) | ||
| 59 | + else | ||
| 60 | + AC_DEFINE(HAVE_LIBCAP, 1, | ||
| 61 | + [Define to 1 if you have the `cap' library (-lcap).] | ||
| 62 | + ) | ||
| 63 | + HAVE_LIBCAP=1 | ||
| 64 | + fi | ||
| 65 | fi | ||
| 66 | |||
| 67 | dnl # | ||
| 68 | -- | ||
| 69 | 2.25.1 | ||
| 70 | |||
