All users were logged out of Bugzilla on October 13th, 2018
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.
Accepted the bug and added CC list.
Summary: Build fails if DIST path contains symlinks (sometimes) → [PP]Build fails if DIST path contains symlinks (sometimes)
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)) &&
Yes, that fixes it.
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
Last Resolved: 20 years ago
Resolution: --- → FIXED
Fix checked in. Marking the bug resolved. File modified; mozilla/nsprpub/config/nsinstall.c (rev. 3.11)
NSPR now has its own Bugzilla product. Moving this bug to the NSPR product.
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.