[Top][All Lists]

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

Re: [Qemu-discuss] Undefined reference to `minor', qga/commands-posix.c:

From: Peter Maydell
Subject: Re: [Qemu-discuss] Undefined reference to `minor', qga/commands-posix.c: error when building qemu
Date: Sat, 5 Jan 2019 15:50:37 +0000

On Sat, 5 Jan 2019 at 12:50, Kevin Wilson <address@hidden> wrote:
> HI all,
> I am trying to build qemu-2.3.0 on Fedora 29 machine (X86_64) with 
> gcc-8.2.1-5.
> I need this version for an existing legacy setup.
> I am getting the following error:
> ...
> ./configure --target-list=x86_64-softmmu
> ....
> make
> .....
> ...
>   CC    stubs/qmp_pc_dimm_device_list.o
>   AR    libqemustub.a
>   LINK  qemu-ga
> /usr/bin/ld: qga/commands-posix.o: in function `dev_major_minor':
> /work/src/qemu-2.3.0/qga/commands-posix.c:633: undefined reference to `major'
> /usr/bin/ld: /work/src/qemu-2.3.0/qga/commands-posix.c:634: undefined
> reference to `minor'
> collect2: error: ld returned 1 exit status
> make: *** [Makefile:288: qemu-ga] Error 1
> address@hidden qemu-2.3.0]# [
> BTW, I got the same error when trying with QEMU 2.4.0.

If you want to build a QEMU version this old on a newer
toolchain/glibc, you'll have to look through and find
the bugfixes and changes we've added since which allow
compilation on the newer setup. Usually you can find
the right fix by looking through the QEMU commit log
of a newer QEMU version and also googling for the
compiler error messages you're hitting, which should
bring up the qemu-devel mailing list threads where we
encountered and fixed the problems.

In this case, the answer is that you want the equivalent
of upstream commit 4d04351f4c3db3b70dc, which adds
an include of sys/sysmacros.h if necessary.

-- PMM

reply via email to

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