[m-dev.] diff: install and create bindists better on win32

Warwick Harvey wharvey at cs.monash.edu.au
Thu Jul 29 15:42:12 AEST 1999

>  .PHONY: install_scripts
>  install_scripts: $(SCRIPTS) install_dirs
> -	# we remove the installed `mmake' script before (re)installing it
> +	# we move the installed `mmake' script before (re)installing it
>  	# to avoid overwriting the script while it is running
> -	-rm -f $(INSTALL_BINDIR)/mmake
> +	# (just removing it doesn't work very well on win32, which will
> +	# deny you permission to write the file while mmake is running).
> +	-mv $(INSTALL_BINDIR)/mmake $(INSTALL_BINDIR)/mmake.old

Would it be better to use `mv -f' in case `mmake.old' exists for some 
reason?  (e.g. the mmake process was interrupted before the following `rm'?)

>  	for file in $(SCRIPTS); do \
>  		chmod u+w $(INSTALL_BINDIR)/$$file ;\
>  	done
> +	-rm -f $(INSTALL_BINDIR)/mmake.old


mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au

More information about the developers mailing list