Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] Problem with svn revision 24694
@ 2009-01-05 20:49 hartleys
  2009-01-05 21:47 ` [Buildroot] External toolchain problem " hartleys
  0 siblings, 1 reply; 4+ messages in thread
From: hartleys @ 2009-01-05 20:49 UTC (permalink / raw)
  To: buildroot

Hello all,

I updated my svn checkout today and noticed that busybox and the linux
kernel were updated.  When either of these have been updated in the past
I usually have problems with my root filesystem not getting fully
created.

To get around this issue I normally just do a 'make menuconfig' so that
my buildroot .config gets updated then do a 'make'.  The new files then
get downloaded and compiled.  I'll then do a 'make busybox-menuconfig'
and 'make linux26-menuconfig' to make sure busybox and the kernel are
configured correctly for what I need.  After that I manually delete
$(PROJECT_BUILD_DIR)/root, $(PROJECT_BUILD_DIR)/.root,
$(PROJECT_BUILD_DIR)/autotools-stamps.  Then do a 'make' and everything
gets built correctly.

In the past this has worked fine.  When I tried it today I get the
following right after my external toolchain libraries are copied to
$(PROJECT_BUILD_DIR)/root/lib:

...
copy_toolchain_lib_root lib=libstdc++.so.6.0.8 dst=/lib
SYSROOT_DIR=`/usr/local/arm/4.1.1-920t/bin/arm-linux-gcc -v 2>&1 | grep
^Configured | tr " " "\n" | grep -- "--with-sysroot" | cut -f2 -d=`; cp
-a ${SYSROOT_DIR}/* /home/bigguiness/buildroot/build_arm/staging_dir/ ;
find /home/bigguiness/buildroot/build_arm/staging_dir -type d | xargs
chmod 755
cp: cannot create special file
`/home/bigguiness/buildroot/build_arm/staging_dir/dev/vcsa6': Operation
not permitted
cp: cannot create special file
`/home/bigguiness/buildroot/build_arm/staging_dir/dev/vcs6': Operation
not permitted
cp: cannot create special file
`/home/bigguiness/buildroot/build_arm/staging_dir/dev/vcsa5': Operation
not permitted
...
More cp: cannot create special file errors
...
cp: cannot create special file
`/home/bigguiness/buildroot/build_arm/staging_dir/dev/console':
Operation not permitted
cp: cannot open `/etc/X11/Xwrapper.config' for reading: Permission
denied
cp: cannot create regular file
`/home/bigguiness/buildroot/build_arm/staging_dir/etc/vmware-tools/xsess
ion-gdm.sh': Permission denied
...
More cp: cannot create regular file errors
...
cp: cannot create regular file
`/home/bigguiness/buildroot/build_arm/staging_dir/etc/vmware-tools/xsess
ion-xdm.pl': Permission denied
cp: cannot access `/etc/cups/ssl': Permission denied
cp: cannot open `/etc/cups/cupsd.conf' for reading: Permission denied
cp: cannot open `/etc/cups/printers.conf' for reading: Permission denied
cp: cannot access `/etc/chatscripts': Permission denied
cp: cannot open `/etc/group-' for reading: Permission denied
cp: cannot access `/etc/selinux/refpolicy-targeted/modules/active':
Permission denied
cp: cannot open
`/etc/selinux/refpolicy-targeted/modules/semanage.read.LOCK' for
reading: Permission denied
cp: cannot open
`/etc/selinux/refpolicy-targeted/modules/semanage.trans.LOCK' for
reading: Permission denied
cp: cannot access `/etc/selinux/refpolicy-targeted/modules/previous':
Permission denied
cp: cannot open `/etc/shadow-' for reading: Permission denied
cp: cannot open `/etc/identd.key' for reading: Permission denied
cp: cannot open `/etc/apt/secring.gpg' for reading: Permission denied
cp: cannot open `/etc/apt/trusted.gpg' for reading: Permission denied
cp: cannot open `/etc/apt/trustdb.gpg' for reading: Permission denied
cp: cannot open `/etc/apt/trusted.gpg~' for reading: Permission denied
cp: cannot open `/etc/.pwd.lock' for reading: Permission denied
cp: cannot access `/etc/ssl/private': Permission denied
cp: cannot open `/etc/passwd-' for reading: Permission denied
cp: cannot open `/etc/qt3/.qt_plugins_3.3rc.lock' for reading:
Permission denied
cp: cannot open `/etc/gshadow-' for reading: Permission denied
cp: cannot open `/etc/at.deny' for reading: Permission denied
cp: cannot open `/etc/sudoers' for reading: Permission denied
cp: cannot open `/etc/ppp/pap-secrets' for reading: Permission denied
cp: cannot open `/etc/ppp/chap-secrets' for reading: Permission denied
cp: cannot access `/etc/ppp/peers': Permission denied
cp: cannot open `/etc/exim4/passwd.client' for reading: Permission
denied
cp: cannot open `/etc/gshadow' for reading: Permission denied
cp: cannot open `/etc/shadow' for reading: Permission denied
cp: cannot create regular file
`/home/bigguiness/buildroot/build_arm/staging_dir/etc/init.d/vmware-tool
s': Permission denied
cp: cannot access `/home/bigguiness/.gnupg': Permission denied

