[avahi] Building 0.6.17 on Solaris

Ted Percival ted at midg3t.net
Thu Feb 8 17:34:31 PST 2007

Padraig O'Briain wrote:
> I was able to get it to build with the attached patch.
>  service-types.db: service-types build-db
>  	$(PYTHON) build-db $< $@.coming
> -	mv $@.coming $@
> +	if test -f "$@.coming"; then mv $@.coming $@; fi

I'm not sure why this is necessary. The change to this bit of code was
made so that $@ would only be created if the build-db command succeeded.
It's possible for the build-db command to fail but the $@ file to be
created, which means if `make` is run again, it will consider the rule

I don't see how adding an 'if' around the mv command helps at all.
Surely the mv command will only be attempted if the build-db command
succeeds, in which case the $@.coming file will definitely exist. Have I
missed something?

If this is the right change to make, it might also need to be made near
line 35 where there is a similar service-types.db rule.


More information about the avahi mailing list