* [Qemu-devel] aarch64-linux-user compilation error
@ 2016-12-11 19:09 Pranith Kumar
2016-12-11 19:32 ` Pranith Kumar
2016-12-11 22:59 ` Peter Maydell
0 siblings, 2 replies; 7+ messages in thread
From: Pranith Kumar @ 2016-12-11 19:09 UTC (permalink / raw)
To: qemu-devel; +Cc: peter.maydell, alex.bennee
Hi,
I am getting a strange compilation error lately for aarch64-linux-user. I
think it is somehow related to TYPE_PTRVOID handling but my investigation has
not led to anything concrete. I think this is a compiler error since the build
passes on an other system with gcc-6.
Info: ubuntu 16.04 x86_64 system
$ gcc --version
gcc (Ubuntu 5.4.1-2ubuntu1~16.04) 5.4.1 20160904
Error:
/home/pranith/devops/code/qemu/linux-user/ioctls.h:224:9: error: ‘SNDCTL_DSP_MAPINBUF’ undeclared here (not in a function)
IOCTL(SNDCTL_DSP_MAPINBUF, IOC_R, MK_PTR(MK_STRUCT(STRUCT_buffmem_desc)))
^
/home/pranith/devops/code/qemu/linux-user/syscall.c:5453:23: note: in definition of macro ‘IOCTL’
{ TARGET_ ## cmd, cmd, #cmd, access, 0, { __VA_ARGS__ } },
^
/home/pranith/devops/code/qemu/linux-user/ioctls.h:225:9: error: ‘SNDCTL_DSP_MAPOUTBUF’ undeclared here (not in a function)
IOCTL(SNDCTL_DSP_MAPOUTBUF, IOC_R, MK_PTR(MK_STRUCT(STRUCT_buffmem_desc)))
^
/home/pranith/devops/code/qemu/linux-user/syscall.c:5453:23: note: in definition of macro ‘IOCTL’
{ TARGET_ ## cmd, cmd, #cmd, access, 0, { __VA_ARGS__ } },
^
/home/pranith/devops/code/qemu/linux-user/ioctls.h:280:9: error: ‘SOUND_MIXER_ACCESS’ undeclared here (not in a function)
IOCTL(SOUND_MIXER_ACCESS, 0, TYPE_PTRVOID)
^
/home/pranith/devops/code/qemu/linux-user/syscall.c:5453:23: note: in definition of macro ‘IOCTL’
{ TARGET_ ## cmd, cmd, #cmd, access, 0, { __VA_ARGS__ } },
^
/home/pranith/devops/code/qemu/rules.mak:60: recipe for target 'linux-user/syscall.o' failed
--
Pranith
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] aarch64-linux-user compilation error
2016-12-11 19:09 [Qemu-devel] aarch64-linux-user compilation error Pranith Kumar
@ 2016-12-11 19:32 ` Pranith Kumar
2016-12-11 22:59 ` Peter Maydell
1 sibling, 0 replies; 7+ messages in thread
From: Pranith Kumar @ 2016-12-11 19:32 UTC (permalink / raw)
To: qemu-devel; +Cc: Peter Maydell, Alex Bennée
On Sun, Dec 11, 2016 at 2:09 PM, Pranith Kumar <bobby.prani@gmail.com> wrote:
> Hi,
>
> I am getting a strange compilation error lately for aarch64-linux-user. I
> think it is somehow related to TYPE_PTRVOID handling but my investigation has
> not led to anything concrete. I think this is a compiler error since the build
> passes on an other system with gcc-6.
>
> Info: ubuntu 16.04 x86_64 system
>
> $ gcc --version
> gcc (Ubuntu 5.4.1-2ubuntu1~16.04) 5.4.1 20160904
>
The issue occurs even with a newer gcc.
$ gcc --version
gcc (Ubuntu 6.2.0-3ubuntu11~16.04) 6.2.0 20160901
--
Pranith
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] aarch64-linux-user compilation error
2016-12-11 19:09 [Qemu-devel] aarch64-linux-user compilation error Pranith Kumar
2016-12-11 19:32 ` Pranith Kumar
@ 2016-12-11 22:59 ` Peter Maydell
2016-12-12 1:36 ` Pranith Kumar
1 sibling, 1 reply; 7+ messages in thread
From: Peter Maydell @ 2016-12-11 22:59 UTC (permalink / raw)
To: Pranith Kumar; +Cc: QEMU Developers, Alex Bennée
On 11 December 2016 at 19:09, Pranith Kumar <bobby.prani@gmail.com> wrote:
> I am getting a strange compilation error lately for aarch64-linux-user. I
> think it is somehow related to TYPE_PTRVOID handling but my investigation has
> not led to anything concrete. I think this is a compiler error since the build
> passes on an other system with gcc-6.
> Error:
> /home/pranith/devops/code/qemu/linux-user/ioctls.h:224:9: error: ‘SNDCTL_DSP_MAPINBUF’ undeclared here (not in a function)
> IOCTL(SNDCTL_DSP_MAPINBUF, IOC_R, MK_PTR(MK_STRUCT(STRUCT_buffmem_desc)))
> ^
SNDCTL_DSP_MAPINBUF is supposed to be defined by your system
headers (/usr/include/linux/soundcard.h or equivalent).
Similarly for SNDCTL_DSP_MAPOUTBUF and SOUND_MIXER_ACCESS.
Looking at QEMU's git history we've used these symbols
for years. I would check whether your system headers
are actually providing these symbols (and that the
compiler is really putting the right headers on the
include path).
thanks
-- PMM
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] aarch64-linux-user compilation error
2016-12-11 22:59 ` Peter Maydell
@ 2016-12-12 1:36 ` Pranith Kumar
2016-12-12 11:39 ` Alex Bennée
0 siblings, 1 reply; 7+ messages in thread
From: Pranith Kumar @ 2016-12-12 1:36 UTC (permalink / raw)
To: Peter Maydell; +Cc: QEMU Developers, Alex Bennée
On Sun, Dec 11, 2016 at 5:59 PM, Peter Maydell <peter.maydell@linaro.org> wrote:
>
>> Error:
>> /home/pranith/devops/code/qemu/linux-user/ioctls.h:224:9: error: ‘SNDCTL_DSP_MAPINBUF’ undeclared here (not in a function)
>> IOCTL(SNDCTL_DSP_MAPINBUF, IOC_R, MK_PTR(MK_STRUCT(STRUCT_buffmem_desc)))
>> ^
>
> SNDCTL_DSP_MAPINBUF is supposed to be defined by your system
> headers (/usr/include/linux/soundcard.h or equivalent).
> Similarly for SNDCTL_DSP_MAPOUTBUF and SOUND_MIXER_ACCESS.
>
> Looking at QEMU's git history we've used these symbols
> for years. I would check whether your system headers
> are actually providing these symbols (and that the
> compiler is really putting the right headers on the
> include path).
So soundcard.h header is provided by two packages:
$ apt-file search /usr/include/linux/soundcard.h
linux-libc-dev: /usr/include/linux/soundcard.h
oss4-dev: /usr/include/linux/soundcard.h
I had oss4-dev installed. After removing that and reinstalling
linux-libc-dev, it compiles fine. Not sure why this file differs. May
be a packaging issue.
Thanks for the help!
--
Pranith
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] aarch64-linux-user compilation error
2016-12-12 1:36 ` Pranith Kumar
@ 2016-12-12 11:39 ` Alex Bennée
2016-12-13 2:17 ` Pranith Kumar
0 siblings, 1 reply; 7+ messages in thread
From: Alex Bennée @ 2016-12-12 11:39 UTC (permalink / raw)
To: Pranith Kumar; +Cc: Peter Maydell, QEMU Developers
Pranith Kumar <bobby.prani@gmail.com> writes:
> On Sun, Dec 11, 2016 at 5:59 PM, Peter Maydell <peter.maydell@linaro.org> wrote:
>>
>>> Error:
>>> /home/pranith/devops/code/qemu/linux-user/ioctls.h:224:9: error: ‘SNDCTL_DSP_MAPINBUF’ undeclared here (not in a function)
>>> IOCTL(SNDCTL_DSP_MAPINBUF, IOC_R, MK_PTR(MK_STRUCT(STRUCT_buffmem_desc)))
>>> ^
>>
>> SNDCTL_DSP_MAPINBUF is supposed to be defined by your system
>> headers (/usr/include/linux/soundcard.h or equivalent).
>> Similarly for SNDCTL_DSP_MAPOUTBUF and SOUND_MIXER_ACCESS.
>>
>> Looking at QEMU's git history we've used these symbols
>> for years. I would check whether your system headers
>> are actually providing these symbols (and that the
>> compiler is really putting the right headers on the
>> include path).
>
> So soundcard.h header is provided by two packages:
>
> $ apt-file search /usr/include/linux/soundcard.h
> linux-libc-dev: /usr/include/linux/soundcard.h
> oss4-dev: /usr/include/linux/soundcard.h
>
> I had oss4-dev installed. After removing that and reinstalling
> linux-libc-dev, it compiles fine. Not sure why this file differs. May
> be a packaging issue.
Sounds like it. How did you ensure you had your QEMU build dependencies
installed on your system?
--
Alex Bennée
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] aarch64-linux-user compilation error
2016-12-12 11:39 ` Alex Bennée
@ 2016-12-13 2:17 ` Pranith Kumar
2016-12-13 7:25 ` Alex Bennée
0 siblings, 1 reply; 7+ messages in thread
From: Pranith Kumar @ 2016-12-13 2:17 UTC (permalink / raw)
To: Alex Bennée; +Cc: Peter Maydell, QEMU Developers
Hi Alex,
On Mon, Dec 12, 2016 at 6:39 AM, Alex Bennée <alex.bennee@linaro.org> wrote:
>
> Sounds like it. How did you ensure you had your QEMU build dependencies
> installed on your system?
>
I did:
$ sudo apt-get build-dep qemu
to get all the build dependencies. I must have recently installed
oss4-dev through some other package which overwrote soundcard.h. It
was working fine earlier.
--
Pranith
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] aarch64-linux-user compilation error
2016-12-13 2:17 ` Pranith Kumar
@ 2016-12-13 7:25 ` Alex Bennée
0 siblings, 0 replies; 7+ messages in thread
From: Alex Bennée @ 2016-12-13 7:25 UTC (permalink / raw)
To: Pranith Kumar; +Cc: Peter Maydell, QEMU Developers
Pranith Kumar <bobby.prani@gmail.com> writes:
> Hi Alex,
>
> On Mon, Dec 12, 2016 at 6:39 AM, Alex Bennée <alex.bennee@linaro.org> wrote:
>>
>> Sounds like it. How did you ensure you had your QEMU build dependencies
>> installed on your system?
>>
>
> I did:
>
> $ sudo apt-get build-dep qemu
>
> to get all the build dependencies. I must have recently installed
> oss4-dev through some other package which overwrote soundcard.h. It
> was working fine earlier.
aptitude why oss4-dev
Might tell you what happened. Anyway glad it's fixed now.
--
Alex Bennée
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2016-12-13 7:27 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-12-11 19:09 [Qemu-devel] aarch64-linux-user compilation error Pranith Kumar
2016-12-11 19:32 ` Pranith Kumar
2016-12-11 22:59 ` Peter Maydell
2016-12-12 1:36 ` Pranith Kumar
2016-12-12 11:39 ` Alex Bennée
2016-12-13 2:17 ` Pranith Kumar
2016-12-13 7:25 ` Alex Bennée
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).