Closed
Bug 4954
Opened 26 years ago
Closed 26 years ago
[PP]Build fails if DIST path contains symlinks (sometimes)
Categories
(NSPR :: NSPR, defect, P3)
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: tenthumbs, Assigned: srinivas)
Details
Attachments
(1 file)
2.75 KB,
text/plain
|
Details |
I decide the final resting place for NSPR is /usr/xtra/nspr but I do not want to
build as root; so ...
As the build user, I create /tmp/usr/xtra. As root I do
ln -s /tmp/usr/xtra /usr/xtra
As the build user I say "make DIST=/usr/xtra/nspr".
The first time nsinstall runs it dies with an error saying "permission" denied
trying to create /usr/xtra.
It appears that nsinstall uses lstat rather than stat sometimes and doesn't
recognize that it can create /usr/xtra/nspr.
If I manually create /tmp/usr/xtra/nspr the build works.
Summary: Build fails if DIST path contains symlinks (sometimes) → [PP]Build fails if DIST path contains symlinks (sometimes)
Comment 2•26 years ago
|
||
I followed the exact recipe you described on
my machine and it worked for me.
Can you do 'ls -l /usr/xtra' and see what it
says?
This is caused by the use of lstat by nsinstall. To create
/usr/xtra/nspr
nsinstall checks, by calling lstat, if each component of the path is a
directory. After reaching a directory (/usr, in this case) nsinstall starts to
build the path and fails because you don't have write permission for /usr.
Can you apply the following patch to nsprpub/config/nsinstall.c and retry your
test case?
Index: nsinstall.c
===================================================================
RCS file: /cvsroot/mozilla/nsprpub/config/nsinstall.c,v
retrieving revision 3.10
diff -r3.10 nsinstall.c
132c132
< if ((lstat(path, &sb) < 0 || !S_ISDIR(sb.st_mode)) &&
---
> if ((stat(path, &sb) < 0 || !S_ISDIR(sb.st_mode)) &&
Since this same code appears in mozilla/config/nsinstall.c, perhaps this should
be passed on to the person responsible.
Added Chris Yeh and Ramiro to the cc list.
Chris and Ramiro, can you make a similar change to
mozilla/config/nsinstall.c?
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
Fix checked in. Marking the bug resolved.
File modified;
mozilla/nsprpub/config/nsinstall.c (rev. 3.11)
Comment 9•26 years ago
|
||
NSPR now has its own Bugzilla product. Moving this bug to the NSPR product.
Comment 10•26 years ago
|
||
this fix is not visible to qa. if you think this bug should be reopened,
please do so.
will mark as verified.
You need to log in
before you can comment on or make changes to this bug.
Description
•