Skip to contentSkip to conversation

package/python-pyelftools: Add host variant

PATCH New Shyam Saini 2 participants 3 messages Apr 18, 2019 – Apr 20, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 package/python-pyelftools: Add host variant

This would be used by uboot for rockchip rk3399
socs boards.

---
 package/python-pyelftools/python-pyelftools.mk | 1 +
 1 file changed, 1 insertion(+)
package/python-pyelftools/python-pyelftools.mk +1 -0
index 5b5b488cf0..92dafbe27f 100644
@@ -12,3 +12,4 @@ PYTHON_PYELFTOOLS_LICENSE_FILES = LICENSE
 PYTHON_PYELFTOOLS_SETUP_TYPE = distutils
 
 $(eval $(python-package))
+$(eval $(host-python-package))
Signature · 1 line
2.11.0
#1 lore raw

PATCH 2/2 boot/uboot: Add python pyelftools library as uboot dependency

Rockchip rk3399 SOC based boards require python pyelftools library for parsing dtb files, so lets add it as uboot dependency.

This commit introduces new a variable BR2_TARGET_UBOOT_NEEDS_PYELFTOOLS to achieve this.

---
 boot/uboot/Config.in | 8 ++++++++
 boot/uboot/uboot.mk  | 4 ++++
 2 files changed, 12 insertions(+)
boot/uboot/Config.in +8 -0
index d4a93615ee..33b7e67ff7 100644
@@ -151,6 +151,14 @@ config BR2_TARGET_UBOOT_NEEDS_PYLIBFDT
 	  Select this option if your U-Boot board configuration
 	  requires the Python libfdt library to be available.
 
+config BR2_TARGET_UBOOT_NEEDS_PYELFTOOLS
+	bool "U-Boot needs pyelftools"
+	help
+	  Select this option if your U-Boot board configuration
+	  requires the Python pyelftools library to be available.
+	  This is used by some rockchip SOCs for elf parsing.
+	  For example: rk3399 soc boards.
+
 config BR2_TARGET_UBOOT_NEEDS_OPENSSL
 	bool "U-Boot needs OpenSSL"
 	help
boot/uboot/uboot.mk +4 -0
index 3c070b41b3..ae09c37d84 100644
@@ -152,6 +152,10 @@ ifeq ($(BR2_TARGET_UBOOT_NEEDS_PYLIBFDT),y)
 UBOOT_DEPENDENCIES += host-python host-swig
 endif
 
+ifeq ($(BR2_TARGET_UBOOT_NEEDS_PYELFTOOLS),y)
+UBOOT_DEPENDENCIES += host-python-pyelftools
+endif
+
 ifeq ($(BR2_TARGET_UBOOT_NEEDS_OPENSSL),y)
 UBOOT_DEPENDENCIES += host-openssl
 endif
Signature · 1 line
2.11.0
#2 lore raw

PATCH 1/2 package/python-pyelftools: Add host variant

In reply to Shyam Saini
Quoted 7 lines · On Thu, 18 Apr 2019 18:53:30 +0530 Shyam Saini…

This would be used by uboot for rockchip rk3399
socs boards.

---
 package/python-pyelftools/python-pyelftools.mk | 1 +
 1 file changed, 1 insertion(+)

Series applied to master. Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com