* [Buildroot] Problem building avahi
@ 2011-01-05 14:20 Andreas Stahl
2011-01-05 16:10 ` Thomas Petazzoni
0 siblings, 1 reply; 8+ messages in thread
From: Andreas Stahl @ 2011-01-05 14:20 UTC (permalink / raw)
To: buildroot
Hello,
I cannot build the avahi package on buildroot-2010.11
my steps:
- download and extract buildroot-2010.11.tar.bz2
- cd to the buildroot-2010.11 directory
- make atngw100_defconfig
- make
after some hours of heavy building i get the following error:
[...]
make[3]: Betrete Verzeichnis
'/usr/buildroot-2010.11/output/build/avahi-0.6.27/avahi-glib'
CC libavahi_glib_la-glib-watch.lo
CC libavahi_glib_la-glib-malloc.lo
CCLD libavahi-glib.la
libtool: link: warning:
`/usr/buildroot-2010.11/output/staging/usr/lib/libintl.la' seems to be moved
libtool: link: warning: library
`/usr/buildroot-2010.11/output/staging/usr/lib/libglib-2.0.la' was moved.
/bin/grep:
/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/lib/libintl.la:
No such file or directory
/bin/sed: can't read
/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/lib/libintl.la:
No such file or directory
libtool: link:
`/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/buildroot-2010.11/output/staging/usr/lib/libintl.la'
is not a valid libtool archive
make[3]: *** [libavahi-glib.la] Fehler 1
make[3]: Verlasse Verzeichnis
'/usr/buildroot-2010.11/output/build/avahi-0.6.27/avahi-glib'
make[2]: *** [all-recursive] Fehler 1
make[2]: Verlasse Verzeichnis
'/usr/buildroot-2010.11/output/build/avahi-0.6.27'
make[1]: *** [all] Fehler 2
make[1]: Verlasse Verzeichnis
'/usr/buildroot-2010.11/output/build/avahi-0.6.27'
make: *** [/usr/buildroot-2010.11/output/build/avahi-0.6.27/.stamp_built]
Fehler 2
It seems that some paths are wrong...
When I disable the avahi package in the menuconfig, the buildprocess
succseeds and i get a nice target image.
Enabling avahi now produces the same error.
unitil now, i found these wrong paths in lib
output/staging/usr/lib/libintl.la and libglib-2.0.la
I changed those two files an now i get other errors:
[...]
libtool: install: /usr/bin/install -c .libs/libavahi-glib.so.1.0.2T
/usr/buildroot-2010.11/output/staging/usr/lib/libavahi-glib.so.1.0.2
libtool: install: (cd /usr/buildroot-2010.11/output/staging/usr/lib && {
ln -s -f libavahi-glib.so.1.0.2 libavahi-glib.so.1 || { rm -f
libavahi-glib.so.1 && ln -s libavahi-glib.so.1.0.2 libavahi-glib.so.1; }; })
libtool: install: (cd /usr/buildroot-2010.11/output/staging/usr/lib && {
ln -s -f libavahi-glib.so.1.0.2 libavahi-glib.so || { rm -f libavahi-glib.so
&& ln -s libavahi-glib.so.1.0.2 libavahi-glib.so; }; })
libtool: install: /usr/bin/install -c .libs/libavahi-glib.lai
/usr/buildroot-2010.11/output/staging/usr/lib/libavahi-glib.la
/usr/bin/install: cannot stat `.libs/libavahi-glib.lai': No such file or
directory
make[3]: *** [install-libLTLIBRARIES] Fehler 1
make[3]: Verlasse Verzeichnis
'/usr/buildroot-2010.11/output/build/avahi-0.6.27/avahi-glib'
make[2]: *** [install-am] Fehler 2
make[2]: Verlasse Verzeichnis
'/usr/buildroot-2010.11/output/build/avahi-0.6.27/avahi-glib'
make[1]: *** [install-recursive] Fehler 1
make[1]: Verlasse Verzeichnis
'/usr/buildroot-2010.11/output/build/avahi-0.6.27'
make: ***
[/usr/buildroot-2010.11/output/build/avahi-0.6.27/.stamp_staging_installed]
Fehler 2
Any suggestions? Is this a configuration error on my system ?
Andreas Stahl
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] Problem building avahi
2011-01-05 14:20 [Buildroot] Problem building avahi Andreas Stahl
@ 2011-01-05 16:10 ` Thomas Petazzoni
2011-01-06 11:11 ` Andreas Stahl
0 siblings, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2011-01-05 16:10 UTC (permalink / raw)
To: buildroot
Hello Andreas,
On Wed, 5 Jan 2011 15:20:55 +0100
"Andreas Stahl" <a.stahl@wsa-electronic.de> wrote:
> I cannot build the avahi package on buildroot-2010.11
> my steps:
> - download and extract buildroot-2010.11.tar.bz2
> - cd to the buildroot-2010.11 directory
> - make atngw100_defconfig
> - make
For what it's worth, on my system, this exact set of commands produces
a working build, which includes avahi.
> '/usr/buildroot-2010.11/output/build/avahi-0.6.27/avahi-glib'
This path seems to indicate that you might be running Buildroot as
root. You should not do this.
And in fact I think it's precisely because you're building somewhere
in /usr that things break. In order to workaround libtool oddness, we
have a mechanism in Buildroot that modifies .la files by replacing:
/usr
by
$(STAGING_DIR)/usr
But in your case, since your $(STAGING_DIR) starts by /usr, the rule
gets executed over and over and over again, so the path goes like this:
/usr
$(STAGING_DIR)/usr
$(STAGING_DIR)/$(STAGING_DIR)/usr
$(STAGING_DIR)/$(STAGING_DIR)/$(STAGING_DIR)/usr
etc.
So as a quick fix you can just not build from /usr, and build from
$HOME, as a normal user. Long term, we should improve our sed
expression to not fall into this.
Regards,
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] Problem building avahi
2011-01-05 16:10 ` Thomas Petazzoni
@ 2011-01-06 11:11 ` Andreas Stahl
2011-01-06 11:32 ` Thomas Petazzoni
0 siblings, 1 reply; 8+ messages in thread
From: Andreas Stahl @ 2011-01-06 11:11 UTC (permalink / raw)
To: buildroot
Hello Thomas
> This path seems to indicate that you might be running Buildroot as
> root. You should not do this.
I build in /usr/buildroot-2010.11 for some historical reason, but not as
root. The buildroot directory belongs to the devel group and i'm a
member of this group.
> And in fact I think it's precisely because you're building somewhere
> in /usr that things break. In order to workaround libtool oddness, we
> have a mechanism in Buildroot that modifies .la files by replacing:
>
> /usr
>
> by
>
> $(STAGING_DIR)/usr
Ok, I now extracted buildroot to /opt/buildroot-2010.11 and everything
works now. Thanks for that hint!
Hmm, the uImage now is in output/images and got not copied to
output/target/boot/ and is not in the rootfs.tar ?
Thanks, Andreas
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] Problem building avahi
2011-01-06 11:11 ` Andreas Stahl
@ 2011-01-06 11:32 ` Thomas Petazzoni
2011-01-06 12:33 ` Peter Korsgaard
0 siblings, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2011-01-06 11:32 UTC (permalink / raw)
To: buildroot
On Thu, 6 Jan 2011 12:11:26 +0100
"Andreas Stahl" <a.stahl@wsa-electronic.de> wrote:
> I build in /usr/buildroot-2010.11 for some historical reason, but not
> as root. The buildroot directory belongs to the devel group and i'm a
> member of this group.
Ok, good. At least this has exhibited an interesting bug of Buildroot
that we'll have to fix.
> Ok, I now extracted buildroot to /opt/buildroot-2010.11 and everything
> works now. Thanks for that hint!
Great.
> Hmm, the uImage now is in output/images and got not copied to
> output/target/boot/ and is not in the rootfs.tar ?
No. On non-x86 embedded systems it's not very usual to have the kernel
image *inside* the root filesystem. It's usually flashed separatly from
the root filesystem image.
However, if there is demand for such a feature, we could certainly add
an option to the kernel build process.
Regards,
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] Problem building avahi
2011-01-06 11:32 ` Thomas Petazzoni
@ 2011-01-06 12:33 ` Peter Korsgaard
2011-01-06 12:55 ` Thomas Petazzoni
0 siblings, 1 reply; 8+ messages in thread
From: Peter Korsgaard @ 2011-01-06 12:33 UTC (permalink / raw)
To: buildroot
>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni@free-electrons.com> writes:
Hi,
>> I build in /usr/buildroot-2010.11 for some historical reason, but not
>> as root. The buildroot directory belongs to the devel group and i'm a
>> member of this group.
Thomas> Ok, good. At least this has exhibited an interesting bug of Buildroot
Thomas> that we'll have to fix.
Yeah.
>> Hmm, the uImage now is in output/images and got not copied to
>> output/target/boot/ and is not in the rootfs.tar ?
Thomas> No. On non-x86 embedded systems it's not very usual to have the kernel
Thomas> image *inside* the root filesystem. It's usually flashed separatly from
Thomas> the root filesystem image.
Thomas> However, if there is demand for such a feature, we could certainly add
Thomas> an option to the kernel build process.
For such a special situation, I would prefer to we tell users to do it
with BR2_ROOTFS_POST_BUILD_SCRIPT instead.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] Problem building avahi
2011-01-06 12:33 ` Peter Korsgaard
@ 2011-01-06 12:55 ` Thomas Petazzoni
2011-01-06 13:19 ` Quotient Remainder
2011-01-06 13:19 ` Peter Korsgaard
0 siblings, 2 replies; 8+ messages in thread
From: Thomas Petazzoni @ 2011-01-06 12:55 UTC (permalink / raw)
To: buildroot
On Thu, 06 Jan 2011 13:33:25 +0100
Peter Korsgaard <jacmet@uclibc.org> wrote:
> Thomas> Ok, good. At least this has exhibited an interesting bug of
> Thomas> Buildroot that we'll have to fix.
>
> Yeah.
Something like "grep -v" the lines that have already been changed to
start with $(STAGING_DIR)/usr ?
> For such a special situation, I would prefer to we tell users to do it
> with BR2_ROOTFS_POST_BUILD_SCRIPT instead.
On x86, it's fairly usual to have the kernel inside the root
filesystem, and embedded x86 systems are quite common. So this feature
could be seen as sufficiently useful to be integrated into BR.
Something like:
config BR2_LINUX_KERNEL_INSTALL_TO_ROOTFS
bool "Install kernel image in rootfs"
default y if BR2_i386 || BR2_x86_64
help
Copy the generated kernel image to the /boot directory
in the root filesystem
Regards,
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] Problem building avahi
2011-01-06 12:55 ` Thomas Petazzoni
@ 2011-01-06 13:19 ` Quotient Remainder
2011-01-06 13:19 ` Peter Korsgaard
1 sibling, 0 replies; 8+ messages in thread
From: Quotient Remainder @ 2011-01-06 13:19 UTC (permalink / raw)
To: buildroot
Ar D?ar, 2011-01-06 ag 13:55 +0100, scr?obh Thomas Petazzoni:
> On x86, it's fairly usual to have the kernel inside the root
> filesystem, and embedded x86 systems are quite common. So this feature
> could be seen as sufficiently useful to be integrated into BR.
>
> Something like:
>
> config BR2_LINUX_KERNEL_INSTALL_TO_ROOTFS
> bool "Install kernel image in rootfs"
> default y if BR2_i386 || BR2_x86_64
> help
> Copy the generated kernel image to the /boot directory
> in the root filesystem
This feature was present as BR2_LINUX_COPYTO_ROOTFS until the great
linux rework.
Commit fe1cba690a9afdd661abf0285b08ce95c6347de7 removed it.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] Problem building avahi
2011-01-06 12:55 ` Thomas Petazzoni
2011-01-06 13:19 ` Quotient Remainder
@ 2011-01-06 13:19 ` Peter Korsgaard
1 sibling, 0 replies; 8+ messages in thread
From: Peter Korsgaard @ 2011-01-06 13:19 UTC (permalink / raw)
To: buildroot
>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni@free-electrons.com> writes:
Hi,
Thomas> Ok, good. At least this has exhibited an interesting bug of
Thomas> Buildroot that we'll have to fix.
>>
>> Yeah.
Thomas> Something like "grep -v" the lines that have already been changed to
Thomas> start with $(STAGING_DIR)/usr ?
We could simply skip lines that already contain STAGING_DIR/usr - E.G.
$(SED) -e '/$(subst /,\/,$(STAGING_DIR)/usr)/b' -e "s:\(['= ]\)/usr:..
>> For such a special situation, I would prefer to we tell users to do it
>> with BR2_ROOTFS_POST_BUILD_SCRIPT instead.
Thomas> On x86, it's fairly usual to have the kernel inside the root
Thomas> filesystem, and embedded x86 systems are quite common. So this
Thomas> feature could be seen as sufficiently useful to be integrated
Thomas> into BR.
But u-boot on x86 isn't common, right?
Thomas> Something like:
Thomas> config BR2_LINUX_KERNEL_INSTALL_TO_ROOTFS
Thomas> bool "Install kernel image in rootfs"
Thomas> default y if BR2_i386 || BR2_x86_64
Thomas> help
Thomas> Copy the generated kernel image to the /boot directory
Thomas> in the root filesystem
Ahh, for non-uImage stuff - Yes, that's fine.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2011-01-06 13:19 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-05 14:20 [Buildroot] Problem building avahi Andreas Stahl
2011-01-05 16:10 ` Thomas Petazzoni
2011-01-06 11:11 ` Andreas Stahl
2011-01-06 11:32 ` Thomas Petazzoni
2011-01-06 12:33 ` Peter Korsgaard
2011-01-06 12:55 ` Thomas Petazzoni
2011-01-06 13:19 ` Quotient Remainder
2011-01-06 13:19 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox