All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-oe][PATCH] lshw: Add new recipe with B.02.18 version
@ 2018-06-01 12:06 Krzysztof Kozlowski
  2018-06-01 12:30 ` Krzysztof Kozlowski
  2018-06-01 16:48 ` Khem Raj
  0 siblings, 2 replies; 4+ messages in thread
From: Krzysztof Kozlowski @ 2018-06-01 12:06 UTC (permalink / raw)
  To: openembedded-devel

Add new recipe for lshw B.02.18 version - a small tool to provide
detailed information on the hardware configuration of the machine.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>

---

The recipe is based on existing meta-linaro:
https://layers.openembedded.org/layerindex/recipe/5446/

with changes:
1. Bump to 02.18,
2. Fix QA issue with GNU_HASH,
3. Minor recipe styling fixes.
---
 ...e-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch | 33 ++++++++++++++++++
 .../lshw/files/cross-compile.patch                 | 39 ++++++++++++++++++++++
 meta-oe/recipes-devtools/lshw/lshw_02.18.bb        | 37 ++++++++++++++++++++
 3 files changed, 109 insertions(+)
 create mode 100644 meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
 create mode 100644 meta-oe/recipes-devtools/lshw/files/cross-compile.patch
 create mode 100644 meta-oe/recipes-devtools/lshw/lshw_02.18.bb

diff --git a/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
new file mode 100644
index 000000000000..627619fd137f
--- /dev/null
+++ b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
@@ -0,0 +1,33 @@
+From 2f69ba75608619ba7fc962b1a0338682b644a406 Mon Sep 17 00:00:00 2001
+From: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
+Date: Thu, 31 May 2018 16:22:23 +0200
+Subject: [PATCH] Makefile: Use supplied LDFLAGS to silence OE GNU_HASH QA
+ warning
+
+Fix OpenEmbedded/Yocto QA warning:
+
+    ERROR: lshw-02.16-r1 do_package_qa: QA Issue: No GNU_HASH in the elf binary: 'build/tmp/work/cortexa5hf-neon-poky-linux-gnueabi/lshw/02.16-r1/packages-split/lshw/usr/sbin/lshw' [ldflags]
+    ERROR: lshw-02.16-r1 do_package_qa: QA run found fatal errors. Please consider fixing them.
+    ERROR: lshw-02.16-r1 do_package_qa: Function failed: do_package_qa
+
+Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
+---
+ src/Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index f474ff9d56b3..dd7a2a400be2 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -25,7 +25,7 @@ CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
+ ifeq ($(SQLITE), 1)
+ 	CXXFLAGS+= -DSQLITE $(shell pkg-config --cflags sqlite3)
+ endif
+-LDFLAGS=-L./core/ -g
++LDFLAGS+=-L./core/ -g
+ ifneq ($(shell $(LD) --help 2| grep -- --as-needed), )
+ 	LDFLAGS+= -Wl,--as-needed
+ endif
+-- 
+2.7.4
+
diff --git a/meta-oe/recipes-devtools/lshw/files/cross-compile.patch b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
new file mode 100644
index 000000000000..221b7e538c00
--- /dev/null
+++ b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
@@ -0,0 +1,39 @@
+---
+ src/Makefile      |    2 +-
+ src/core/Makefile |    2 +-
+ src/gui/Makefile  |    4 ++--
+ 3 files changed, 4 insertions(+), 4 deletions(-)
+
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -18,7 +18,7 @@ export MANDIR
+ export DATADIR
+ export SQLITE
+ 
+-CXX?=c++
++CXX?=$(CROSS_COMPILE)c++
+ INCLUDES=-I./core/
+ DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
+ CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
+--- a/src/core/Makefile
++++ b/src/core/Makefile
+@@ -1,6 +1,6 @@
+ PACKAGENAME?=lshw
+ 
+-CXX=c++
++CXX?=$(CROSS_COMPILE)c++
+ INCLUDES=
+ DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
+ CXXFLAGS?=-g -Wall $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
+--- a/src/gui/Makefile
++++ b/src/gui/Makefile
+@@ -1,7 +1,7 @@
+ PACKAGENAME?=lshw
+ 
+-CXX?=c++
+-CC?=cc
++CXX?=$(CROSS_COMPILE)c++
++CC?=$(CROSS_COMPILE)cc
+ STRIP?=strip
+ OBJCOPY?=objcopy
+ 
diff --git a/meta-oe/recipes-devtools/lshw/lshw_02.18.bb b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
new file mode 100644
index 000000000000..aac6707fcea4
--- /dev/null
+++ b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
@@ -0,0 +1,37 @@
+DESCRIPTION = "A small tool to provide detailed information on the hardware \
+configuration of the machine. It can report exact memory configuration, \
+firmware version, mainboard configuration, CPU version and speed, cache \
+configuration, bus speed, etc. on DMI-capable or EFI systems."
+SUMMARY = "Hardware lister"
+HOMEPAGE = "http://ezix.org/project/wiki/HardwareLiSter"
+SECTION = "console/tools"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+DEPENDS = " \
+    pciutils \
+    usbutils \
+"
+COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
+
+SRC_URI = " \
+    http://ezix.org/software/files/lshw-B.${PV}.tar.gz \
+    file://cross-compile.patch \
+    file://0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch \
+"
+SRC_URI[md5sum] = "8671c6d94d6324a744b7f21f1bfecfd2"
+SRC_URI[sha256sum] = "ae22ef11c934364be4fd2a0a1a7aadf4495a0251ec6979da280d342a89ca3c2f"
+
+S = "${WORKDIR}/lshw-B.${PV}"
+
+do_compile() {
+    # build core only - don't ship gui
+    oe_runmake -C src core
+}
+
+do_install() {
+    oe_runmake install DESTDIR=${D}
+    # data files provided by dependencies
+    rm -rf ${D}/usr/share/lshw
+}
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [meta-oe][PATCH] lshw: Add new recipe with B.02.18 version
  2018-06-01 12:06 [meta-oe][PATCH] lshw: Add new recipe with B.02.18 version Krzysztof Kozlowski
