| Submitter | Denys Dmytriyenko |
|---|---|
| Date | March 20, 2012, 12:22 a.m. |
| Message ID | <1332202974-27977-1-git-send-email-denis@denix.org> |
| Download | mbox | patch |
| Permalink | /patch/23839/ |
| State | New |
| Headers | show |
Comments
On 03/19/2012 05:22 PM, Denys Dmytriyenko wrote: > From: Denys Dmytriyenko <denys@ti.com> > > Replace dependency on eglibc with virtual/libc > Pass LDFLAGS to TARGET_CC_ARCH, instead of CFLAGS as Makefile overrides it > > Signed-off-by: Denys Dmytriyenko <denys@ti.com> Thanks Denys, Looking through the rt-tests sources I don't see TARGET_CC_ARCH anywhere. Have you confirmed that changes made there make their way into the actual build? What was the problem you ran into? -- Darren > --- > meta/recipes-rt/rt-tests/rt-tests_0.83.bb | 6 +++--- > 1 files changed, 3 insertions(+), 3 deletions(-) > > diff --git a/meta/recipes-rt/rt-tests/rt-tests_0.83.bb b/meta/recipes-rt/rt-tests/rt-tests_0.83.bb > index 6425027..3755c79 100644 > --- a/meta/recipes-rt/rt-tests/rt-tests_0.83.bb > +++ b/meta/recipes-rt/rt-tests/rt-tests_0.83.bb > @@ -1,7 +1,7 @@ > DESCRIPTION = "Real-Time preemption testcases" > HOMEPAGE = "https://rt.wiki.kernel.org/index.php/Cyclictest" > SECTION = "tests" > -DEPENDS = "linux-libc-headers eglibc" > +DEPENDS = "linux-libc-headers virtual/libc" > LICENSE = "GPLv2 & GPLv2+" > LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \ > file://src/cyclictest/cyclictest.c;beginline=7;endline=9;md5=ce162fe491d19d2ec67dff6dbc938d50 \ > @@ -11,13 +11,13 @@ SRCREV = "5f1e84f8b015df3ff950056494134eca3f640d70" > > # git -> 0.83 needs a PE bump > PE = "1" > -PR = "r1" > +PR = "r2" > > SRC_URI = "git://github.com/clrkwllms/rt-tests.git" > > S = "${WORKDIR}/git" > > -CFLAGS += "-I${S}/src/include -D_GNU_SOURCE -Wall -Wno-nonnulli ${LDFLAGS}" > +TARGET_CC_ARCH += "${LDFLAGS}" > > # calling 'uname -m' is broken on crossbuilds > EXTRA_OEMAKE = "NUMA=0"
Op 20 mrt. 2012, om 16:01 heeft Darren Hart het volgende geschreven: > > > On 03/19/2012 05:22 PM, Denys Dmytriyenko wrote: >> From: Denys Dmytriyenko <denys@ti.com> >> >> Replace dependency on eglibc with virtual/libc >> Pass LDFLAGS to TARGET_CC_ARCH, instead of CFLAGS as Makefile overrides it >> >> Signed-off-by: Denys Dmytriyenko <denys@ti.com> > > Thanks Denys, > > Looking through the rt-tests sources I don't see TARGET_CC_ARCH > anywhere. Have you confirmed that changes made there make their way into > the actual build? TARGET_CC_ARCH is an OE thing, it's is what ends up in $CC. regards, Koen
On Tue, Mar 20, 2012 at 08:01:44AM -0700, Darren Hart wrote: > > > On 03/19/2012 05:22 PM, Denys Dmytriyenko wrote: > > From: Denys Dmytriyenko <denys@ti.com> > > > > Replace dependency on eglibc with virtual/libc > > Pass LDFLAGS to TARGET_CC_ARCH, instead of CFLAGS as Makefile overrides it > > > > Signed-off-by: Denys Dmytriyenko <denys@ti.com> > > Thanks Denys, > > Looking through the rt-tests sources I don't see TARGET_CC_ARCH > anywhere. Have you confirmed that changes made there make their way into > the actual build? Darren, TARGET_CC_ARCH is not an rt-tests specific variable, it's used in OE. Although, TARGET_LDFLAGS might be more appropriate for this purpose, historically TARGET_CC_ARCH was heavily used to pass distro LDFLAGS to the app's build process - grepping it would show many such cases in OE-Core and especially in meta-oe... > What was the problem you ran into? Not a problem per se, but it was not getting all the LDFLAGS being passed, more specifically: -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed BTW, in Classic OE it was failing on GNU Hash QA check w/o this.
On 03/20/2012 08:28 AM, Denys Dmytriyenko wrote: > On Tue, Mar 20, 2012 at 08:01:44AM -0700, Darren Hart wrote: >> >> >> On 03/19/2012 05:22 PM, Denys Dmytriyenko wrote: >>> From: Denys Dmytriyenko <denys@ti.com> >>> >>> Replace dependency on eglibc with virtual/libc >>> Pass LDFLAGS to TARGET_CC_ARCH, instead of CFLAGS as Makefile overrides it >>> >>> Signed-off-by: Denys Dmytriyenko <denys@ti.com> >> >> Thanks Denys, >> >> Looking through the rt-tests sources I don't see TARGET_CC_ARCH >> anywhere. Have you confirmed that changes made there make their way into >> the actual build? > > Darren, > > TARGET_CC_ARCH is not an rt-tests specific variable, it's used in OE. > Although, TARGET_LDFLAGS might be more appropriate for this purpose, > historically TARGET_CC_ARCH was heavily used to pass distro LDFLAGS to the > app's build process - grepping it would show many such cases in OE-Core and > especially in meta-oe... OK, thanks for the context. Will you be resubmitting with TARGET_LDFLAGS? >> What was the problem you ran into? > > Not a problem per se, but it was not getting all the LDFLAGS being passed, > more specifically: > > -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed > > BTW, in Classic OE it was failing on GNU Hash QA check w/o this. >
On Tue, Mar 20, 2012 at 08:33:14AM -0700, Darren Hart wrote: > > > On 03/20/2012 08:28 AM, Denys Dmytriyenko wrote: > > On Tue, Mar 20, 2012 at 08:01:44AM -0700, Darren Hart wrote: > >> > >> > >> On 03/19/2012 05:22 PM, Denys Dmytriyenko wrote: > >>> From: Denys Dmytriyenko <denys@ti.com> > >>> > >>> Replace dependency on eglibc with virtual/libc > >>> Pass LDFLAGS to TARGET_CC_ARCH, instead of CFLAGS as Makefile overrides it > >>> > >>> Signed-off-by: Denys Dmytriyenko <denys@ti.com> > >> > >> Thanks Denys, > >> > >> Looking through the rt-tests sources I don't see TARGET_CC_ARCH > >> anywhere. Have you confirmed that changes made there make their way into > >> the actual build? > > > > Darren, > > > > TARGET_CC_ARCH is not an rt-tests specific variable, it's used in OE. > > Although, TARGET_LDFLAGS might be more appropriate for this purpose, > > historically TARGET_CC_ARCH was heavily used to pass distro LDFLAGS to the > > app's build process - grepping it would show many such cases in OE-Core and > > especially in meta-oe... > > OK, thanks for the context. Will you be resubmitting with TARGET_LDFLAGS? Nope, my bad, it's actually the other way around. From bitbake.conf: export LDFLAGS = "${TARGET_LDFLAGS}" So, appending to TARGET_CC_ARCH is the simplest way to pass flags, as that's embedded into $CC Another option would have been to call make with -e flag to let environment variables override the ones in the Makefile, but that's less controlled...
On 03/20/2012 09:09 AM, Denys Dmytriyenko wrote: > On Tue, Mar 20, 2012 at 08:33:14AM -0700, Darren Hart wrote: >> >> >> On 03/20/2012 08:28 AM, Denys Dmytriyenko wrote: >>> On Tue, Mar 20, 2012 at 08:01:44AM -0700, Darren Hart wrote: >>>> >>>> >>>> On 03/19/2012 05:22 PM, Denys Dmytriyenko wrote: >>>>> From: Denys Dmytriyenko <denys@ti.com> >>>>> >>>>> Replace dependency on eglibc with virtual/libc >>>>> Pass LDFLAGS to TARGET_CC_ARCH, instead of CFLAGS as Makefile overrides it >>>>> >>>>> Signed-off-by: Denys Dmytriyenko <denys@ti.com> >>>> >>>> Thanks Denys, >>>> >>>> Looking through the rt-tests sources I don't see TARGET_CC_ARCH >>>> anywhere. Have you confirmed that changes made there make their way into >>>> the actual build? >>> >>> Darren, >>> >>> TARGET_CC_ARCH is not an rt-tests specific variable, it's used in OE. >>> Although, TARGET_LDFLAGS might be more appropriate for this purpose, >>> historically TARGET_CC_ARCH was heavily used to pass distro LDFLAGS to the >>> app's build process - grepping it would show many such cases in OE-Core and >>> especially in meta-oe... >> >> OK, thanks for the context. Will you be resubmitting with TARGET_LDFLAGS? > > Nope, my bad, it's actually the other way around. From bitbake.conf: > > export LDFLAGS = "${TARGET_LDFLAGS}" > > So, appending to TARGET_CC_ARCH is the simplest way to pass flags, as that's > embedded into $CC > > Another option would have been to call make with -e flag to let environment > variables override the ones in the Makefile, but that's less controlled... OK, from the context you've provided, the TARGET_CC_ARCH seems like the most expedient option. Ultimately a patch to rt-tests to allow users to provide LDFLAGS seems like the best approach. I can talk to Clark W. about this. So you have my ack: Acked-by: Darren Hart <dvhart@linux.intel.com>
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 03/20/2012 08:11 AM, Koen Kooi wrote: > > Op 20 mrt. 2012, om 16:01 heeft Darren Hart het volgende > geschreven: > >> >> >> On 03/19/2012 05:22 PM, Denys Dmytriyenko wrote: >>> From: Denys Dmytriyenko <denys@ti.com> >>> >>> Replace dependency on eglibc with virtual/libc Pass LDFLAGS to >>> TARGET_CC_ARCH, instead of CFLAGS as Makefile overrides it >>> >>> Signed-off-by: Denys Dmytriyenko <denys@ti.com> >> >> Thanks Denys, >> >> Looking through the rt-tests sources I don't see TARGET_CC_ARCH >> anywhere. Have you confirmed that changes made there make their >> way into the actual build? > > TARGET_CC_ARCH is an OE thing, it's is what ends up in $CC. > for record you should not need to pass LDFLAGS to TARGET_CC_ARCH in OE-Core if you were doing it to silence hash style warnings we have fixed toolchain for that > regards, > > Koen > > _______________________________________________ Openembedded-core > mailing list Openembedded-core@lists.openembedded.org > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk9/ta8ACgkQuwUzVZGdMxQGeACgj4VzDL18gKXxxI6pp0zhTOKs a6kAn0GccFNh94ttjzSWxp7Q6UYTY/4R =yKil -----END PGP SIGNATURE-----
Patch
diff --git a/meta/recipes-rt/rt-tests/rt-tests_0.83.bb b/meta/recipes-rt/rt-tests/rt-tests_0.83.bb index 6425027..3755c79 100644 --- a/meta/recipes-rt/rt-tests/rt-tests_0.83.bb +++ b/meta/recipes-rt/rt-tests/rt-tests_0.83.bb @@ -1,7 +1,7 @@ DESCRIPTION = "Real-Time preemption testcases" HOMEPAGE = "https://rt.wiki.kernel.org/index.php/Cyclictest" SECTION = "tests" -DEPENDS = "linux-libc-headers eglibc" +DEPENDS = "linux-libc-headers virtual/libc" LICENSE = "GPLv2 & GPLv2+" LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \ file://src/cyclictest/cyclictest.c;beginline=7;endline=9;md5=ce162fe491d19d2ec67dff6dbc938d50 \ @@ -11,13 +11,13 @@ SRCREV = "5f1e84f8b015df3ff950056494134eca3f640d70" # git -> 0.83 needs a PE bump PE = "1" -PR = "r1" +PR = "r2" SRC_URI = "git://github.com/clrkwllms/rt-tests.git" S = "${WORKDIR}/git" -CFLAGS += "-I${S}/src/include -D_GNU_SOURCE -Wall -Wno-nonnulli ${LDFLAGS}" +TARGET_CC_ARCH += "${LDFLAGS}" # calling 'uname -m' is broken on crossbuilds EXTRA_OEMAKE = "NUMA=0"