Oliver Fromme wrote at 18:35 +0100 on Nov 15, 2010:
 > Anonymous <swel...@gmail.com> wrote:
 >  > John Hein <jh...@symmetricom.com> writes:
 >  > > +post-extract:
 >  > > +# The distribution tarball for python 2.7 has permission bits for 
 > 'others'
 >  > > +# set to 0.  Later during install, we copy Tools and Demo to the 
 > installed
 >  > > +# prefix, so set them right here.
 >  > > +    ${FIND} ${WRKSRC}/Tools ${WRKSRC}/Demo -type d | ${XARGS} ${CHMOD} 
 > a+rx
 >  > > +    ${FIND} ${WRKSRC}/Tools ${WRKSRC}/Demo -type f | ${XARGS} ${CHMOD} 
 > a+r
 >  > > +
 >  >  
 >  >  This can be reduced to one command
 >  >  
 >  >    ${FIND} ${WRKSRC}/Tools ${WRKSRC}/Demo \
 >  >                -type d -exec ${CHMOD} a+rx {} + \
 >  >            -or -type f -exec ${CHMOD} a+r  {} +
 > 
 > It's unclear to me why you have to use find(1) at all.
 > The following simple command should work equally well:
 > 
 >     ${CHMOD} -R og=u-w ${WRKSRC}/Tools ${WRKSRC}/Demo

Yes, that's better still and will work fine since the user bits are
good in the tarball.  Updated patch (with a fix for the path, too)...

Index: Makefile
===================================================================
RCS file: /base/FreeBSD-CVS/ports/lang/python27/Makefile,v
retrieving revision 1.169
diff -u -p -r1.169 Makefile
--- Makefile    6 Sep 2010 00:25:04 -0000       1.169
+++ Makefile    15 Nov 2010 18:16:55 -0000
@@ -146,6 +146,12 @@ CONFIGURE_ARGS+=   --disable-ipv6
 CONFIGURE_ARGS+=       --with-fpectl
 .endif
 
+post-extract:
+# The distribution tarball for python 2.7 has permission bits for 'others'
+# set to 0.  Later during install, we copy Tools and Demo to the installed
+# prefix, so set them right here.
+       ${CHMOD} og=u-w ${PYTHON_WRKSRC}/Tools ${PYTHON_WRKSRC}/Demo
+
 pre-patch:
        ${CP} -r ${PATCH_WRKSRC}/Lib/plat-freebsd8 \
                ${PATCH_WRKSRC}/Lib/plat-freebsd9
@@ -260,12 +266,12 @@ post-install:
 .if !defined(NOPORTDATA)
        @${MKDIR} ${DATADIR}
        @cd ${PYTHON_WRKSRC}; ${TAR} -cf - Tools | \
-               (cd ${DATADIR}; ${TAR} -xf -)
+               (cd ${DATADIR}; ${TAR} --no-same-owner -xf -)
 .endif
 .if !defined(NOPORTEXAMPLES)
        @${MKDIR} ${EXAMPLESDIR}
        @cd ${PYTHON_WRKSRC}/Demo; ${TAR} -cf - * | \
-               (cd ${EXAMPLESDIR}; ${TAR} -xf -)
+               (cd ${EXAMPLESDIR}; ${TAR} --no-same-owner -xf -)
 .endif
 
        @${CAT} ${PKGMESSAGE}
_______________________________________________
freebsd-python@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-python
To unsubscribe, send any mail to "freebsd-python-unsubscr...@freebsd.org"

Reply via email to