@ 2018-06-01 12:30 ` Krzysztof Kozlowski
  2018-06-01 16:48 ` Khem Raj
  1 sibling, 0 replies; 4+ messages in thread
From: Krzysztof Kozlowski @ 2018-06-01 12:30 UTC (permalink / raw)
  To: openembedded-devel

+Cc: Fathi Boudra <fathi.boudra@linaro.org>

On Fri, Jun 1, 2018 at 2:06 PM, Krzysztof Kozlowski <krzk@kernel.org> wrote:
> Add new recipe for lshw B.02.18 version - a small tool to provide
> detailed information on the hardware configuration of the machine.
>
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>
> ---
>
> The recipe is based on existing meta-linaro:
> https://layers.openembedded.org/layerindex/recipe/5446/
>
> with changes:
> 1. Bump to 02.18,
> 2. Fix QA issue with GNU_HASH,
> 3. Minor recipe styling fixes.
> ---
>  ...e-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch | 33 ++++++++++++++++++
>  .../lshw/files/cross-compile.patch                 | 39 ++++++++++++++++++++++
>  meta-oe/recipes-devtools/lshw/lshw_02.18.bb        | 37 ++++++++++++++++++++
>  3 files changed, 109 insertions(+)
>  create mode 100644 meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
>  create mode 100644 meta-oe/recipes-devtools/lshw/files/cross-compile.patch
>  create mode 100644 meta-oe/recipes-devtools/lshw/lshw_02.18.bb
>
> diff --git a/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
> new file mode 100644
> index 000000000000..627619fd137f
> --- /dev/null
> +++ b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
> @@ -0,0 +1,33 @@
> +From 2f69ba75608619ba7fc962b1a0338682b644a406 Mon Sep 17 00:00:00 2001
> +From: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
> +Date: Thu, 31 May 2018 16:22:23 +0200
> +Subject: [PATCH] Makefile: Use supplied LDFLAGS to silence OE GNU_HASH QA
> + warning
> +
> +Fix OpenEmbedded/Yocto QA warning:
> +
> +    ERROR: lshw-02.16-r1 do_package_qa: QA Issue: No GNU_HASH in the elf binary: 'build/tmp/work/cortexa5hf-neon-poky-linux-gnueabi/lshw/02.16-r1/packages-split/lshw/usr/sbin/lshw' [ldflags]
> +    ERROR: lshw-02.16-r1 do_package_qa: QA run found fatal errors. Please consider fixing them.
> +    ERROR: lshw-02.16-r1 do_package_qa: Function failed: do_package_qa
> +
> +Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
> +---
> + src/Makefile | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/src/Makefile b/src/Makefile
> +index f474ff9d56b3..dd7a2a400be2 100644
> +--- a/src/Makefile
> ++++ b/src/Makefile
> +@@ -25,7 +25,7 @@ CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
> + ifeq ($(SQLITE), 1)
> +       CXXFLAGS+= -DSQLITE $(shell pkg-config --cflags sqlite3)
> + endif
> +-LDFLAGS=-L./core/ -g
> ++LDFLAGS+=-L./core/ -g
> + ifneq ($(shell $(LD) --help 2| grep -- --as-needed), )
> +       LDFLAGS+= -Wl,--as-needed
> + endif
> +--
> +2.7.4
> +
> diff --git a/meta-oe/recipes-devtools/lshw/files/cross-compile.patch b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
> new file mode 100644
> index 000000000000..221b7e538c00
> --- /dev/null
> +++ b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
> @@ -0,0 +1,39 @@
> +---
> + src/Makefile      |    2 +-
> + src/core/Makefile |    2 +-
> + src/gui/Makefile  |    4 ++--
> + 3 files changed, 4 insertions(+), 4 deletions(-)
> +
> +--- a/src/Makefile
> ++++ b/src/Makefile
> +@@ -18,7 +18,7 @@ export MANDIR
> + export DATADIR
> + export SQLITE
> +
> +-CXX?=c++
> ++CXX?=$(CROSS_COMPILE)c++
> + INCLUDES=-I./core/
> + DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
> + CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
> +--- a/src/core/Makefile
> ++++ b/src/core/Makefile
> +@@ -1,6 +1,6 @@
> + PACKAGENAME?=lshw
> +
> +-CXX=c++
> ++CXX?=$(CROSS_COMPILE)c++
> + INCLUDES=
> + DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
> + CXXFLAGS?=-g -Wall $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
> +--- a/src/gui/Makefile
> ++++ b/src/gui/Makefile
> +@@ -1,7 +1,7 @@
> + PACKAGENAME?=lshw
> +
> +-CXX?=c++
> +-CC?=cc
> ++CXX?=$(CROSS_COMPILE)c++
> ++CC?=$(CROSS_COMPILE)cc
> + STRIP?=strip
> + OBJCOPY?=objcopy
> +
> diff --git a/meta-oe/recipes-devtools/lshw/lshw_02.18.bb b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
> new file mode 100644
> index 000000000000..aac6707fcea4
> --- /dev/null
> +++ b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
> @@ -0,0 +1,37 @@
> +DESCRIPTION = "A small tool to provide detailed information on the hardware \
> +configuration of the machine. It can report exact memory configuration, \
> +firmware version, mainboard configuration, CPU version and speed, cache \
> +configuration, bus speed, etc. on DMI-capable or EFI systems."
> +SUMMARY = "Hardware lister"
> +HOMEPAGE = "http://ezix.org/project/wiki/HardwareLiSter"
> +SECTION = "console/tools"
> +
> +LICENSE = "GPLv2+"
> +LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
> +
> +DEPENDS = " \
> +    pciutils \
> +    usbutils \
> +"
> +COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
> +
> +SRC_URI = " \
> +    http://ezix.org/software/files/lshw-B.${PV}.tar.gz \
> +    file://cross-compile.patch \
> +    file://0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch \
> +"
> +SRC_URI[md5sum] = "8671c6d94d6324a744b7f21f1bfecfd2"
> +SRC_URI[sha256sum] = "ae22ef11c934364be4fd2a0a1a7aadf4495a0251ec6979da280d342a89ca3c2f"
> +
> +S = "${WORKDIR}/lshw-B.${PV}"
> +
> +do_compile() {
> +    # build core only - don't ship gui
> +    oe_runmake -C src core
> +}
> +
> +do_install() {
> +    oe_runmake install DESTDIR=${D}
> +    # data files provided by dependencies
> +    rm -rf ${D}/usr/share/lshw
> +}
> --
> 2.7.4
>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [meta-oe][PATCH] lshw: Add new recipe with B.02.18 version
  2018-06-01 12:06 [meta-oe][PATCH] lshw: Add new recipe with B.02.18 version Krzysztof Kozlowski
  2018-06-01 12:30 ` Krzysztof Kozlowski
@ 2018-06-01 16:48 ` Khem Raj
  2018-06-04  8:00   ` Krzysztof Kozlowski
  1 sibling, 1 reply; 4+ messages in thread
From: Khem Raj @ 2018-06-01 16:48 UTC (permalink / raw)
  To: Krzysztof Kozlowski, openembedded-devel


[-- Attachment #1.1: Type: text/plain, Size: 5919 bytes --]

Hi Krzysztof

On 6/1/18 5:06 AM, Krzysztof Kozlowski wrote:
> Add new recipe for lshw B.02.18 version - a small tool to provide
> detailed information on the hardware configuration of the machine.
> 
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
> 
> ---
> 
> The recipe is based on existing meta-linaro:
> https://layers.openembedded.org/layerindex/recipe/5446/
> 
> with changes:
> 1. Bump to 02.18,
> 2. Fix QA issue with GNU_HASH,
> 3. Minor recipe styling fixes.
> ---
>  ...e-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch | 33 ++++++++++++++++++
>  .../lshw/files/cross-compile.patch                 | 39 ++++++++++++++++++++++
>  meta-oe/recipes-devtools/lshw/lshw_02.18.bb        | 37 ++++++++++++++++++++
>  3 files changed, 109 insertions(+)
>  create mode 100644 meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
>  create mode 100644 meta-oe/recipes-devtools/lshw/files/cross-compile.patch
>  create mode 100644 meta-oe/recipes-devtools/lshw/lshw_02.18.bb
> 
> diff --git a/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
> new file mode 100644
> index 000000000000..627619fd137f
> --- /dev/null
> +++ b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
> @@ -0,0 +1,33 @@
> +From 2f69ba75608619ba7fc962b1a0338682b644a406 Mon Sep 17 00:00:00 2001
> +From: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
> +Date: Thu, 31 May 2018 16:22:23 +0200
> +Subject: [PATCH] Makefile: Use supplied LDFLAGS to silence OE GNU_HASH QA
> + warning
> +
> +Fix OpenEmbedded/Yocto QA warning:
> +
> +    ERROR: lshw-02.16-r1 do_package_qa: QA Issue: No GNU_HASH in the elf binary: 'build/tmp/work/cortexa5hf-neon-poky-linux-gnueabi/lshw/02.16-r1/packages-split/lshw/usr/sbin/lshw' [ldflags]
> +    ERROR: lshw-02.16-r1 do_package_qa: QA run found fatal errors. Please consider fixing them.
> +    ERROR: lshw-02.16-r1 do_package_qa: Function failed: do_package_qa
> +
> +Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
> +---
> + src/Makefile | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/src/Makefile b/src/Makefile
> +index f474ff9d56b3..dd7a2a400be2 100644
> +--- a/src/Makefile
> ++++ b/src/Makefile
> +@@ -25,7 +25,7 @@ CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
> + ifeq ($(SQLITE), 1)
> + 	CXXFLAGS+= -DSQLITE $(shell pkg-config --cflags sqlite3)
> + endif
> +-LDFLAGS=-L./core/ -g
> ++LDFLAGS+=-L./core/ -g
> + ifneq ($(shell $(LD) --help 2| grep -- --as-needed), )
> + 	LDFLAGS+= -Wl,--as-needed
> + endif
> +-- 
> +2.7.4
> +
> diff --git a/meta-oe/recipes-devtools/lshw/files/cross-compile.patch b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
> new file mode 100644
> index 000000000000..221b7e538c00
> --- /dev/null
> +++ b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
> @@ -0,0 +1,39 @@
> +---
> + src/Makefile      |    2 +-
> + src/core/Makefile |    2 +-
> + src/gui/Makefile  |    4 ++--
> + 3 files changed, 4 insertions(+), 4 deletions(-)
> +
> +--- a/src/Makefile
> ++++ b/src/Makefile
> +@@ -18,7 +18,7 @@ export MANDIR
> + export DATADIR
> + export SQLITE
> + 
> +-CXX?=c++
> ++CXX?=$(CROSS_COMPILE)c++
> + INCLUDES=-I./core/
> + DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
> + CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
> +--- a/src/core/Makefile
> ++++ b/src/core/Makefile
> +@@ -1,6 +1,6 @@
> + PACKAGENAME?=lshw
> + 
> +-CXX=c++
> ++CXX?=$(CROSS_COMPILE)c++
> + INCLUDES=
> + DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
> + CXXFLAGS?=-g -Wall $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
> +--- a/src/gui/Makefile
> ++++ b/src/gui/Makefile
> +@@ -1,7 +1,7 @@
> + PACKAGENAME?=lshw
> + 
> +-CXX?=c++
> +-CC?=cc
> ++CXX?=$(CROSS_COMPILE)c++
> ++CC?=$(CROSS_COMPILE)cc
> + STRIP?=strip
> + OBJCOPY?=objcopy
> + 
> diff --git a/meta-oe/recipes-devtools/lshw/lshw_02.18.bb b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
> new file mode 100644
> index 000000000000..aac6707fcea4
> --- /dev/null
> +++ b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
> @@ -0,0 +1,37 @@
> +DESCRIPTION = "A small tool to provide detailed information on the hardware \
> +configuration of the machine. It can report exact memory configuration, \
> +firmware version, mainboard configuration, CPU version and speed, cache \
> +configuration, bus speed, etc. on DMI-capable or EFI systems."
> +SUMMARY = "Hardware lister"
> +HOMEPAGE = "http://ezix.org/project/wiki/HardwareLiSter"
> +SECTION = "console/tools"
> +
> +LICENSE = "GPLv2+"
> +LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
> +
> +DEPENDS = " \
> +    pciutils \
> +    usbutils \
> +"
> +COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
> +
> +SRC_URI = " \
> +    http://ezix.org/software/files/lshw-B.${PV}.tar.gz \
> +    file://cross-compile.patch \
> +    file://0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch \
> +"
> +SRC_URI[md5sum] = "8671c6d94d6324a744b7f21f1bfecfd2"
> +SRC_URI[sha256sum] = "ae22ef11c934364be4fd2a0a1a7aadf4495a0251ec6979da280d342a89ca3c2f"
> +
> +S = "${WORKDIR}/lshw-B.${PV}"
> +
> +do_compile() {
> +    # build core only - don't ship gui
> +    oe_runmake -C src core
> +}
> +
> +do_install() {
> +    oe_runmake install DESTDIR=${D}
> +    # data files provided by dependencies
> +    rm -rf ${D}/usr/share/lshw

who should be providing these files ?
should these packages be in rrecommends for this to work effectively ?

> +}
> 



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 201 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [meta-oe][PATCH] lshw: Add new recipe with B.02.18 version
  2018-06-01 16:48 ` Khem Raj