At this point the build just hangs.  I've let it sit there for various
times to see if it will continue but a Ctrl-C always gives me:

make: *** Deleting file
`/home/bigguiness/buildroot/project_build_arm/ep9307/root/lib/libc.so.0'
make: ***
[/home/bigguiness/buildroot/project_build_arm/ep9307/root/lib/libc.so.0]
Interrupt

Any ideas what might be the problem? I'm at a loss...

Thanks,
Hartley

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Buildroot] External toolchain problem with svn revision 24694
  2009-01-05 20:49 [Buildroot] Problem with svn revision 24694 hartleys
@ 2009-01-05 21:47 ` hartleys
  2009-01-05 21:54   ` Thomas Petazzoni
  0 siblings, 1 reply; 4+ messages in thread
From: hartleys @ 2009-01-05 21:47 UTC (permalink / raw)
  To: buildroot

Thomas,

I updated my svn checkout today and ran into a problem running the
toplevel make.

I haven't completely figured out where the problem is but I think one of
the changes you made in revision 24408 is causing part of it.

> * In toolchain/external-toolchain/ext-tool.mk, copy the contents of
>   the sysroot directory to the staging dir.

My bash scripting is not quite up to par but I think the
$(copy_toolchain_sysroot) macro is doing the following:

1) calls '$(TARGET_CC) -v'
2) greps the output for the "Configured ...." information
3) greps that information for the "--with-sysroot ..." string
4) cuts the string following --with-sysroot and assigns it to
SYSROOT_DIR
5) copies the entire $${SYSROOT_DIR} to ${STAGING_DIR}
6) chmod's all the directories to 755

The problem I have is my external toolchain does not have a
--with-sysroot configuration option.  For some reason this seems to
cause the cp to try copying my entire root directory to the staging dir.
Here's the output of my $(TARGET_CC) -v:

bigguiness at etch:~/buildroot$ /usr/local/arm/4.1.1-920t/bin/arm-linux-gcc
-v
Using built-in specs.
Target: arm-linux-uclibc
Configured with:
/opt/buildroot.920t-cc/toolchain_build_arm_nofpu/gcc-4.1.1/configure
--prefix=/usr/local/arm/4.1.1-920t --build=i386-pc-linux-gnu
--host=i386-pc-linux-gnu --target=arm-linux-uclibc
--enable-languages=c,c++ --disable-__cxa_atexit --enable-target-optspace
--with-gnu-ld
--with-gmp=/opt/buildroot.920t-cc/toolchain_build_arm_nofpu/gmp
--with-mpfr=/opt/buildroot.920t-cc/toolchain_build_arm_nofpu/mpfr
--enable-shared --disable-nls --enable-threads --disable-multilib
--with-float=soft
Thread model: posix
gcc version 4.1.1

Any ideas?

Thanks,
Hartley

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Buildroot] External toolchain problem with svn revision 24694
  2009-01-05 21:47 ` [Buildroot] External toolchain problem " hartleys
