All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ryan Eatmon <reatmon@ti.com>
To: Praneeth Bajjuri <praneeth@ti.com>,
	Denys Dmytriyenko <denys@konsulko.com>,
	<meta-ti@lists.yoctoproject.org>
Subject: [meta-ti][master][PATCH] libulm: Fix "buildpaths" QA error
Date: Fri, 19 Jul 2024 15:36:03 -0500	[thread overview]
Message-ID: <20240719203603.21930-1-reatmon@ti.com> (raw)

The TI cl6x compiler does not have a mechanism for replacing paths in
the obj files it creates.  So replace the string we want to remove with
an equally sized replacement string that does not contain the path.

Signed-off-by: Ryan Eatmon <reatmon@ti.com>
---
 ...m-makefile-Fix-reproducibility-error.patch | 31 +++++++++++++++++++
 .../recipes-bsp/dsptop/libulm_git.bb          | 12 +++++--
 2 files changed, 41 insertions(+), 2 deletions(-)
 create mode 100644 meta-ti-extras/recipes-bsp/dsptop/files/0001-dstop-ulm-makefile-Fix-reproducibility-error.patch

diff --git a/meta-ti-extras/recipes-bsp/dsptop/files/0001-dstop-ulm-makefile-Fix-reproducibility-error.patch b/meta-ti-extras/recipes-bsp/dsptop/files/0001-dstop-ulm-makefile-Fix-reproducibility-error.patch
new file mode 100644
index 00000000..6ea59517
--- /dev/null
+++ b/meta-ti-extras/recipes-bsp/dsptop/files/0001-dstop-ulm-makefile-Fix-reproducibility-error.patch
@@ -0,0 +1,31 @@
+From 8619e4b2f983130bf1909cc9c9bc238cd43ded41 Mon Sep 17 00:00:00 2001
+From: Ryan Eatmon <reatmon@ti.com>
+Date: Fri, 19 Jul 2024 14:37:55 -0500
+Subject: [master][PATCH] dstop/ulm/makefile: Fix reproducibility error
+
+The TI cl6x compiler does not have a mechanism for replacing paths in
+the obj files it creates.  So replace the string we want to remove with
+an equally sized replacement string that does not contain the path.
+
+Upstream-Status: Inappropriate [OE-specific]
+
+Signed-off-by: Ryan Eatmon <reatmon@ti.com>
+---
+ makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/makefile b/makefile
+index dffb211..586dcc2 100644
+--- a/makefile
++++ b/makefile
+@@ -82,6 +82,7 @@ $(OBJDIR)/%.obj: %.c $(INCLUDE_FILES)
+ 	@echo "Compiling" $<
+ 	@mkdir -p $(OBJDIR)
+ 	$(CC) $(CFLAGS) $(INCLUDE_PATH) -fe $@ $<
++	perl -pi -e 's#${SEARCH}#${REPLACE}#g' $@
+ 
+ libtiulm.a libtiulm.ae66: $(OBJECTS)
+ 	@echo "Building target" $@
+-- 
+2.17.1
+
diff --git a/meta-ti-extras/recipes-bsp/dsptop/libulm_git.bb b/meta-ti-extras/recipes-bsp/dsptop/libulm_git.bb
index 6a2cde30..aafae21f 100644
--- a/meta-ti-extras/recipes-bsp/dsptop/libulm_git.bb
+++ b/meta-ti-extras/recipes-bsp/dsptop/libulm_git.bb
@@ -6,7 +6,7 @@ inherit features_check
 
 REQUIRED_MACHINE_FEATURES = "dsp"
 
-DEPENDS = "ti-cgt6x-native"
+DEPENDS = "ti-cgt6x-native perl-native"
 PR = "${INC_PR}.0"
 
 S = "${WORKDIR}/git/dsptop/ulm"
@@ -14,7 +14,13 @@ S = "${WORKDIR}/git/dsptop/ulm"
 DEVICE=""
 DEVICE:dra7xx = "DRA7xx"
 
-EXTRA_OEMAKE = "release DEVICE=${DEVICE} CROSS_COMPILE=${TARGET_PREFIX}"
+EXTRA_OEMAKE = " \
+    release \
+    DEVICE=${DEVICE} \
+    CROSS_COMPILE=${TARGET_PREFIX} \
+    SEARCH=${WORKDIR} \
+    REPLACE=${@'_'*(len(d.getVar('WORKDIR'))-7)+"workdir"} \
+"
 
 do_compile() {
     oe_runmake arm XPORT_ONLY CC="${CC}"
@@ -40,6 +46,8 @@ FILES:${PN}-dev += "\
 
 include dsptop.inc
 
+SRC_URI += "file://0001-dstop-ulm-makefile-Fix-reproducibility-error.patch"
+
 ALLOW_EMPTY:${PN} = "1"
 
 PARALLEL_MAKE= ""
-- 
2.17.1



             reply	other threads:[~2024-07-19 20:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-19 20:36 Ryan Eatmon [this message]
2024-07-20 18:02 ` [meta-ti][master][PATCH] libulm: Fix "buildpaths" QA error Denys Dmytriyenko
     [not found] ` <17E3FDCA0923C85A.21127@lists.yoctoproject.org>
2024-07-20 18:25   ` Denys Dmytriyenko

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=20240719203603.21930-1-reatmon@ti.com \
    --to=reatmon@ti.com \
    --cc=denys@konsulko.com \
    --cc=meta-ti@lists.yoctoproject.org \
    --cc=praneeth@ti.com \
    /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 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.