Patchwork Rename qemu -> qemu-system-i386

login
register
mail settings
Submitter Anthony Liguori
Date Aug. 29, 2011, 2:55 p.m.
Message ID <1314629736-13023-1-git-send-email-aliguori@us.ibm.com>
Download mbox | patch
Permalink /patch/112079/
State New
Headers show

Comments

Anthony Liguori - Aug. 29, 2011, 2:55 p.m.
This has been discussed before in the past.  The special casing really makes no
sense anymore.  This seems like a good change to make for 1.0.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
---
 Makefile        |    5 ++---
 Makefile.target |    4 ----
 2 files changed, 2 insertions(+), 7 deletions(-)
Juan Quintela - Aug. 30, 2011, 3:33 p.m.
Anthony Liguori <aliguori@us.ibm.com> wrote:
> This has been discussed before in the past.  The special casing really makes no
> sense anymore.  This seems like a good change to make for 1.0.
>
> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>

Acked-by: Juan Quintela <quintela@redhat.com>

/me never liked it in the 1st place
Peter Maydell - Aug. 30, 2011, 3:41 p.m.
On 29 August 2011 15:55, Anthony Liguori <aliguori@us.ibm.com> wrote:
> This has been discussed before in the past.  The special casing really makes no
> sense anymore.  This seems like a good change to make for 1.0.

No issues here. Obviously it would need to be flagged up to users,
which suggests a thought: should we create a ChangeLog/trunk wiki page
to list things we're going to have to release-note for 1.0 so we
don't have to try to remember them all later?

-- PMM
Anthony Liguori - Aug. 30, 2011, 3:59 p.m.
On 08/30/2011 10:41 AM, Peter Maydell wrote:
> On 29 August 2011 15:55, Anthony Liguori<aliguori@us.ibm.com>  wrote:
>> This has been discussed before in the past.  The special casing really makes no
>> sense anymore.  This seems like a good change to make for 1.0.
>
> No issues here. Obviously it would need to be flagged up to users,
> which suggests a thought: should we create a ChangeLog/trunk wiki page
> to list things we're going to have to release-note for 1.0 so we
> don't have to try to remember them all later?

Excellent thought.

http://wiki.qemu.org/ChangeLog/Next

Regards,

Anthony Liguori

>
> -- PMM
>
Blue Swirl - Aug. 30, 2011, 7:24 p.m.
On Mon, Aug 29, 2011 at 2:55 PM, Anthony Liguori <aliguori@us.ibm.com> wrote:
> This has been discussed before in the past.  The special casing really makes no
> sense anymore.  This seems like a good change to make for 1.0.
>
> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
> ---
>  Makefile        |    5 ++---
>  Makefile.target |    4 ----
>  2 files changed, 2 insertions(+), 7 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 8606849..51ecdb5 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -365,9 +365,8 @@ tar:
>        rm -rf /tmp/$(FILE)
>
>  SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS))
> -SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \
> -             $(patsubst %-softmmu,qemu-system-%, \
> -             $(SYSTEM_TARGETS)))
> +SYSTEM_PROGS=$(patsubst %-softmmu,qemu-system-%, \
> +             $(SYSTEM_TARGETS))

Maybe the patsubst could be avoided, just rename the build directory
from *-softmmu to qemu-system-* while at it?