@ 2009-01-05 21:54   ` Thomas Petazzoni
  2009-01-12 11:16     ` Daniel James Laird
  0 siblings, 1 reply; 4+ messages in thread
From: Thomas Petazzoni @ 2009-01-05 21:54 UTC (permalink / raw)
  To: buildroot

Hi hartleys,

Le Mon, 5 Jan 2009 16:47:53 -0500,
"hartleys" <hartleys@visionengravers.com> a ?crit :

> My bash scripting is not quite up to par but I think the
> $(copy_toolchain_sysroot) macro is doing the following:
> 
> 1) calls '$(TARGET_CC) -v'
> 2) greps the output for the "Configured ...." information
> 3) greps that information for the "--with-sysroot ..." string
> 4) cuts the string following --with-sysroot and assigns it to
> SYSROOT_DIR
> 5) copies the entire $${SYSROOT_DIR} to ${STAGING_DIR}
> 6) chmod's all the directories to 755

Exactly.

> The problem I have is my external toolchain does not have a
> --with-sysroot configuration option.

Which probably means that your toolchain hasn't been compiled with
sysroot support.

> Any ideas?

Yes and no.

Yes: I can make sure that we test if sysroot is supported by the
toolchain and if not fail out instead of doing stupid things. I will
commit a patch that implements this soon.

No: I don't see a proper way of supporting external toolchains if they
don't support sysroot. Our previous attempts of using --rpath-link have
all failed, and --sysroot seems to be the best option we've seen until
now.

Thanks for the report!

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Buildroot] External toolchain problem with svn revision 24694
  2009-01-05 21:54   ` Thomas Petazzoni
@ 2009-01-12 11:16     ` Daniel James Laird
  0 siblings, 0 replies; 4+ messages in thread
From: Daniel James Laird @ 2009-01-12 11:16 UTC (permalink / raw)
  To: buildroot

I have applied a fix in my local version that checks for sysroot support before doing the cp.  This should solve this problem.

I have a second issue which is that I think the copy_toolchain stuff needs to be changed to use a target stamp file otherwise it gets called everytime a new make of buildroot runs and this complicates things like libiconv as this has iconv.h and this gets overridden by the toolchain iconv.h and this is not good.  Any ideas on how we could solve this?

Cheers
Dan

-----Original Message-----
From: buildroot-bounces@busybox.net [mailto:buildroot-bounces at busybox.net] On Behalf Of Thomas Petazzoni
Sent: 2009 Jan 05 21:55
To: hartleys
Cc: buildroot at uclibc.org
Subject: Re: [Buildroot] External toolchain problem with svn revision 24694

Hi hartleys,

Le Mon, 5 Jan 2009 16:47:53 -0500,
"hartleys" <hartleys@visionengravers.com> a ?crit :

> My bash scripting is not quite up to par but I think the
> $(copy_toolchain_sysroot) macro is doing the following:
> 
> 1) calls '$(TARGET_CC) -v'
> 2) greps the output for the "Configured ...." information
> 3) greps that information for the "--with-sysroot ..." string
> 4) cuts the string following --with-sysroot and assigns it to
> SYSROOT_DIR
> 5) copies the entire $${SYSROOT_DIR} to ${STAGING_DIR}
> 6) chmod's all the directories to 755

Exactly.

> The problem I have is my external toolchain does not have a
> --with-sysroot configuration option.

Which probably means that your toolchain hasn't been compiled with
sysroot support.

> Any ideas?

Yes and no.

Yes: I can make sure that we test if sysroot is supported by the
toolchain and if not fail out instead of doing stupid things. I will
commit a patch that implements this soon.

No: I don't see a proper way of supporting external toolchains if they
don't support sysroot. Our previous attempts of using --rpath-link have
all failed, and --sysroot seems to be the best option we've seen until
now.

Thanks for the report!

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-01-12 11:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-05 20:49 [Buildroot] Problem with svn revision 24694 hartleys
2009-01-05 21:47 ` [Buildroot] External toolchain problem " hartleys
2009-01-05 21:54   ` Thomas Petazzoni
2009-01-12 11:16     ` Daniel James Laird

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox