All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chong Lu <Chong.Lu@windriver.com>
To: <openembedded-devel@lists.openembedded.org>
Subject: [PATCH 3/3] vim: add knob whether elf.h are checked
Date: Fri, 18 Apr 2014 18:16:32 +0800	[thread overview]
Message-ID: <fcf0027b255a0441d42df0e9f2584067c3ec3d74.1397816030.git.Chong.Lu@windriver.com> (raw)
In-Reply-To: <cover.1397816030.git.Chong.Lu@windriver.com>

Previously, it still was checked when there was no elf library in sysroots directory.
Add knob to decide whether elf.h are checked or not.

Fixed by using PACKAGECONFIG to check elf, with default disabled set.

Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
---
 .../vim-add-knob-whether-elf.h-are-checked.patch   | 38 ++++++++++++++++++++++
 meta-oe/recipes-support/vim/vim_7.4.258.bb         |  2 ++
 2 files changed, 40 insertions(+)
 create mode 100644 meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch

diff --git a/meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch b/meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch
new file mode 100644
index 0000000..693d130
--- /dev/null
+++ b/meta-oe/recipes-support/vim/files/vim-add-knob-whether-elf.h-are-checked.patch
@@ -0,0 +1,38 @@
+vim: add knob whether elf.h are checked
+
+Previously, it still was checked when there was no elf library in sysroots directory.
+Add knob to decide whether elf.h are checked or not.
+
+Upstream-status: Pending
+
+Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
+---
+ src/configure.in |    7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/src/configure.in b/src/configure.in
+index d734064..f504fa6 100644
+--- a/src/configure.in
++++ b/src/configure.in
+@@ -2483,11 +2483,18 @@ AC_TRY_COMPILE([#include <stdio.h>], [int x __attribute__((unused));],
+ 	AC_MSG_RESULT(no))
+ 
+ dnl Checks for header files.
++AC_MSG_CHECKING(whether or not to look for elf.h)
++AC_ARG_ENABLE(elf-check,
++        [  --enable-elf-check      If elfutils, check for elf.h [default=no]],
++        , enable_elf_check="no")
++AC_MSG_RESULT($enable_elf_check)
++if test "x$enable_elf_check" != "xno"; then
+ AC_CHECK_HEADER(elf.h, HAS_ELF=1)
+ dnl AC_CHECK_HEADER(dwarf.h, SVR4=1)
+ if test "$HAS_ELF" = 1; then
+   AC_CHECK_LIB(elf, main)
+ fi
++fi
+ 
+ AC_HEADER_DIRENT
+ 
+-- 
+1.7.9.5
+
diff --git a/meta-oe/recipes-support/vim/vim_7.4.258.bb b/meta-oe/recipes-support/vim/vim_7.4.258.bb
index 9c6e231..19c8abc 100644
--- a/meta-oe/recipes-support/vim/vim_7.4.258.bb
+++ b/meta-oe/recipes-support/vim/vim_7.4.258.bb
@@ -8,6 +8,7 @@ LIC_FILES_CHKSUM = "file://../runtime/doc/uganda.txt;md5=b779e18be6ed77facc77069
 
 SRC_URI = "hg://vim.googlecode.com/hg/;protocol=https;module=vim \
            file://disable_acl_header_check.patch;patchdir=.. \
+           file://vim-add-knob-whether-elf.h-are-checked.patch;patchdir=.. \
 "
 SRCREV = "v7-4-258"
 
@@ -38,6 +39,7 @@ PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
 PACKAGECONFIG[x11] = "--with-x,--without-x,xt,"
 PACKAGECONFIG[tiny] = "--with-features=tiny,--with-features=big,,"
 PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux,"
+PACKAGECONFIG[elfutils] = "--enable-elf-check,,elfutils,"
 
 EXTRA_OECONF = " \
     --disable-gpm \
-- 
1.8.1.2



      parent reply	other threads:[~2014-04-18 10:16 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-18 10:16 [PATCH 0/3] vim: add dependency and selinux and acl support control Chong Lu
2014-04-18 10:16 ` [PATCH 1/3] " Chong Lu
2014-04-21 11:32   ` Martin Jansa
2014-05-05 21:45   ` Paul Barker
2014-05-06  2:55     ` Chong Lu
2014-05-06 10:01       ` Paul Barker
2014-05-06  5:08     ` Chong Lu
2014-04-18 10:16 ` [PATCH 2/3] vim: don't check acl header if acl support disabled Chong Lu
2014-04-18 10:16 ` Chong Lu [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fcf0027b255a0441d42df0e9f2584067c3ec3d74.1397816030.git.Chong.Lu@windriver.com \
    --to=chong.lu@windriver.com \
    --cc=openembedded-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.