>
>  USER_TARGETS=$(filter %-user,$(TARGET_DIRS))
>  USER_PROGS=$(patsubst %-bsd-user,qemu-%, \

Also here the directory and executable names could be made to match.

> diff --git a/Makefile.target b/Makefile.target
> index 07af4d4..29287ed 100644
> --- a/Makefile.target
> +++ b/Makefile.target
> @@ -27,12 +27,8 @@ ifdef CONFIG_USER_ONLY
>  QEMU_PROG=qemu-$(TARGET_ARCH2)
>  else
>  # system emulator name
> -ifeq ($(TARGET_ARCH), i386)
> -QEMU_PROG=qemu$(EXESUF)
> -else
>  QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
>  endif
> -endif
>
>  PROGS=$(QEMU_PROG)
>  STPFILES=
> --
> 1.7.4.1
>
>
Anthony Liguori - Sept. 2, 2011, 3:39 p.m.
On 08/30/2011 02:24 PM, Blue Swirl wrote:
> On Mon, Aug 29, 2011 at 2:55 PM, Anthony Liguori<aliguori@us.ibm.com>  wrote:
>> This has been discussed before in the past.  The special casing really makes no
>> sense anymore.  This seems like a good change to make for 1.0.
>>
>> Signed-off-by: Anthony Liguori<aliguori@us.ibm.com>
>> ---
>>   Makefile        |    5 ++---
>>   Makefile.target |    4 ----
>>   2 files changed, 2 insertions(+), 7 deletions(-)
>>
>> diff --git a/Makefile b/Makefile
>> index 8606849..51ecdb5 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -365,9 +365,8 @@ tar:
>>         rm -rf /tmp/$(FILE)
>>
>>   SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS))
>> -SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \
>> -             $(patsubst %-softmmu,qemu-system-%, \
>> -             $(SYSTEM_TARGETS)))
>> +SYSTEM_PROGS=$(patsubst %-softmmu,qemu-system-%, \
>> +             $(SYSTEM_TARGETS))
>
> Maybe the patsubst could be avoided, just rename the build directory
> from *-softmmu to qemu-system-* while at it?
>
>>
>>   USER_TARGETS=$(filter %-user,$(TARGET_DIRS))
>>   USER_PROGS=$(patsubst %-bsd-user,qemu-%, \
>
> Also here the directory and executable names could be made to match.

I thought that historically the phrase softmmu was for the variant of 
libcpu that had an emulated TLB.

I know Peter's been talking about a linux-user mode that uses softmmu 
since certain combinations of architectures today are impossible with 
linux-user (ia64 on x86_64 for instance).

So I think the current naming conventions probably are reasonable 
although I'm not opposed to changing them.  I think that should be a 
separate patch though.

Regards,

Anthony Liguori

>
>> diff --git a/Makefile.target b/Makefile.target
>> index 07af4d4..29287ed 100644
>> --- a/Makefile.target
>> +++ b/Makefile.target
>> @@ -27,12 +27,8 @@ ifdef CONFIG_USER_ONLY
>>   QEMU_PROG=qemu-$(TARGET_ARCH2)
>>   else
>>   # system emulator name
>> -ifeq ($(TARGET_ARCH), i386)
>> -QEMU_PROG=qemu$(EXESUF)
>> -else
>>   QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
>>   endif
>> -endif
>>
>>   PROGS=$(QEMU_PROG)
>>   STPFILES=
>> --
>> 1.7.4.1
>>
>>
>
>
Anthony Liguori - Sept. 2, 2011, 3:40 p.m.
On 08/29/2011 09:55 AM, Anthony Liguori wrote:
> This has been discussed before in the past.  The special casing really makes no
> sense anymore.  This seems like a good change to make for 1.0.
>
> Signed-off-by: Anthony Liguori<aliguori@us.ibm.com>

Applied.

Regards,

Anthony Liguori

> ---
>   Makefile        |    5 ++---
>   Makefile.target |    4 ----
>   2 files changed, 2 insertions(+), 7 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 8606849..51ecdb5 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -365,9 +365,8 @@ tar:
>   	rm -rf /tmp/$(FILE)
>
>   SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS))
> -SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \
> -             $(patsubst %-softmmu,qemu-system-%, \
> -             $(SYSTEM_TARGETS)))
> +SYSTEM_PROGS=$(patsubst %-softmmu,qemu-system-%, \
> +             $(SYSTEM_TARGETS))
>
>   USER_TARGETS=$(filter %-user,$(TARGET_DIRS))
>   USER_PROGS=$(patsubst %-bsd-user,qemu-%, \
> diff --git a/Makefile.target b/Makefile.target
> index 07af4d4..29287ed 100644
> --- a/Makefile.target
> +++ b/Makefile.target
> @@ -27,12 +27,8 @@ ifdef CONFIG_USER_ONLY
>   QEMU_PROG=qemu-$(TARGET_ARCH2)
>   else
>   # system emulator name
> -ifeq ($(TARGET_ARCH), i386)
> -QEMU_PROG=qemu$(EXESUF)
> -else
>   QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
>   endif
> -endif
>
>   PROGS=$(QEMU_PROG)
>   STPFILES=
Blue Swirl - Sept. 3, 2011, 11:46 a.m.
On Fri, Sep 2, 2011 at 3:39 PM, Anthony Liguori <aliguori@us.ibm.com> wrote:
> On 08/30/2011 02:24 PM, Blue Swirl wrote:
>>
>> On Mon, Aug 29, 2011 at 2:55 PM, Anthony Liguori<aliguori@us.ibm.com>
>>  wrote:
>>>
>>> This has been discussed before in the past.  The special casing really
>>> makes no
>>> sense anymore.  This seems like a good change to make for 1.0.
>>>
>>> Signed-off-by: Anthony Liguori<aliguori@us.ibm.com>
>>> ---
>>>  Makefile        |    5 ++---
>>>  Makefile.target |    4 ----
>>>  2 files changed, 2 insertions(+), 7 deletions(-)
>>>
>>> diff --git a/Makefile b/Makefile
>>> index 8606849..51ecdb5 100644
>>> --- a/Makefile
>>> +++ b/Makefile
>>> @@ -365,9 +365,8 @@ tar:
>>>        rm -rf /tmp/$(FILE)
>>>
>>>  SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS))
>>> -SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \
>>> -             $(patsubst %-softmmu,qemu-system-%, \
>>> -             $(SYSTEM_TARGETS)))
>>> +SYSTEM_PROGS=$(patsubst %-softmmu,qemu-system-%, \
>>> +             $(SYSTEM_TARGETS))
>>
>> Maybe the patsubst could be avoided, just rename the build directory
>> from *-softmmu to qemu-system-* while at it?
>>
>>>
>>>  USER_TARGETS=$(filter %-user,$(TARGET_DIRS))
>>>  USER_PROGS=$(patsubst %-bsd-user,qemu-%, \
>>
>> Also here the directory and executable names could be made to match.
>
> I thought that historically the phrase softmmu was for the variant of libcpu
> that had an emulated TLB.
>
> I know Peter's been talking about a linux-user mode that uses softmmu since
> certain combinations of architectures today are impossible with linux-user
> (ia64 on x86_64 for instance).

That could be qemu-linux-softmmu-xxx.

If we had a similar mode for system emulation which used host MMU,
those system emulators could be named qemu-system-hostmmu-xxx.

> So I think the current naming conventions probably are reasonable although
> I'm not opposed to changing them.  I think that should be a separate patch
> though.

OK. The names of the build directories do not bring users any major
benefits in any case.

> Regards,
>
> Anthony Liguori
>
>>
>>> diff --git a/Makefile.target b/Makefile.target
>>> index 07af4d4..29287ed 100644
>>> --- a/Makefile.target
>>> +++ b/Makefile.target
>>> @@ -27,12 +27,8 @@ ifdef CONFIG_USER_ONLY
>>>  QEMU_PROG=qemu-$(TARGET_ARCH2)
>>>  else
>>>  # system emulator name
>>> -ifeq ($(TARGET_ARCH), i386)
>>> -QEMU_PROG=qemu$(EXESUF)
>>> -else
>>>  QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
>>>  endif
>>> -endif
>>>
>>>  PROGS=$(QEMU_PROG)
>>>  STPFILES=
>>> --
>>> 1.7.4.1
>>>
>>>
>>
>>
>
>
>
Andreas Färber - Sept. 3, 2011, 1:44 p.m.
Am 02.09.2011 um 17:40 schrieb Anthony Liguori:

> On 08/29/2011 09:55 AM, Anthony Liguori wrote:
>> This has been discussed before in the past.  The special casing  
>> really makes no
>> sense anymore.  This seems like a good change to make for 1.0.
>>
>> Signed-off-by: Anthony Liguori<aliguori@us.ibm.com>
>
> Applied.
>
> Regards,
>
> Anthony Liguori
>
>> ---
>>  Makefile        |    5 ++---
>>  Makefile.target |    4 ----
>>  2 files changed, 2 insertions(+), 7 deletions(-)
>>
>> diff --git a/Makefile b/Makefile
>> index 8606849..51ecdb5 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -365,9 +365,8 @@ tar:
>>  	rm -rf /tmp/$(FILE)
>>
>>  SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS))
>> -SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \
>> -             $(patsubst %-softmmu,qemu-system-%, \
>> -             $(SYSTEM_TARGETS)))
>> +SYSTEM_PROGS=$(patsubst %-softmmu,qemu-system-%, \
>> +             $(SYSTEM_TARGETS))
>>
>>  USER_TARGETS=$(filter %-user,$(TARGET_DIRS))
>>  USER_PROGS=$(patsubst %-bsd-user,qemu-%, \
>> diff --git a/Makefile.target b/Makefile.target
>> index 07af4d4..29287ed 100644
>> --- a/Makefile.target
>> +++ b/Makefile.target
>> @@ -27,12 +27,8 @@ ifdef CONFIG_USER_ONLY
>>  QEMU_PROG=qemu-$(TARGET_ARCH2)
>>  else
>>  # system emulator name
>> -ifeq ($(TARGET_ARCH), i386)
>> -QEMU_PROG=qemu$(EXESUF)
>> -else
>>  QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
>>  endif
>> -endif
>>
>>  PROGS=$(QEMU_PROG)
>>  STPFILES=

This will leave an old qemu executable from a previous `make install`  
behind.
We should check for it and, unless it's a symlink to qemu-system-i386,  
remove it in the install target.

Andreas
Paolo Bonzini - Sept. 3, 2011, 4:11 p.m.
On 09/03/2011 03:44 PM, Andreas Färber wrote:
> This will leave an old qemu executable from a previous `make
> install` behind. We should check for it and, unless it's a symlink
> to qemu-system-i386, remove it in the install target.

No, "make install" should never remove anything.

Paolo
Anthony Liguori - Sept. 3, 2011, 8:09 p.m.
On 09/03/2011 08:44 AM, Andreas Färber wrote:
> Am 02.09.2011 um 17:40 schrieb Anthony Liguori:
>
>> On 08/29/2011 09:55 AM, Anthony Liguori wrote:
>>> This has been discussed before in the past. The special casing really
>>> makes no
>>> sense anymore. This seems like a good change to make for 1.0.
>>>
>>> Signed-off-by: Anthony Liguori<aliguori@us.ibm.com>
>>
>> Applied.
>>
>> Regards,
>>
>> Anthony Liguori
>>
>>> ---
>>> Makefile | 5 ++---
>>> Makefile.target | 4 ----
>>> 2 files changed, 2 insertions(+), 7 deletions(-)
>>>
>>> diff --git a/Makefile b/Makefile
>>> index 8606849..51ecdb5 100644
>>> --- a/Makefile
>>> +++ b/Makefile
>>> @@ -365,9 +365,8 @@ tar:
>>> rm -rf /tmp/$(FILE)
>>>
>>> SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS))
>>> -SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \
>>> - $(patsubst %-softmmu,qemu-system-%, \
>>> - $(SYSTEM_TARGETS)))
>>> +SYSTEM_PROGS=$(patsubst %-softmmu,qemu-system-%, \
>>> + $(SYSTEM_TARGETS))
>>>
>>> USER_TARGETS=$(filter %-user,$(TARGET_DIRS))
>>> USER_PROGS=$(patsubst %-bsd-user,qemu-%, \
>>> diff --git a/Makefile.target b/Makefile.target
>>> index 07af4d4..29287ed 100644
>>> --- a/Makefile.target
>>> +++ b/Makefile.target
>>> @@ -27,12 +27,8 @@ ifdef CONFIG_USER_ONLY
>>> QEMU_PROG=qemu-$(TARGET_ARCH2)
>>> else
>>> # system emulator name
>>> -ifeq ($(TARGET_ARCH), i386)
>>> -QEMU_PROG=qemu$(EXESUF)
>>> -else
>>> QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
>>> endif
>>> -endif
>>>
>>> PROGS=$(QEMU_PROG)
>>> STPFILES=
>
> This will leave an old qemu executable from a previous `make install`
> behind.

You're not supposed to do a make install on top of another install. 
You're supposed to first do a make uninstall in the old tree than a make 
install in the new tree.

Semantically, this is how a distro package upgrade works.

> We should check for it and, unless it's a symlink to qemu-system-i386,
> remove it in the install target.

Once we're no longer generating an executable, we should be removing it 
from the system.

It's up to the user to remove old files from the system.

Regards,

Anthony Liguori

>
> Andreas
>
Andreas Färber - Sept. 4, 2011, 1:31 p.m.
Am 03.09.2011 um 22:09 schrieb Anthony Liguori:

> On 09/03/2011 08:44 AM, Andreas Färber wrote:
>> Am 02.09.2011 um 17:40 schrieb Anthony Liguori:
>>
>>> On 08/29/2011 09:55 AM, Anthony Liguori wrote:
>>>> diff --git a/Makefile.target b/Makefile.target
>>>> index 07af4d4..29287ed 100644
>>>> --- a/Makefile.target
>>>> +++ b/Makefile.target
>>>> @@ -27,12 +27,8 @@ ifdef CONFIG_USER_ONLY
>>>> QEMU_PROG=qemu-$(TARGET_ARCH2)
>>>> else
>>>> # system emulator name
>>>> -ifeq ($(TARGET_ARCH), i386)
>>>> -QEMU_PROG=qemu$(EXESUF)
>>>> -else
>>>> QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
>>>> endif
>>>> -endif
>>>>
>>>> PROGS=$(QEMU_PROG)
>>>> STPFILES=
>>
>> This will leave an old qemu executable from a previous `make install`
>> behind.
>
> You're not supposed to do a make install on top of another install.  
> You're supposed to first do a make uninstall in the old tree than a  
> make install in the new tree.

In practice though, I do git pull, make, make install and so will  
others.

>> We should check for it and, unless it's a symlink to qemu-system- 
>> i386,
>> remove it in the install target.
>
> Once we're no longer generating an executable, we should be removing  
> it from the system.
>
> It's up to the user to remove old files from the system.

Yeah, Paolo is right there, install shouldn't remove.

What I had in mind was Git's switch from lots of git-* scripts to the  
single git. `make install` checked for such artefacts. My point was, I  
believe we should do the same here and *detect* it within the install  
target.
I'd be fine with a prominent textual notice. And I'd contribute a  
patch myself but have more urgent worries first, so if someone with  
more shell foo wants to take a stab, please do.

We should also make sure `make clean` still removes an old qemu from  
the build dir.

Andreas

Patch

diff --git a/Makefile b/Makefile
index 8606849..51ecdb5 100644
--- a/Makefile
+++ b/Makefile
@@ -365,9 +365,8 @@  tar:
 	rm -rf /tmp/$(FILE)
 
 SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS))
-SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \
-             $(patsubst %-softmmu,qemu-system-%, \
-             $(SYSTEM_TARGETS)))
+SYSTEM_PROGS=$(patsubst %-softmmu,qemu-system-%, \
+             $(SYSTEM_TARGETS))
 
 USER_TARGETS=$(filter %-user,$(TARGET_DIRS))
 USER_PROGS=$(patsubst %-bsd-user,qemu-%, \
diff --git a/Makefile.target b/Makefile.target
index 07af4d4..29287ed 100644
--- a/Makefile.target
+++ b/Makefile.target
@@ -27,12 +27,8 @@  ifdef CONFIG_USER_ONLY
 QEMU_PROG=qemu-$(TARGET_ARCH2)
 else
 # system emulator name
-ifeq ($(TARGET_ARCH), i386)
-QEMU_PROG=qemu$(EXESUF)
-else
 QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
 endif
-endif
 
 PROGS=$(QEMU_PROG)
 STPFILES=