@ 2018-06-04  8:00   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 4+ messages in thread
From: Krzysztof Kozlowski @ 2018-06-04  8:00 UTC (permalink / raw)
  To: Khem Raj; +Cc: openembedded-devel

On Fri, Jun 1, 2018 at 6:48 PM, Khem Raj <raj.khem@gmail.com> wrote:
> Hi Krzysztof
>
> On 6/1/18 5:06 AM, Krzysztof Kozlowski wrote:
>> Add new recipe for lshw B.02.18 version - a small tool to provide
>> detailed information on the hardware configuration of the machine.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
>>
>> ---
>>
>> The recipe is based on existing meta-linaro:
>> https://layers.openembedded.org/layerindex/recipe/5446/
>>
>> with changes:
>> 1. Bump to 02.18,
>> 2. Fix QA issue with GNU_HASH,
>> 3. Minor recipe styling fixes.
>> ---
>>  ...e-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch | 33 ++++++++++++++++++
>>  .../lshw/files/cross-compile.patch                 | 39 ++++++++++++++++++++++
>>  meta-oe/recipes-devtools/lshw/lshw_02.18.bb        | 37 ++++++++++++++++++++
>>  3 files changed, 109 insertions(+)
>>  create mode 100644 meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
>>  create mode 100644 meta-oe/recipes-devtools/lshw/files/cross-compile.patch
>>  create mode 100644 meta-oe/recipes-devtools/lshw/lshw_02.18.bb
>>
>> diff --git a/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
>> new file mode 100644
>> index 000000000000..627619fd137f
>> --- /dev/null
>> +++ b/meta-oe/recipes-devtools/lshw/files/0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch
>> @@ -0,0 +1,33 @@
>> +From 2f69ba75608619ba7fc962b1a0338682b644a406 Mon Sep 17 00:00:00 2001
>> +From: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
>> +Date: Thu, 31 May 2018 16:22:23 +0200
>> +Subject: [PATCH] Makefile: Use supplied LDFLAGS to silence OE GNU_HASH QA
>> + warning
>> +
>> +Fix OpenEmbedded/Yocto QA warning:
>> +
>> +    ERROR: lshw-02.16-r1 do_package_qa: QA Issue: No GNU_HASH in the elf binary: 'build/tmp/work/cortexa5hf-neon-poky-linux-gnueabi/lshw/02.16-r1/packages-split/lshw/usr/sbin/lshw' [ldflags]
>> +    ERROR: lshw-02.16-r1 do_package_qa: QA run found fatal errors. Please consider fixing them.
>> +    ERROR: lshw-02.16-r1 do_package_qa: Function failed: do_package_qa
>> +
>> +Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@proceq.com>
>> +---
>> + src/Makefile | 2 +-
>> + 1 file changed, 1 insertion(+), 1 deletion(-)
>> +
>> +diff --git a/src/Makefile b/src/Makefile
>> +index f474ff9d56b3..dd7a2a400be2 100644
>> +--- a/src/Makefile
>> ++++ b/src/Makefile
>> +@@ -25,7 +25,7 @@ CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
>> + ifeq ($(SQLITE), 1)
>> +     CXXFLAGS+= -DSQLITE $(shell pkg-config --cflags sqlite3)
>> + endif
>> +-LDFLAGS=-L./core/ -g
>> ++LDFLAGS+=-L./core/ -g
>> + ifneq ($(shell $(LD) --help 2| grep -- --as-needed), )
>> +     LDFLAGS+= -Wl,--as-needed
>> + endif
>> +--
>> +2.7.4
>> +
>> diff --git a/meta-oe/recipes-devtools/lshw/files/cross-compile.patch b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
>> new file mode 100644
>> index 000000000000..221b7e538c00
>> --- /dev/null
>> +++ b/meta-oe/recipes-devtools/lshw/files/cross-compile.patch
>> @@ -0,0 +1,39 @@
>> +---
>> + src/Makefile      |    2 +-
>> + src/core/Makefile |    2 +-
>> + src/gui/Makefile  |    4 ++--
>> + 3 files changed, 4 insertions(+), 4 deletions(-)
>> +
>> +--- a/src/Makefile
>> ++++ b/src/Makefile
>> +@@ -18,7 +18,7 @@ export MANDIR
>> + export DATADIR
>> + export SQLITE
>> +
>> +-CXX?=c++
>> ++CXX?=$(CROSS_COMPILE)c++
>> + INCLUDES=-I./core/
>> + DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
>> + CXXFLAGS=-g -Wall -g $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
>> +--- a/src/core/Makefile
>> ++++ b/src/core/Makefile
>> +@@ -1,6 +1,6 @@
>> + PACKAGENAME?=lshw
>> +
>> +-CXX=c++
>> ++CXX?=$(CROSS_COMPILE)c++
>> + INCLUDES=
>> + DEFINES=-DPREFIX=\"$(PREFIX)\" -DSBINDIR=\"$(SBINDIR)\" -DMANDIR=\"$(MANDIR)\" -DDATADIR=\"$(DATADIR)\"
>> + CXXFLAGS?=-g -Wall $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
>> +--- a/src/gui/Makefile
>> ++++ b/src/gui/Makefile
>> +@@ -1,7 +1,7 @@
>> + PACKAGENAME?=lshw
>> +
>> +-CXX?=c++
>> +-CC?=cc
>> ++CXX?=$(CROSS_COMPILE)c++
>> ++CC?=$(CROSS_COMPILE)cc
>> + STRIP?=strip
>> + OBJCOPY?=objcopy
>> +
>> diff --git a/meta-oe/recipes-devtools/lshw/lshw_02.18.bb b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
>> new file mode 100644
>> index 000000000000..aac6707fcea4
>> --- /dev/null
>> +++ b/meta-oe/recipes-devtools/lshw/lshw_02.18.bb
>> @@ -0,0 +1,37 @@
>> +DESCRIPTION = "A small tool to provide detailed information on the hardware \
>> +configuration of the machine. It can report exact memory configuration, \
>> +firmware version, mainboard configuration, CPU version and speed, cache \
>> +configuration, bus speed, etc. on DMI-capable or EFI systems."
>> +SUMMARY = "Hardware lister"
>> +HOMEPAGE = "http://ezix.org/project/wiki/HardwareLiSter"
>> +SECTION = "console/tools"
>> +
>> +LICENSE = "GPLv2+"
>> +LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
>> +
>> +DEPENDS = " \
>> +    pciutils \
>> +    usbutils \
>> +"
>> +COMPATIBLE_HOST = "(i.86|x86_64|arm|aarch64).*-linux"
>> +
>> +SRC_URI = " \
>> +    http://ezix.org/software/files/lshw-B.${PV}.tar.gz \
>> +    file://cross-compile.patch \
>> +    file://0001-Makefile-Use-supplied-LDFLAGS-to-silence-OE-GNU_HASH.patch \
>> +"
>> +SRC_URI[md5sum] = "8671c6d94d6324a744b7f21f1bfecfd2"
>> +SRC_URI[sha256sum] = "ae22ef11c934364be4fd2a0a1a7aadf4495a0251ec6979da280d342a89ca3c2f"
>> +
>> +S = "${WORKDIR}/lshw-B.${PV}"
>> +
>> +do_compile() {
>> +    # build core only - don't ship gui
>> +    oe_runmake -C src core
>> +}
>> +
>> +do_install() {
>> +    oe_runmake install DESTDIR=${D}
>> +    # data files provided by dependencies
>> +    rm -rf ${D}/usr/share/lshw
>
> who should be providing these files ?
> should these packages be in rrecommends for this to work effectively ?

Thanks for catching this. They were indeed missing in the image. I can
add all of them as RDEPENDS or maybe as PACKAGECONFIG and then
customize the install with check for respective dependencies. I think
I will go with the second as it gives greater flexibility.

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-06-04  8:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-01 12:06 [meta-oe][PATCH] lshw: Add new recipe with B.02.18 version Krzysztof Kozlowski
2018-06-01 12:30 ` Krzysztof Kozlowski
2018-06-01 16:48 ` Khem Raj
2018-06-04  8:00   ` Krzysztof Kozlowski

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.