From owner-freebsd-gecko@FreeBSD.ORG Fri Jul 9 12:50:07 2010 Return-Path: Delivered-To: gecko@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 504A1106564A for ; Fri, 9 Jul 2010 12:50:07 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 280AB8FC0C for ; Fri, 9 Jul 2010 12:50:07 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o69Co7rP069400 for ; Fri, 9 Jul 2010 12:50:07 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o69Co65B069399; Fri, 9 Jul 2010 12:50:06 GMT (envelope-from gnats) Date: Fri, 9 Jul 2010 12:50:06 GMT Message-Id: <201007091250.o69Co65B069399@freefall.freebsd.org> To: gecko@FreeBSD.org From: Anonymous Cc: Subject: Re: ports/148436: www/firefox35: directories installed with incorrect permissons X-BeenThere: freebsd-gecko@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Anonymous List-Id: Gecko Rendering Engine issues List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Jul 2010 12:50:07 -0000 The following reply was made to PR ports/148436; it has been noted by GNATS. From: Anonymous To: Peter Jeremy Cc: bug-followup@FreeBSD.org Subject: Re: ports/148436: www/firefox35: directories installed with incorrect permissons Date: Fri, 09 Jul 2010 16:44:15 +0400 Well, nsinstall(1) uses same permissions when copying directories recursively. It's easily reproducable by $ nsinstall -m 644 /usr/include blah nsinstall: cannot create /path/to/blah/include/unctrl.h: Permission denied More accurately $ nsinstall -t -m 644 dist/include/system_wrappers FAKEDIR/include/firefox3/unstable from toolkit/mozapps/installer/packager.mk # The dist/include has module subdirectories that we need to flatten find $(DIST)/include -type f -o -type l -exec $(SYSINSTALL) $(IFLAGS1) {} $(DESTDIR)$(includedir)/unstable \; This also makes SU_CMD-aware install as well as INSTALL_AS_USER unable to copy system_wrapper directory contents to FAKEDIR. And on do-install cpio(1) faithfully copies those wrong permissions to PREFIX/include. However, there is a port's specific bug in mimicing `-xtype f' behaviour. The man pages says -xtype c The same as -type unless the file is a symbolic link. For sym- bolic links: if the -H or -P option was specified, true if the file is a link to a file of type c; if the -L option has been given, true if c is `l'. In other words, for symbolic links, -xtype checks the type of the file that -type does not check. So, it should match all files and symlinks that do *not* point to directories. IOW, above command should not try to install system_wrappers and system_wrappers_js. Here is a quick fix. --- a.diff begins here --- Index: www/firefox35/files/patch-toolkit_mozapps_installer_packager.mk =================================================================== RCS file: /a/.cvsup/ports/www/firefox35/files/patch-toolkit_mozapps_installer_packager.mk,v retrieving revision 1.1 diff -u -p -r1.1 patch-toolkit_mozapps_installer_packager.mk --- www/firefox35/files/patch-toolkit_mozapps_installer_packager.mk 25 Apr 2009 22:45:27 -0000 1.1 +++ www/firefox35/files/patch-toolkit_mozapps_installer_packager.mk 9 Jul 2010 12:12:28 -0000 @@ -5,7 +5,7 @@ (cd $(DESTDIR)$(includedir)/stable && tar -xf -) # The dist/include has module subdirectories that we need to flatten - find $(DIST)/include -xtype f -exec $(SYSINSTALL) $(IFLAGS1) {} $(DESTDIR)$(includedir)/unstable \; -+ find $(DIST)/include -type f -o -type l -exec $(SYSINSTALL) $(IFLAGS1) {} $(DESTDIR)$(includedir)/unstable \; ++ find -L $(DIST)/include -name system_wrappers\* -prune -or -type f -exec $(SYSINSTALL) $(IFLAGS1) {} $(DESTDIR)$(includedir)/unstable \; # IDL directory is stable (dist/sdk/idl) and unstable (dist/idl) $(NSINSTALL) -D $(DESTDIR)$(idldir)/stable $(NSINSTALL) -D $(DESTDIR)$(idldir)/unstable --- a.diff ends here ---