* [PATCH 1/2] systemtap: Add patch to remove quotes
@ 2017-03-07 20:12 Saul Wold
2017-03-07 20:12 ` [PATCH 2/2] crosstap: Changes to support Recipe specific sysroot Saul Wold
0 siblings, 1 reply; 2+ messages in thread
From: Saul Wold @ 2017-03-07 20:12 UTC (permalink / raw)
To: openembedded-core, richard.purdie
This fixes the -I include lines that are getting passed to the
kernel macros
[YOCTO #10990]
Signed-off-by: Saul Wold <sgw@linux.intel.com>
---
...ldrun-remove-quotes-around-I-include-line.patch | 38 ++++++++++++++++++++++
meta/recipes-kernel/systemtap/systemtap_git.inc | 1 +
2 files changed, 39 insertions(+)
create mode 100644 meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch
diff --git a/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch b/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch
new file mode 100644
index 0000000..7996fdd
--- /dev/null
+++ b/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch
@@ -0,0 +1,38 @@
+From 75c4aec6de3a615909f3283eac585760de101b8c Mon Sep 17 00:00:00 2001
+From: Saul Wold <sgw@linux.intel.com>
+Date: Tue, 7 Mar 2017 10:46:12 -0800
+Subject: [PATCH] buildrun: remove quotes around -I include line
+
+By having the quotes, the kernel Makefile addtree macro adds the
+kernel $srctree directory as a prefix and causes compilation failures.
+Removing the quotes resolves the issue.
+
+This is trimmed from the verbose output of the GCC command line
+Before:
+ -I/srv/sdb/builds/4.9/tmp/work-shared/qemux86-64/kernel-source/"/srv/sdb/releases/jethro/builds/4.1/tmp/sysroots/x86_64-linux/usr/share/systemtap/runtime"
+
+After:
+ -I/srv/sdb/builds/4.9/tmp/sysroots/x86_64-linux/usr/share/systemtap/runtime
+
+Upstream-Status: Pending
+Signed-off-by: Saul Wold <sgw@linux.intel.com>
+---
+ buildrun.cxx | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/buildrun.cxx b/buildrun.cxx
+index aaea64c..8a8ee9f 100644
+--- a/buildrun.cxx
++++ b/buildrun.cxx
+@@ -495,7 +495,7 @@ compile_pass (systemtap_session& s)
+ #if CHECK_POINTER_ARITH_PR5947
+ o << "EXTRA_CFLAGS += -Wpointer-arith" << endl;
+ #endif
+- o << "EXTRA_CFLAGS += -I\"" << s.runtime_path << "\"" << endl;
++ o << "EXTRA_CFLAGS += -I" << s.runtime_path << endl;
+ // XXX: this may help ppc toc overflow
+ // o << "CFLAGS := $(subst -Os,-O2,$(CFLAGS)) -fminimal-toc" << endl;
+ o << "obj-m := " << s.module_name << ".o" << endl;
+--
+2.7.4
+
diff --git a/meta/recipes-kernel/systemtap/systemtap_git.inc b/meta/recipes-kernel/systemtap/systemtap_git.inc
index c961230..a6aedd3 100644
--- a/meta/recipes-kernel/systemtap/systemtap_git.inc
+++ b/meta/recipes-kernel/systemtap/systemtap_git.inc
@@ -11,6 +11,7 @@ SRC_URI = "git://sourceware.org/git/systemtap.git \
file://no-msgfmt-check.patch \
file://0001-Do-not-let-configure-write-a-python-location-into-th.patch \
file://0001-Install-python-modules-to-correct-library-dir.patch \
+ file://0001-buildrun-remove-quotes-around-I-include-line.patch \
"
# systemtap doesn't support mips
--
2.7.4
^ permalink raw reply related [flat|nested] 2+ messages in thread* [PATCH 2/2] crosstap: Changes to support Recipe specific sysroot
2017-03-07 20:12 [PATCH 1/2] systemtap: Add patch to remove quotes Saul Wold
@ 2017-03-07 20:12 ` Saul Wold
0 siblings, 0 replies; 2+ messages in thread
From: Saul Wold @ 2017-03-07 20:12 UTC (permalink / raw)
To: openembedded-core, richard.purdie
The crosstap script needed to be updated for recipe specific sysroot
changes including adding support for finding the systemtap binaries.
[YOCTO #10990]
Signed-off-by: Saul Wold <sgw@linux.intel.com>
---
scripts/crosstap | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/scripts/crosstap b/scripts/crosstap
index 58317cf..39739bb 100755
--- a/scripts/crosstap
+++ b/scripts/crosstap
@@ -104,13 +104,19 @@ STAGING_BINDIR_TOOLCHAIN=$(echo "$BITBAKE_VARS" | grep ^STAGING_BINDIR_TOOLCHAIN
| cut -d '=' -f2 | cut -d '"' -f2)
STAGING_BINDIR_TOOLPREFIX=$(echo "$BITBAKE_VARS" | grep ^TARGET_PREFIX \
| cut -d '=' -f2 | cut -d '"' -f2)
-SYSTEMTAP_HOST_INSTALLDIR=$(echo "$BITBAKE_VARS" | grep ^STAGING_DIR_NATIVE \
- | cut -d '=' -f2 | cut -d '"' -f2)
TARGET_ARCH=$(echo "$BITBAKE_VARS" | grep ^TRANSLATED_TARGET_ARCH \
| cut -d '=' -f2 | cut -d '"' -f2)
TARGET_KERNEL_BUILDDIR=$(echo "$BITBAKE_VARS" | grep ^B= \
| cut -d '=' -f2 | cut -d '"' -f2)
+# Build and populate the recipe-sysroot-native with systemtap-native
+pushd $PWD
+cd $BUILDDIR
+BITBAKE_VARS=`bitbake -e systemtap-native`
+popd
+SYSTEMTAP_HOST_INSTALLDIR=$(echo "$BITBAKE_VARS" | grep ^STAGING_DIR_NATIVE \
+ | cut -d '=' -f2 | cut -d '"' -f2)
+
systemtap_target_arch "$TARGET_ARCH"
if [ ! -d $TARGET_KERNEL_BUILDDIR ] ||
@@ -125,6 +131,7 @@ if [ ! -f $SYSTEMTAP_HOST_INSTALLDIR/usr/bin/stap ]; then
echo -e "\nError: Native (host) systemtap not found."
echo -e "Did you accidentally build a local non-sdk image? (or forget to"
echo -e "add 'tools-profile' to EXTRA_IMAGE_FEATURES in your local.conf)?"
+ echo -e "You can also: bitbake -c addto_recipe_sysroot systemtap-native"
setup_usage
exit 1
fi
--
2.7.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-03-07 20:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-07 20:12 [PATCH 1/2] systemtap: Add patch to remove quotes Saul Wold
2017-03-07 20:12 ` [PATCH 2/2] crosstap: Changes to support Recipe specific sysroot Saul Wold
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox