| Summary: | x11-libs/libXt-1.0.6 fails to crosscompile when CFLAGS contains march or mtune options not valid for the host architecture | ||
|---|---|---|---|
| Product: | Gentoo Linux | Reporter: | Andrei Slavoiu <ansla80> |
| Component: | Current packages | Assignee: | Gentoo X packagers <x11> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | ||
| Priority: | High | ||
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Package list: | Runtime testing required: | --- | |
| Attachments: |
libXt-1.0.6.ebuild.patch
build.log libXt-1.0.7-r1-build_dir.tar.bz2 |
||
|
Description
Andrei Slavoiu
2009-10-23 21:26:09 UTC
That looks like you are using a compiler that doesn't know these -march values. Which gcc version do you use? Created attachment 208068 [details, diff]
libXt-1.0.6.ebuild.patch
Copy CFLAGS to CFLAGS_FOR_BUILD and filter -march=* and -mtune=* out of it
(In reply to comment #1) > That looks like you are using a compiler that doesn't know these -march values. > Which gcc version do you use? > /usr/portage/x11-libs/libXt/files/libXt-1.0.6-cross.patch adds a hack for this package to use the native compiler for building some tools that are required at build time. And of course my native amd64 compiler does not understand -march values for arm. Ok, so I've committed a better patch to 1.0.7-r1 which should work with crossdev-wrappers. Please _TEST_ it so I can commit the configure patch to upstream and not look like a fool. Thanks Created attachment 209376 [details]
build.log
Build log for x11-libs/libXt-1.0.7-r1. Same problem a before.
See attachment above. What do you use to cross-compile? What command do you run? Thanks (In reply to comment #7) > What do you use to cross-compile? What command do you run? > > Thanks > I added "=x11-libs/libXt-1.0.7-r1" to /usr/armv4tl-softfloat-linux-gnueabi/etc/portage/package.keywords and then I ran `emerge-armv4tl-softfloat-linux-gnueabi -NDatuv world`. emerge-armv4tl-softfloat-linux-gnueabi is generated by crossdev-wrappers. Hum, ok, so something I intended isn't working. Could you tar.bz2 up the libXt build dir from /var/tmp/portage and attach it here (or upload it somewhere else if bugzilla yells)? It'll be faster that way, instead of going back and forth :) Thanks Created attachment 209515 [details]
libXt-1.0.7-r1-build_dir.tar.bz2
Could you modify the ebuild like so and run "ebuild libXt-1.0.7-r1.ebuild digest" in the correct directory?
Thanks
--- libXt-1.0.7-r1.ebuild 5 Nov 2009 11:41:08 -0000 1.1
+++ libXt-1.0.7-r1.ebuild 7 Nov 2009 22:04:03 -0000
@@ -29,6 +29,6 @@
filter-ldflags -Wl,-Bdirect
if tc-is-cross-compiler; then
- CFLAGS_FOR_BUILD="${BUILD_CFLAGS}"
+ export CFLAGS_FOR_BUILD="${BUILD_CFLAGS}"
fi
}
tried the change as suggested and was successful in cross compiling. My CFLAGS"-march=armv7-a -mtune=cortex-a8 -mfpu=neon -ftree-vectorize -mfloat-abi=softfp -fomit-frame-pointer -Os -pipe". Thanks Thanks for testing. The patch is now in portage and will soon be in the overlay. Cheers |