Re: [PATCH] build fix when source tree is fully read-only

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>>> Andrew Haley <aph@xxxxxxxxxx> 26.02.08 10:56 >>>
>Jan Beulich wrote:
>> While the $(TOOLS_ZIP) rule in classpath/tools/Makefile.{am,in} is
>> broken in more general respects (i.e. it doesn't tolerate being
>> interrupted and the make then later be resumed), this patch fixes the
>> most immediate problem of insufficient permissions to remove the copied
>> asm/ and classes/ trees, if those (and perhaps the entire source tree)
>> had undergone a 'chmod -R a-w', resulting in a build failure.
>> 
>> Built and tested on i686-pc-linux-gnu, x86_64-unknown-linux-gnu, and
>> ia64-unknown-linux-gnu.
>
>This isn't a good patch.  If the tree is read-only the user has made it so
>for a reason, and we shouldn't be overriding that.

It's *not* the source tree that gets altered, but the copy made for
creating tools.zip. That copy, as said in the description, gets deleted
immediately afterwards anyway, so what would be the purpose of
insisting of retaining the attributes (which result only from 'cp -pR'
used earlier in the rule.

>I can't think of a nice way to fix this,
>Cc: to Classpath discussion list for comments.

Jan


> 2008-02-26  Jan Beulich  <jbeulich@xxxxxxxxxx>
> 
> 	* classpath/tools/Makefile.am ($(TOOLS_ZIP)): Make tree
> 	writeable before attempting to remove them.
> 	* classpath/tools/Makefile.in: Re-generate.
> 
> --- 2008-02-25/libjava/classpath/tools/Makefile.am	2008-02-22 11:01:17.000000000 +0100
> +++ 2008-02-25/libjava/classpath/tools/Makefile.am	2008-02-25 15:05:34.000000000 +0100
> @@ -218,6 +218,7 @@
>  	if test "$(ZIP)" != ""; then $(ZIP) -u -r ../$(TOOLS_ZIP) .; fi; \
>  	if test "$(FASTJAR)" != ""; then $(FASTJAR) uf ../$(TOOLS_ZIP) .; fi; \
>  	cd ..)
> +	chmod -R a+w asm classes
>  	rm -rf asm classes classes.lst asm.lst
>  
>  # Zip file be gone! (and make sure the classes are gone too)
> --- 2008-02-25/libjava/classpath/tools/Makefile.in	2008-02-22 11:01:17.000000000 +0100
> +++ 2008-02-25/libjava/classpath/tools/Makefile.in	2008-02-25 15:05:34.000000000 +0100
> @@ -1158,6 +1158,7 @@
>  	if test "$(ZIP)" != ""; then $(ZIP) -u -r ../$(TOOLS_ZIP) .; fi; \
>  	if test "$(FASTJAR)" != ""; then $(FASTJAR) uf ../$(TOOLS_ZIP) .; fi; \
>  	cd ..)
> +	chmod -R a+w asm classes
>  	rm -rf asm classes classes.lst asm.lst
>  
>  # Zip file be gone! (and make sure the classes are gone too)
> 
> 
> 





[Index of Archives]     [Linux Kernel]     [Linux Cryptography]     [Fedora]     [Fedora Directory]     [Red Hat Development]

  Powered by Linux