qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] configure: fix qemu-ga missing '.exe' extension


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH] configure: fix qemu-ga missing '.exe' extension on windows
Date: Wed, 26 Jul 2017 05:37:07 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

On 07/25/2017 10:28 PM, Philippe Mathieu-Daudé wrote:

>>> - rm -f $(filter-out %.tlb,$(TOOLS)) $(HELPERS-y) qemu-ga TAGS
>>> cscope.* *.pod *~ */*~
>>> + rm -f $(filter-out %.tlb,$(TOOLS)) $(HELPERS-y) qemu-ga${EXESUF}
>>> TAGS cscope.* *.pod *~ */*~
>>>
>>> It's a bit ugly since `rm -f qemu-ga.exe` would silently fail on posix,

But that's the whole point of 'rm -f' - to silently ignore files that
didn't exist.

>>
>> On w32 I mean, sorry.
> 
> side question: should we use $(RM) with something like:
> 
> ifeq ($(OS),Windows_NT)
>     RM = cmd //C del //Q //F
> else
>     RM = rf -f
> endif
> 

Absolutely not.  We can at least assume a mingw-like environment that
has all the usual tools like rm.

>>>
>>> Alternatively, you can explicitly check for qemu-ga.exe and remove it if
>>> it exists. I would consider either acceptable, but not this patch as it
>>> currently stands.

But that's what 'rm -f' already does - I don't see the point in adding a
racy check for existence prior to deletion, when deletion already
handles the race.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]