humanai / gyp

Automatically exported from code.google.com/p/gyp
0 stars 0 forks source link

Absolute path generated instead of relative #71

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Try to compile chromium
2. When building chromium's webkit part, problem appears:
3. If directory where building is done has more characters then a (quite
low) limit, the build fail with:
[...].o
/full/path/to/chromium/src/out/Release/obj/lease/obj/webkit/libwebcore.a
make: execvp: /bin/sh: Argument list too long

What is the expected output? What do you see instead?
I tried to copy-paste the ~130000 characters long command and strip the
full path to get relative path. The command executed correctly. After
reading a bit on the gyp's wiki, it seems it should create relative paths
(http://code.google.com/p/gyp/wiki/InputFormatReference#Pathname_Relativization)
but it did not.

What version of the product are you using? On what operating system?
http://gyp.googlecode.com/svn/trunk revision 601

Issue page of chromium:
http://code.google.com/p/chromium/issues/detail?id=19854

Original issue reported on code.google.com by nbigaoue...@gmail.com on 1 Sep 2009 at 2:55

GoogleCodeExporter commented 9 years ago
Forgot to say that because of this, I cannot build at all chromium.

Original comment by nbigaoue...@gmail.com on 1 Sep 2009 at 2:56

GoogleCodeExporter commented 9 years ago
The current workaround is to build in a directory with a shorter path. I.e. 
symlink
/b to the directory that holds Chromium's src/.

Original comment by thestig@chromium.org on 2 Sep 2009 at 11:25

GoogleCodeExporter commented 9 years ago
Thanx for the workaround. I knew it though and I had tried using a symlink, but 
what
I remember was that the link was resolved to the full path (be it by gyp or by
makepkg, the ArchLinux package builder): it did not worked.

I was finnaly able to compile chromium mounting (with bind option) the directory
containing the source. This was on x86_64. It was problematic when I tried 
compiling
in a i686 chroot, since all the mount points where messed up. Adding to the
complication was that my main harddrive containing / is almost full, while even
though another 1.5TB drive mounted in /home/Seagate could have hosted the 
building,
/home/Seagate was too big as a path and resulted in the afformentioned error.

So because of a configuration problem from chromium/gyp, I can't (or hardly 
can) just
_compile_ the testing code...

Why is the ar command using full path anyway? Isn't gyp supposed to work with
relative path? That seems to be the cause of the problem...

Original comment by nbigaoue...@gmail.com on 2 Sep 2009 at 11:55

GoogleCodeExporter commented 9 years ago
I have the same problem in Gentoo, as I have
rootdir=/var/tmp/portage/www-client/chromium-4.0.207.0/work/chromium-4.0.207.0/ 
(set
by portage, so hard to shorten)

Original comment by bcafa...@gmail.com on 8 Sep 2009 at 9:09

GoogleCodeExporter commented 9 years ago
Just a note: See http://code.google.com/p/chromium/issues/detail?id=19854 
comment #9 
for a workaround that can be used by portage and probably other package 
managers. It 
involves slight changes to the invocation of the make build part which then 
results in 
a reltaive path build. I've tested that approach successfully with paludis.

Original comment by heiko.pr...@gmail.com on 8 Sep 2009 at 9:38

GoogleCodeExporter commented 9 years ago
It looks as though all we have to do is remove the rootdir and change builddir 
to
$(builddir_name)/$(BUILDTYPE). Seems to work ok for me.

Original comment by thestig@chromium.org on 9 Sep 2009 at 10:00

GoogleCodeExporter commented 9 years ago
Please give this patch a try. If I hear positive results, I'll commit the change
tomorrow. http://codereview.chromium.org/199068/show

Original comment by thestig@chromium.org on 9 Sep 2009 at 10:20

GoogleCodeExporter commented 9 years ago
Fixed?

Original comment by mmoss@chromium.org on 13 Oct 2009 at 2:36

GoogleCodeExporter commented 9 years ago
Waiting for a dep roll on the Chrome side to make sure it all works. Maybe I 
should
do that now.

Original comment by thestig@chromium.org on 13 Oct 2009 at 5:53

GoogleCodeExporter commented 9 years ago

Original comment by thestig@chromium.org on 13 Oct 2009 at 6:52