* [Buildroot] [git commit branch/2023.05.x] package/hwdata: install to staging
@ 2023-07-06 10:47 Peter Korsgaard
0 siblings, 0 replies; only message in thread
From: Peter Korsgaard @ 2023-07-06 10:47 UTC (permalink / raw)
To: buildroot
commit: https://git.buildroot.net/buildroot/commit/?id=6e537234e4a2a4c2d3c69c19d221e6f628f5558b
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/2023.05.x
hwdata provides a .pc file, which other packages can look up to find the
location where hwdata files are, and use them at build time.
This is the case for the upcoming libdisplay-info package, which
requires the hwdata's PNP IDs at build time.
However, installing the .pc file is not enough. Indeed, meson (which
libdisplay-info uses) will look for the corresponding data files in
datadir, which it locates relative to the sysroot, which is our staging.
So, we also need to install the hwdata files in staging.
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
(cherry picked from commit f36c57728aa43df2355db731d90712a5a29cc501)
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
---
package/hwdata/hwdata.mk | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/package/hwdata/hwdata.mk b/package/hwdata/hwdata.mk
index 755a9c93f1..cbac3a22d4 100644
--- a/package/hwdata/hwdata.mk
+++ b/package/hwdata/hwdata.mk
@@ -8,6 +8,7 @@ HWDATA_VERSION = 0.369
HWDATA_SITE = $(call github,vcrhonek,hwdata,v$(HWDATA_VERSION))
HWDATA_LICENSE = GPL-2.0+, BSD-3-Clause, XFree86 1.0
HWDATA_LICENSE_FILES = COPYING LICENSE
+HWDATA_INSTALL_STAGING = YES
HWDATA_FILES = \
$(if $(BR2_PACKAGE_HWDATA_IAB_OUI_TXT),iab.txt oui.txt) \
@@ -15,7 +16,22 @@ HWDATA_FILES = \
$(if $(BR2_PACKAGE_HWDATA_PNP_IDS),pnp.ids) \
$(if $(BR2_PACKAGE_HWDATA_USB_IDS),usb.ids)
+define HWDATA_CONFIGURE_CMDS
+ (cd $(@D); $(TARGET_CONFIGURE_OPTS) ./configure)
+endef
+
+define HWDATA_BUILD_CMDS
+ $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) hwdata.pc
+endef
+
ifneq ($(strip $(HWDATA_FILES)),)
+define HWDATA_INSTALL_STAGING_CMDS
+ $(INSTALL) -D -m 0644 $(@D)/hwdata.pc \
+ $(STAGING_DIR)/usr/lib/pkgconfig/hwdata.pc
+ $(INSTALL) -d -m 755 $(STAGING_DIR)/usr/share/hwdata
+ $(INSTALL) -m 644 -t $(STAGING_DIR)/usr/share/hwdata \
+ $(addprefix $(@D)/,$(HWDATA_FILES))
+endef
define HWDATA_INSTALL_TARGET_CMDS
$(INSTALL) -d -m 755 $(TARGET_DIR)/usr/share/hwdata
$(INSTALL) -m 644 -t $(TARGET_DIR)/usr/share/hwdata \
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2023-07-06 10:53 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-06 10:47 [Buildroot] [git commit branch/2023.05.x] package/hwdata: install to staging Peter Korsgaard
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.