On Mon, Jul 28, 2008 at 09:40:05PM +0100, Federico G. Schwindt wrote: > On Mon, Jul 28, 2008 at 06:33:49PM +0200, Markus Lude wrote: > > On Thu, Jul 03, 2008 at 06:11:07PM +0200, Markus Lude wrote: > > > Hello, > > > after building python 2.5 from ports I get the following while doing a > > > make clean: > > > > > > ===> Cleaning for python-2.5.2p2 > > > rm: /usr/obj/ports/Python-2.5.2/Python-2.5.2/Lib/plat-openbsd4/regen: > > > Permission denied > > > rm: /usr/obj/ports/Python-2.5.2/Python-2.5.2/Lib/plat-openbsd4/IN.py: > > > Permission denied > > > rm: /usr/obj/ports/Python-2.5.2/Python-2.5.2/Lib/plat-openbsd4: Directory > > > not empty > > > rm: /usr/obj/ports/Python-2.5.2/Python-2.5.2/Lib: Directory not empty > > > rm: /usr/obj/ports/Python-2.5.2/Python-2.5.2: Directory not empty > > > rm: /usr/obj/ports/Python-2.5.2: Directory not empty > > > > > > $ ls -l /usr/obj/ports/Python-2.5.2/Python-2.5.2/Lib/plat-openbsd4 > > > total 24 > > > -rw-r--r-- 1 root wsrc 8492 Jul 3 07:59 IN.py > > > -rwxr-xr-x 1 root wsrc 97 Jul 3 07:59 regen* > > > > > > make clean doesn't seem to use sudo here to remove these files, but why? > > > A few weeks ago this problem didn't appear. > > > > Probably the change of ALL_TARGET in r1.20 of Makefile introduced this > > problem: > > Yes, this is known. For now, unless someone comes with a better solution > we'll have to live with it I'm afraid.
Thanks for letting me know this is a known problem. What about creating the directory in post-build? The problem is that the directory has owner root. Small diff is attached. I'm unsure if this needs a package bump, probably not. Regards, Markus
Index: Makefile =================================================================== RCS file: /cvs/ports/lang/python/2.5/Makefile,v retrieving revision 1.23 diff -u -r1.23 Makefile --- Makefile 25 Jul 2008 19:32:21 -0000 1.23 +++ Makefile 29 Jul 2008 00:00:43 -0000 @@ -18,4 +18,9 @@ post-extract: rm -r ${WRKDIST}/Modules/expat +# directory is created during 'make fake' otherwise, which leads to +# owner problems with non-root builds while 'make clean' +post-build: + mkdir -p ${WRKDIST}/Lib/plat-openbsd4 + .include <bsd.port.mk>