All of lore.kernel.org
 help / color / mirror / Atom feed
From: Robert Yang <liezhi.yang@windriver.com>
To: Patches and discussions about the oe-core layer
	<openembedded-core@lists.openembedded.org>
Subject: gcc-cross: Argument list too long
Date: Fri, 13 Apr 2012 14:45:58 +0800	[thread overview]
Message-ID: <4F87CBA6.7040207@windriver.com> (raw)


There would be an error when building gcc-cross in the do_install stage
if the TMPDIR's length is more than 200 characters:

make[1]: execvp: /bin/sh: Argument list too long

This is because of the limit of /usr/include/linux/limits.h:

$ grep PATH_MAX /usr/include/linux/limits.h
#define PATH_MAX        4096    /* # chars in a path name including nul */

I don't think it's worth to fix the do_install of gcc-cross, but it would
be good if we can add a check in oe-init-build-env or meta/classes
/sanity.bbclass to check wether the TMPDIR(or build directory) is longer than a 
reasonable vaule, e.g., 1/16th or 1/32th of PATH_MAX? If you are OK with this,
I'd like to work on it.

To reproduce the error:

$ cd /path/to/workdir/
$ for i in `seq 20`; do mkdir _23_5_78_; cd _23_5_78_; done
$ source /path/to/poky/oe-init-build-env
$ bitbake gcc-cross

Then the error comes.

$ pwd | wc -c
224

-- 
Thanks

Robert



             reply	other threads:[~2012-04-13  6:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-13  6:45 Robert Yang [this message]
2012-04-13  8:31 ` gcc-cross: Argument list too long Richard Purdie

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=4F87CBA6.7040207@windriver.com \
    --to=liezhi.yang@windriver.com \
    --cc=openembedded-core@lists.openembedded.org \
    /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.