Openembedded Devel Discussions
 help / color / mirror / Atom feed
From: Pascal Bach <pascal.bach@siemens.com>
To: openembedded-devel@lists.openembedded.org
Subject: [meta-oe][PATCH 2/2] libyui-ncurses: fix ncurses find module
Date: Tue, 30 Oct 2018 14:29:57 +0100	[thread overview]
Message-ID: <20181030132957.32537-2-pascal.bach@siemens.com> (raw)
In-Reply-To: <20181030132957.32537-1-pascal.bach@siemens.com>

This makes the module look in the standard locations instead of only some
hard coded ones.

Signed-off-by: Pascal Bach <pascal.bach@siemens.com>
---
 .../0003-Simplify-ncurses-finding-module.patch     | 35 ++++++++++++++++++++++
 .../recipes-graphics/libyui/libyui-ncurses_git.bb  |  1 +
 2 files changed, 36 insertions(+)
 create mode 100644 meta-oe/recipes-graphics/libyui/libyui-ncurses/0003-Simplify-ncurses-finding-module.patch

diff --git a/meta-oe/recipes-graphics/libyui/libyui-ncurses/0003-Simplify-ncurses-finding-module.patch b/meta-oe/recipes-graphics/libyui/libyui-ncurses/0003-Simplify-ncurses-finding-module.patch
new file mode 100644
index 000000000..2520ac46f
--- /dev/null
+++ b/meta-oe/recipes-graphics/libyui/libyui-ncurses/0003-Simplify-ncurses-finding-module.patch
@@ -0,0 +1,35 @@
+From c2291fe28dc5682f81804941512431642975cf21 Mon Sep 17 00:00:00 2001
+From: Pascal Bach <pascal.bach@siemens.com>
+Date: Mon, 29 Oct 2018 18:17:32 +0100
+Subject: [PATCH] Simplify ncurses finding module
+
+CMake will automatically look in the right locations, there is no need to
+re-implement the logic with a for loop and NO_DEFAULT_PATH.
+
+It is already done like this to file the headers.
+
+Upstream-Status: Submitted [https://github.com/libyui/libyui-ncurses/pull/73]
+Signed-off-by: Pascal Bach <pascal.bach@siemens.com>
+---
+ cmake/Modules/FindCurses6.cmake | 8 +++-----
+ 1 file changed, 3 insertions(+), 5 deletions(-)
+
+diff --git a/cmake/Modules/FindCurses6.cmake b/cmake/Modules/FindCurses6.cmake
+index 0bf02c3..e298d5d 100644
+--- a/cmake/Modules/FindCurses6.cmake
++++ b/cmake/Modules/FindCurses6.cmake
+@@ -5,11 +5,9 @@
+ #  CURSES6_LIBRARIES - The libraries needed to use Curses6
+ #  CURSES6_DEFINITIONS - Compiler switches required for using Curses6
+ 
+-FOREACH(path ${CMAKE_LIBRARY_PATH} /usr/${LIB_DIR})
+-  FIND_LIBRARY(CURSES6_NCURSESW_LIBRARY NAMES ncursesw PATHS ${path}/ncurses6 ${path} NO_DEFAULT_PATH)
+-  FIND_LIBRARY(CURSES6_PANELW_LIBRARY NAMES panelw PATHS ${path}/ncurses6 ${path} NO_DEFAULT_PATH)
+-  FIND_LIBRARY(CURSES6_TINFO_LIBRARY NAMES tinfo PATHS ${path}/ncurses6 ${path} NO_DEFAULT_PATH)
+-ENDFOREACH()
++FIND_LIBRARY(CURSES6_NCURSESW_LIBRARY NAMES ncursesw PATH_SUFFIXES ncurses6)
++FIND_LIBRARY(CURSES6_PANELW_LIBRARY NAMES panelw PATH_SUFFIXES ncurses6)
++FIND_LIBRARY(CURSES6_TINFO_LIBRARY NAMES tinfo PATH_SUFFIXES ncurses6)
+ 
+ SET(CURSES6_LIBRARIES ${CURSES6_NCURSESW_LIBRARY} ${CURSES6_PANELW_LIBRARY})
+ # tinfo is optional (in 12.1 is not there)
diff --git a/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb b/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb
index 4fafce166..18ea2e828 100644
--- a/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb
+++ b/meta-oe/recipes-graphics/libyui/libyui-ncurses_git.bb
@@ -7,6 +7,7 @@ LIC_FILES_CHKSUM = "file://COPYING.lgpl-3;md5=e6a600fd5e1d9cbde2d983680233ad02 \
 SRC_URI = "git://github.com/libyui/libyui-ncurses.git \
            file://0001-Use-override-consistently.patch \
            file://0002-Define-own-resize-in-NCPad-and-fix-param-type-of-Set.patch \
+           file://0003-Simplify-ncurses-finding-module.patch \
           "
 
 SRC_URI_append_class-target = " file://0001-Fix-the-error-of-can-t-find-header-file.patch"
-- 
2.11.0



      reply	other threads:[~2018-10-30 13:30 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-30 13:29 [meta-oe][PATCH 1/2] libyui: make resulting cmake config relocatable Pascal Bach
2018-10-30 13:29 ` Pascal Bach [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=20181030132957.32537-2-pascal.bach@siemens.com \
    --to=pascal.bach@siemens.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox