All of lore.kernel.org
 help / color / mirror / Atom feed
From: joel at jms.id.au (Joel Stanley)
Subject: [PATCH 3/6] selftests: powerpc/ptrace: Fix linking against pthread
Date: Tue, 23 Oct 2018 16:46:54 +1030	[thread overview]
Message-ID: <20181023061657.18007-4-joel@jms.id.au> (raw)
In-Reply-To: <20181023061657.18007-1-joel@jms.id.au>

Some of the ptrace tests require -ptrace when linking:

 /usr/bin/ld: /tmp/ccH32S9w.o: in function `init_child_sync':
 core-pkey.c:(.text+0x1d64): undefined reference to `sem_init'

The targets for these tests are modfied in lib.mk to add the $(OUTPUT)
prefix. The makefile needs to specify that modifying those rules, or
else they do not match and we miss out on the extra flags.

Signed-off-by: Joel Stanley <joel at jms.id.au>
---
 tools/testing/selftests/powerpc/ptrace/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/testing/selftests/powerpc/ptrace/Makefile b/tools/testing/selftests/powerpc/ptrace/Makefile
index 58de6d4a0cf4..8d3f006c98cc 100644
--- a/tools/testing/selftests/powerpc/ptrace/Makefile
+++ b/tools/testing/selftests/powerpc/ptrace/Makefile
@@ -9,7 +9,7 @@ include ../../lib.mk
 
 CFLAGS += -m64 -I../../../../../usr/include -I../tm -mhtm -fno-pie
 
-ptrace-pkey core-pkey: child.h
-ptrace-pkey core-pkey: LDLIBS += -pthread
+$(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: child.h
+$(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: LDLIBS += -pthread
 
 $(TEST_GEN_PROGS): ../harness.c ../utils.c ../lib/reg.S ptrace.h
-- 
2.19.1

WARNING: multiple messages have this Message-ID (diff)
From: joel@jms.id.au (Joel Stanley)
Subject: [PATCH 3/6] selftests: powerpc/ptrace: Fix linking against pthread
Date: Tue, 23 Oct 2018 16:46:54 +1030	[thread overview]
Message-ID: <20181023061657.18007-4-joel@jms.id.au> (raw)
Message-ID: <20181023061654.pjC3YLRV5f_zQPhQ7HXGUM1hQRXl8S_K6aHFExMeeMU@z> (raw)
In-Reply-To: <20181023061657.18007-1-joel@jms.id.au>

Some of the ptrace tests require -ptrace when linking:

 /usr/bin/ld: /tmp/ccH32S9w.o: in function `init_child_sync':
 core-pkey.c:(.text+0x1d64): undefined reference to `sem_init'

The targets for these tests are modfied in lib.mk to add the $(OUTPUT)
prefix. The makefile needs to specify that modifying those rules, or
else they do not match and we miss out on the extra flags.

Signed-off-by: Joel Stanley <joel at jms.id.au>
---
 tools/testing/selftests/powerpc/ptrace/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/testing/selftests/powerpc/ptrace/Makefile b/tools/testing/selftests/powerpc/ptrace/Makefile
index 58de6d4a0cf4..8d3f006c98cc 100644
--- a/tools/testing/selftests/powerpc/ptrace/Makefile
+++ b/tools/testing/selftests/powerpc/ptrace/Makefile
@@ -9,7 +9,7 @@ include ../../lib.mk
 
 CFLAGS += -m64 -I../../../../../usr/include -I../tm -mhtm -fno-pie
 
-ptrace-pkey core-pkey: child.h
-ptrace-pkey core-pkey: LDLIBS += -pthread
+$(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: child.h
+$(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: LDLIBS += -pthread
 
 $(TEST_GEN_PROGS): ../harness.c ../utils.c ../lib/reg.S ptrace.h
-- 
2.19.1

WARNING: multiple messages have this Message-ID (diff)
From: Joel Stanley <joel@jms.id.au>
To: linuxppc-dev@lists.ozlabs.org
Cc: linux-kselftest@vger.kernel.org
Subject: [PATCH 3/6] selftests: powerpc/ptrace: Fix linking against pthread
Date: Tue, 23 Oct 2018 16:46:54 +1030	[thread overview]
Message-ID: <20181023061657.18007-4-joel@jms.id.au> (raw)
In-Reply-To: <20181023061657.18007-1-joel@jms.id.au>

Some of the ptrace tests require -ptrace when linking:

 /usr/bin/ld: /tmp/ccH32S9w.o: in function `init_child_sync':
 core-pkey.c:(.text+0x1d64): undefined reference to `sem_init'

The targets for these tests are modfied in lib.mk to add the $(OUTPUT)
prefix. The makefile needs to specify that modifying those rules, or
else they do not match and we miss out on the extra flags.

Signed-off-by: Joel Stanley <joel@jms.id.au>
---
 tools/testing/selftests/powerpc/ptrace/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/testing/selftests/powerpc/ptrace/Makefile b/tools/testing/selftests/powerpc/ptrace/Makefile
index 58de6d4a0cf4..8d3f006c98cc 100644
--- a/tools/testing/selftests/powerpc/ptrace/Makefile
+++ b/tools/testing/selftests/powerpc/ptrace/Makefile
@@ -9,7 +9,7 @@ include ../../lib.mk
 
 CFLAGS += -m64 -I../../../../../usr/include -I../tm -mhtm -fno-pie
 
-ptrace-pkey core-pkey: child.h
-ptrace-pkey core-pkey: LDLIBS += -pthread
+$(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: child.h
+$(OUTPUT)/ptrace-pkey $(OUTPUT)/core-pkey: LDLIBS += -pthread
 
 $(TEST_GEN_PROGS): ../harness.c ../utils.c ../lib/reg.S ptrace.h
-- 
2.19.1


  parent reply	other threads:[~2018-10-23  6:16 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-23  6:16 [PATCH 0/6] selftests: powerpc build fixes joel
2018-10-23  6:16 ` Joel Stanley
2018-10-23  6:16 ` Joel Stanley
2018-10-23  6:16 ` [PATCH 1/6] selftests: powerpc/ptrace: Make tests build joel
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16 ` [PATCH 2/6] selftests: powerpc/ptrace: Remove clean rule joel
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16 ` joel [this message]
2018-10-23  6:16   ` [PATCH 3/6] selftests: powerpc/ptrace: Fix linking against pthread Joel Stanley
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16 ` [PATCH 4/6] selftests: powerpc/signal: Make tests build joel
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16 ` [PATCH 5/6] selftests: powerpc/signal: Fix signal_tm CFLAGS joel
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16 ` [PATCH 6/6] selftests: powerpc/pmu: Link ebb tests with -no-pie joel
2018-10-23  6:16   ` Joel Stanley
2018-10-23  6:16   ` Joel Stanley

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=20181023061657.18007-4-joel@jms.id.au \
    --to=unknown@example.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.