public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [PATCH 1/3] libgloss: package riscv header files correctly
@ 2026-03-11 14:12 Alejandro Hernandez Samaniego
  2026-03-11 14:30 ` Patchtest results for " patchtest
  0 siblings, 1 reply; 2+ messages in thread
From: Alejandro Hernandez Samaniego @ 2026-03-11 14:12 UTC (permalink / raw)
  To: openembedded-core; +Cc: Alejandro Hernandez Samaniego

Signed-off-by: Alejandro Hernandez Samaniego <alhe@linux.microsoft.com>
---
 meta/recipes-core/newlib/libgloss_git.bb | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-core/newlib/libgloss_git.bb b/meta/recipes-core/newlib/libgloss_git.bb
index 92bb81050b..0739651eed 100644
--- a/meta/recipes-core/newlib/libgloss_git.bb
+++ b/meta/recipes-core/newlib/libgloss_git.bb
@@ -23,9 +23,18 @@ do_install:append() {
 
         # Remove original directory
         rmdir -p --ignore-fail-on-non-empty ${D}${prefix}/${TARGET_SYS}/lib
-        # Remove empty include dir
-        rmdir ${D}/${prefix}/${TARGET_SYS}/include
-        rmdir ${D}/${prefix}/${TARGET_SYS}/
+
+        # RiscV machines install header files into ${D}/${prefix}/${TARGET_SYS}/include/machine
+        # move their contents into ${includedir}
+        if [ "$(ls -A ${D}/${prefix}/${TARGET_SYS}/include/machine 2>/dev/null)" ]; then
+              mkdir ${D}/${includedir}
+              mv ${D}/${prefix}/${TARGET_SYS}/include/machine/* ${D}/${includedir}
+              rmdir -p --ignore-fail-on-non-empty ${D}${prefix}/${TARGET_SYS}/include/machine
+        fi
+        if [ -d "${D}/${prefix}/${TARGET_SYS}/include" ]; then
+            rmdir -p --ignore-fail-on-non-empty ${D}${prefix}/${TARGET_SYS}/include
+        fi
+
 
 }
 
-- 
2.53.0



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

end of thread, other threads:[~2026-03-11 14:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-11 14:12 [PATCH 1/3] libgloss: package riscv header files correctly Alejandro Hernandez Samaniego
2026-03-11 14:30 ` Patchtest results for " patchtest

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox