Last Comment Bug 461322 - Executable permissions for data files (png, xpm, txt)
: Executable permissions for data files (png, xpm, txt)
: fixed1.9.1
Product: Core
Classification: Components
Component: Build Config (show other bugs)
: Trunk
: x86 Linux
: -- normal (vote)
: mozilla1.9.1b3
Assigned To: Phil Ringnalda (:philor)
: Gregory Szorc [:gps]
: 314970 (view as bug list)
Depends on:
Blocks: 361423 513900
  Show dependency treegraph
Reported: 2008-10-23 04:12 PDT by Jan Horak
Modified: 2010-04-02 10:34 PDT (History)
5 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

Fix for data files installation (2.98 KB, patch)
2008-10-23 04:17 PDT, Jan Horak
ted: review+
mbeltzner: approval1.9.1b2-
Details | Diff | Splinter Review
Fix v.2 (4.95 KB, patch)
2008-11-18 20:48 PST, Phil Ringnalda (:philor)
ted: review+
mbeltzner: approval1.9.1+
Details | Diff | Splinter Review

Description Jan Horak 2008-10-23 04:12:52 PDT
User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/2008102014 Fedora/3.0.2-1.fc9 Firefox/3.0.2
Build Identifier: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/2008102014 Fedora/3.0.2-1.fc9 Firefox/3.0.2

Executable flag for particular data files.

Reproducible: Always

Steps to Reproduce:
1. ls -l dist/bin/icons
   ls -l layout/generic/folder.png
   ls -l dist/bin/chrome/icons/default
   ls -l dist/bin/LICENSE dist/bin/README.txt
Comment 1 Jan Horak 2008-10-23 04:17:27 PDT
Created attachment 344456 [details] [diff] [review]
Fix for data files installation

Fix changes to use SYSINSTALL and IFLAGS1 variables for installing affected data files.
Comment 2 [:Aleksej] 2008-10-28 06:10:41 PDT

*** This bug has been marked as a duplicate of bug 361423 ***
Comment 3 Ted Mielczarek [:ted.mielczarek] 2008-11-14 04:01:56 PST
Comment on attachment 344456 [details] [diff] [review]
Fix for data files installation

I confess to not being knowledgeable of the difference between $(INSTALL) and $(SYSINSTALL), but I trust you've done your homework. (Also, you're just installing icons and other non-code files, so differences shouldn't matter all that much.)
Comment 4 Benjamin Smedberg [:bsmedberg] 2008-11-14 08:28:26 PST
Why are you fixing it this way, instead of changing the permissions in the hg repository?

ted, the major difference between INSTALL and SYSINSTALL is that INSTALL will symlink-by-default, while SYSINSTALL always copies.
Comment 5 Mike Beltzner [:beltzner, not reading bugmail] 2008-11-17 21:24:30 PST
Comment on attachment 344456 [details] [diff] [review]
Fix for data files installation

Let's play with this after the beta
Comment 6 Phil Ringnalda (:philor) 2008-11-18 00:26:00 PST
The (partial, incomplete) answer to bsmedberg's question in comment 4 is "because the perms in the repo aren't broken."

The app/Makefile.ins both set NSDISTMODE = copy, which is a subtle way of saying "$(INSTALL) will be $(SYSINSTALL) from now on" and unless you pass mode flags, $(SYSINSTALL) gives you 755. Whether we do it straight up, with $(SYSINSTALL) $(IFLAGS1), or with a twist with $(INSTALL) $(IFLAGS1), everything in an app/ that shouldn't be 755 (including all the things not covered here, but mentioned in various of the bugs this is a duplicate of, including blocklist.xml and defaults/profile/prefs.js) needs to say it doesn't want to be.

The folder.png bit, though, I don't get: I don't see any reason why it would get bogus perms, and at least for me (building non-XULRunner Fx), it doesn't, it winds up 644. Were it me, I'd want an explanation of that bit before taking it.
Comment 7 Phil Ringnalda (:philor) 2008-11-18 20:48:28 PST
Created attachment 348918 [details] [diff] [review]
Fix v.2

Stealing; the first patch was an awesome prod for me to learn how nsinstall actually works, but it's missing some things, doing others in a suboptimal way, and has one bogus bit.

This patch drops the hunk about folder.png, which is (for some reason) 755 in CVS, but 644 and not a problem in mozilla-central.

It also uses $(INSTALL) rather than $(SYSINSTALL) for libs::, because we don't actually *want* to copy these things so much as just want to deal with it happening as a result of whatever caused someone to use that NSDISTMODE. If that goes away, or if someone copy-pastes them out to some other makefile, they ought to revert to symlinks rather than staying copied.

Doing so reverts bug 418601, which is fine, since there's no way that actually worked.
Comment 8 Mike Beltzner [:beltzner, not reading bugmail] 2008-11-26 20:18:41 PST
Comment on attachment 348918 [details] [diff] [review]
Fix v.2

Comment 9 Phil Ringnalda (:philor) 2008-12-06 20:29:37 PST
Comment 10 Phil Ringnalda (:philor) 2008-12-06 20:37:46 PST
Comment 11 Phil Ringnalda (:philor) 2008-12-14 23:40:00 PST
*** Bug 314970 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.