Hello everyone, I''m working on an Ubuntu 12.04 and I wanted to test Xen 4.2 (official repository offer just version 4.1), so I''ve downloaded the source tarball from the site, followed the instruction in the readme but when compiling I''m getting the following error: In file included from libxl_bootloader.c:21:0: /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] cc1: all warnings being treated as errors make[3]: *** [libxl_bootloader.o] Error 1 could anyone explain how to solve this problem, without disabling the warning/errors compilation options? Thanks in advance Giorgio
Ian Campbell
2012-Oct-02 16:46 UTC
libutil.h moved to bsd/libutil.h (Was: Re: [Xen-users] Problem compiling Xen 4.2 from sources)
(Adding some CCs) On Tue, 2012-10-02 at 17:31 +0100, Giorgio Mossa wrote:> Hello everyone, > I''m working on an Ubuntu 12.04 and I wanted to test > Xen 4.2 (official repository offer just version 4.1), > so I''ve downloaded the source tarball from the site, > followed the instruction in the readme but when compiling > I''m getting the following error: > > In file included from libxl_bootloader.c:21:0: > /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] > cc1: all warnings being treated as errors > make[3]: *** [libxl_bootloader.o] Error 1 > > could anyone explain how to solve this problem, without disabling the warning/errors compilation options?Looks like someone has decided to move this header from /usr/include to /usr/include/bsd and leave behind a #warning in the old location, which has broken the way we do things. http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=640895 seems to relate to the fallout from this. I''m not sure when the include of libutil is needed, it''s not mentioned in the Linux man pages and on Linux neither of the functions we purport to need from it are actually present. Perhaps it''s a BSD only thing? Probably we need to check for bsd/libutil.h in preference to libutil.h although the resolution of #640895 suggests that what we do now is correct now that the bug is fixed, in which case a bug against Ubuntu would be appropriate. Ian, Royer, What do you guys think? Ian.
Ian Campbell
2012-Oct-02 16:46 UTC
libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
(Adding some CCs) On Tue, 2012-10-02 at 17:31 +0100, Giorgio Mossa wrote:> Hello everyone, > I''m working on an Ubuntu 12.04 and I wanted to test > Xen 4.2 (official repository offer just version 4.1), > so I''ve downloaded the source tarball from the site, > followed the instruction in the readme but when compiling > I''m getting the following error: > > In file included from libxl_bootloader.c:21:0: > /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] > cc1: all warnings being treated as errors > make[3]: *** [libxl_bootloader.o] Error 1 > > could anyone explain how to solve this problem, without disabling the warning/errors compilation options?Looks like someone has decided to move this header from /usr/include to /usr/include/bsd and leave behind a #warning in the old location, which has broken the way we do things. http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=640895 seems to relate to the fallout from this. I''m not sure when the include of libutil is needed, it''s not mentioned in the Linux man pages and on Linux neither of the functions we purport to need from it are actually present. Perhaps it''s a BSD only thing? Probably we need to check for bsd/libutil.h in preference to libutil.h although the resolution of #640895 suggests that what we do now is correct now that the bug is fixed, in which case a bug against Ubuntu would be appropriate. Ian, Royer, What do you guys think? Ian.
Ian Campbell
2012-Oct-02 16:50 UTC
Re: [Xen-users] libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
On Tue, 2012-10-02 at 17:46 +0100, Ian Campbell wrote:> (Adding some CCs) > On Tue, 2012-10-02 at 17:31 +0100, Giorgio Mossa wrote: > > Hello everyone, > > I''m working on an Ubuntu 12.04 and I wanted to test > > Xen 4.2 (official repository offer just version 4.1), > > so I''ve downloaded the source tarball from the site, > > followed the instruction in the readme but when compiling > > I''m getting the following error: > > > > In file included from libxl_bootloader.c:21:0: > > /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] > > cc1: all warnings being treated as errors > > make[3]: *** [libxl_bootloader.o] Error 1 > > > > could anyone explain how to solve this problem, without disabling > the warning/errors compilation options?Oh, BTW, I expect you could just purge libbsd-dev from your system and that would workaround the issue. Ian.> > Looks like someone has decided to move this header from /usr/include > to /usr/include/bsd and leave behind a #warning in the old location, > which has broken the way we do things. > > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=640895 seems to relate > to the fallout from this. > > I''m not sure when the include of libutil is needed, it''s not mentioned > in the Linux man pages and on Linux neither of the functions we purport > to need from it are actually present. Perhaps it''s a BSD only thing? > > Probably we need to check for bsd/libutil.h in preference to libutil.h > although the resolution of #640895 suggests that what we do now is > correct now that the bug is fixed, in which case a bug against Ubuntu > would be appropriate. > > Ian, Royer, What do you guys think? > > Ian. > > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xen.org > http://lists.xen.org/xen-users
Ian Campbell
2012-Oct-02 16:50 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
On Tue, 2012-10-02 at 17:46 +0100, Ian Campbell wrote:> (Adding some CCs) > On Tue, 2012-10-02 at 17:31 +0100, Giorgio Mossa wrote: > > Hello everyone, > > I''m working on an Ubuntu 12.04 and I wanted to test > > Xen 4.2 (official repository offer just version 4.1), > > so I''ve downloaded the source tarball from the site, > > followed the instruction in the readme but when compiling > > I''m getting the following error: > > > > In file included from libxl_bootloader.c:21:0: > > /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] > > cc1: all warnings being treated as errors > > make[3]: *** [libxl_bootloader.o] Error 1 > > > > could anyone explain how to solve this problem, without disabling > the warning/errors compilation options?Oh, BTW, I expect you could just purge libbsd-dev from your system and that would workaround the issue. Ian.> > Looks like someone has decided to move this header from /usr/include > to /usr/include/bsd and leave behind a #warning in the old location, > which has broken the way we do things. > > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=640895 seems to relate > to the fallout from this. > > I''m not sure when the include of libutil is needed, it''s not mentioned > in the Linux man pages and on Linux neither of the functions we purport > to need from it are actually present. Perhaps it''s a BSD only thing? > > Probably we need to check for bsd/libutil.h in preference to libutil.h > although the resolution of #640895 suggests that what we do now is > correct now that the bug is fixed, in which case a bug against Ubuntu > would be appropriate. > > Ian, Royer, What do you guys think? > > Ian. > > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xen.org > http://lists.xen.org/xen-users
2012/10/2 Giorgio Mossa <mossa@poisson.phc.unipi.it>> Hello everyone, > I''m working on an Ubuntu 12.04 and I wanted to test > Xen 4.2 (official repository offer just version 4.1), > so I''ve downloaded the source tarball from the site, > followed the instruction in the readme but when compiling > I''m getting the following error: > > In file included from libxl_bootloader.c:21:0: > /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use > <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] > cc1: all warnings being treated as errors > make[3]: *** [libxl_bootloader.o] Error 1 > > could anyone explain how to solve this problem, without disabling the > warning/errors compilation options? > > Thanks in advance > > Giorgio > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xen.org > http://lists.xen.org/xen-users >If I remember You need textinfo library which isn''t listed in there. I''m using those deppendicies to install xen 4.2 from source: apt-get install git-core texinfo libglib2.-dev libyajl-dev build-essential bridge-utils apt-get build-dep xen _______________________________________________ Xen-users mailing list Xen-users@lists.xen.org http://lists.xen.org/xen-users
inline ----- Original Message ----- From: Giorgio Mossa <mossa@poisson.phc.unipi.it> To: xen-users@lists.xen.org Cc: Sent: Tuesday, October 2, 2012 9:31 AM Subject: [Xen-users] Problem compiling Xen 4.2 from sources Hello everyone, I''m working on an Ubuntu 12.04 and I wanted to test Xen 4.2 (official repository offer just version 4.1), so I''ve downloaded the source tarball from the site, followed the instruction in the readme but when compiling I''m getting the following error: In file included from libxl_bootloader.c:21:0: /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] cc1: all warnings being treated as errors make[3]: *** [libxl_bootloader.o] Error 1 could anyone explain how to solve this problem, without disabling the warning/errors compilation options? -------------- As Dariusz said, missing texinfo stopped my build too. Here is my apt log: ------------------------- apt history ------------- $ sudo grep -i commandline /var/log/apt/history.log Commandline: apt-get install nano ubuntu-minimal openssh-server Commandline: apt-get install linux-image-server grub Commandline: apt-get upgrade Commandline: apt-get install build-essential Commandline: apt-get install bcc bin86 gawk bridge-utils iproute libcurl3 libcurl4-openssl-dev bzip2 module-init-tools transfig tgif Commandline: apt-get install make gcc libc6-dev zlib1g-dev python python-dev python-twisted libncurses5-dev patch libvncserver-dev libsdl-dev libjpeg-dev Commandline: apt-get install iasl libbz2-dev e2fslibs-dev git-core uuid-dev ocaml ocaml-findlib libx11-dev bison flex xz-utils libyajl-dev Commandline: apt-get build-dep xen Commandline: apt-get install texinfo --------------------------------- snip --------------------- -- Mark
I''ve installed all the packages you told but compilation still doesn''t work. On Tue, Oct 02, 2012 at 11:00:23AM -0700, Mark Pryor wrote:> -------------- > > As Dariusz said, missing texinfo stopped my build too. > > Here is my apt log: > > ------------------------- apt history ------------- > $ sudo grep -i commandline /var/log/apt/history.log > Commandline: apt-get install nano ubuntu-minimal openssh-server > Commandline: apt-get install linux-image-server grub > Commandline: apt-get upgrade > Commandline: apt-get install build-essential > Commandline: apt-get install bcc bin86 gawk bridge-utils iproute libcurl3 libcurl4-openssl-dev bzip2 module-init-tools transfig tgif > Commandline: apt-get install make gcc libc6-dev zlib1g-dev python python-dev python-twisted libncurses5-dev patch libvncserver-dev libsdl-dev libjpeg-dev > Commandline: apt-get install iasl libbz2-dev e2fslibs-dev git-core uuid-dev ocaml ocaml-findlib libx11-dev bison flex xz-utils libyajl-dev > Commandline: apt-get build-dep xen > Commandline: apt-get install texinfo > --------------------------------- snip --------------------- > > -- > Mark
Giorgio Mossa
2012-Oct-02 19:54 UTC
Re: [Xen-users] libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
On Tue, Oct 02, 2012 at 05:50:03PM +0100, Ian Campbell wrote:> On Tue, 2012-10-02 at 17:46 +0100, Ian Campbell wrote: > > Oh, BTW, I expect you could just purge libbsd-dev from your system and > that would workaround the issue. > > Ian. >Sadly I can''t because I''ve other packages which depend on it......
Giorgio Mossa
2012-Oct-02 19:54 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
On Tue, Oct 02, 2012 at 05:50:03PM +0100, Ian Campbell wrote:> On Tue, 2012-10-02 at 17:46 +0100, Ian Campbell wrote: > > Oh, BTW, I expect you could just purge libbsd-dev from your system and > that would workaround the issue. > > Ian. >Sadly I can''t because I''ve other packages which depend on it......
Am 02.10.2012 20:00, schrieb Mark Pryor:> inline > > > > ----- Original Message ----- > From: Giorgio Mossa <mossa@poisson.phc.unipi.it> > To: xen-users@lists.xen.org > Cc: > Sent: Tuesday, October 2, 2012 9:31 AM > Subject: [Xen-users] Problem compiling Xen 4.2 from sources > > Hello everyone, > I''m working on an Ubuntu 12.04 and I wanted to test > Xen 4.2 (official repository offer just version 4.1), > so I''ve downloaded the source tarball from the site, > followed the instruction in the readme but when compiling > I''m getting the following error: > > In file included from libxl_bootloader.c:21:0: > /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] > cc1: all warnings being treated as errors > make[3]: *** [libxl_bootloader.o] Error 1 > > could anyone explain how to solve this problem, without disabling the warning/errors compilation options? > > -------------- > > As Dariusz said, missing texinfo stopped my build too. > > Here is my apt log: > > ------------------------- apt history ------------- > $ sudo grep -i commandline /var/log/apt/history.log > Commandline: apt-get install nano ubuntu-minimal openssh-server > Commandline: apt-get install linux-image-server grub > Commandline: apt-get upgrade > Commandline: apt-get install build-essential > Commandline: apt-get install bcc bin86 gawk bridge-utils iproute libcurl3 libcurl4-openssl-dev bzip2 module-init-tools transfig tgif > Commandline: apt-get install make gcc libc6-dev zlib1g-dev python python-dev python-twisted libncurses5-dev patch libvncserver-dev libsdl-dev libjpeg-dev > Commandline: apt-get install iasl libbz2-dev e2fslibs-dev git-core uuid-dev ocaml ocaml-findlib libx11-dev bison flex xz-utils libyajl-dev > Commandline: apt-get build-dep xen > Commandline: apt-get install texinfo > --------------------------------- snip --------------------- >Hello, when you compile the complete distribution from source (Hypervisor, utils, lib, libxenstore) than make sure that also the build dependencies of this packages are available on the system. As reference for Ubuntu I would check the build dependencies of the source packages of the 4.1 trunk from the Ubuntu repositories. Best Regards
Roger Pau Monné
2012-Oct-03 08:31 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
On 02/10/12 18:46, Ian Campbell wrote:> (Adding some CCs) > On Tue, 2012-10-02 at 17:31 +0100, Giorgio Mossa wrote: >> Hello everyone, >> I''m working on an Ubuntu 12.04 and I wanted to test >> Xen 4.2 (official repository offer just version 4.1), >> so I''ve downloaded the source tarball from the site, >> followed the instruction in the readme but when compiling >> I''m getting the following error: >> >> In file included from libxl_bootloader.c:21:0: >> /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] >> cc1: all warnings being treated as errors >> make[3]: *** [libxl_bootloader.o] Error 1 >> >> could anyone explain how to solve this problem, without disabling the warning/errors compilation options? > > Looks like someone has decided to move this header from /usr/include > to /usr/include/bsd and leave behind a #warning in the old location, > which has broken the way we do things. > > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=640895 seems to relate > to the fallout from this. > > I''m not sure when the include of libutil is needed, it''s not mentioned > in the Linux man pages and on Linux neither of the functions we purport > to need from it are actually present. Perhaps it''s a BSD only thing? > > Probably we need to check for bsd/libutil.h in preference to libutil.h > although the resolution of #640895 suggests that what we do now is > correct now that the bug is fixed, in which case a bug against Ubuntu > would be appropriate. > > Ian, Royer, What do you guys think?According to the man pages <libutil.h> is only needed on BSDs to be able to use openpty et al. Linux should not have this file, could you please try the following patch? It should prevent configure (and thus libxl) from including the bogus libutil.h header. --- From 250c0d533bab3c9705ade8e4bffed54abcb53b1c Mon Sep 17 00:00:00 2001 From: Roger Pau Monne <roger.pau@citrix.com> Date: Wed, 3 Oct 2012 10:22:21 +0200 Subject: [PATCH] autoconf: add -Werror to libutil.h header check libutil.h is only needed on BSDs, but not in Linux. Debian package libbsd-dev-0.3.0-1 installed a libutil.h overlay that contains a #warning, thus making libxl compilation broken due to -Werror. Perform the libutil.h check with -Werror, so we don''t include this bogus header. Signed-off-by: Roger Pau Monne <roger.pau@citrix.com> --- Please rerun autoconf after applying this patch --- tools/m4/ptyfuncs.m4 | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/tools/m4/ptyfuncs.m4 b/tools/m4/ptyfuncs.m4 index bfea3e1..3e37b5a 100644 --- a/tools/m4/ptyfuncs.m4 +++ b/tools/m4/ptyfuncs.m4 @@ -1,7 +1,14 @@ AC_DEFUN([AX_CHECK_PTYFUNCS], [ + dnl This is a workaround for a bug in Debian package + dnl libbsd-dev-0.3.0-1. Once we no longer support that + dnl package we can remove the addition of -Werror to + dnl CPPFLAGS. + AX_SAVEVAR_SAVE(CPPFLAGS) + CPPFLAGS="$CPPFLAGS -Werror" AC_CHECK_HEADER([libutil.h],[ AC_DEFINE([INCLUDE_LIBUTIL_H],[<libutil.h>],[libutil header file name]) ]) + AX_SAVEVAR_RESTORE(CPPFLAGS) AC_CACHE_CHECK([for openpty et al], [ax_cv_ptyfuncs_libs], [ for ax_cv_ptyfuncs_libs in -lutil "" NOT_FOUND; do if test "x$ax_cv_ptyfuncs_libs" = "xNOT_FOUND"; then -- 1.7.7.5 (Apple Git-26)
Roger Pau Monné
2012-Oct-03 08:31 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: [Xen-users] Problem compiling Xen 4.2 from sources)
On 02/10/12 18:46, Ian Campbell wrote:> (Adding some CCs) > On Tue, 2012-10-02 at 17:31 +0100, Giorgio Mossa wrote: >> Hello everyone, >> I''m working on an Ubuntu 12.04 and I wanted to test >> Xen 4.2 (official repository offer just version 4.1), >> so I''ve downloaded the source tarball from the site, >> followed the instruction in the readme but when compiling >> I''m getting the following error: >> >> In file included from libxl_bootloader.c:21:0: >> /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] >> cc1: all warnings being treated as errors >> make[3]: *** [libxl_bootloader.o] Error 1 >> >> could anyone explain how to solve this problem, without disabling the warning/errors compilation options? > > Looks like someone has decided to move this header from /usr/include > to /usr/include/bsd and leave behind a #warning in the old location, > which has broken the way we do things. > > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=640895 seems to relate > to the fallout from this. > > I''m not sure when the include of libutil is needed, it''s not mentioned > in the Linux man pages and on Linux neither of the functions we purport > to need from it are actually present. Perhaps it''s a BSD only thing? > > Probably we need to check for bsd/libutil.h in preference to libutil.h > although the resolution of #640895 suggests that what we do now is > correct now that the bug is fixed, in which case a bug against Ubuntu > would be appropriate. > > Ian, Royer, What do you guys think?According to the man pages <libutil.h> is only needed on BSDs to be able to use openpty et al. Linux should not have this file, could you please try the following patch? It should prevent configure (and thus libxl) from including the bogus libutil.h header. --- From 250c0d533bab3c9705ade8e4bffed54abcb53b1c Mon Sep 17 00:00:00 2001 From: Roger Pau Monne <roger.pau@citrix.com> Date: Wed, 3 Oct 2012 10:22:21 +0200 Subject: [PATCH] autoconf: add -Werror to libutil.h header check libutil.h is only needed on BSDs, but not in Linux. Debian package libbsd-dev-0.3.0-1 installed a libutil.h overlay that contains a #warning, thus making libxl compilation broken due to -Werror. Perform the libutil.h check with -Werror, so we don''t include this bogus header. Signed-off-by: Roger Pau Monne <roger.pau@citrix.com> --- Please rerun autoconf after applying this patch --- tools/m4/ptyfuncs.m4 | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/tools/m4/ptyfuncs.m4 b/tools/m4/ptyfuncs.m4 index bfea3e1..3e37b5a 100644 --- a/tools/m4/ptyfuncs.m4 +++ b/tools/m4/ptyfuncs.m4 @@ -1,7 +1,14 @@ AC_DEFUN([AX_CHECK_PTYFUNCS], [ + dnl This is a workaround for a bug in Debian package + dnl libbsd-dev-0.3.0-1. Once we no longer support that + dnl package we can remove the addition of -Werror to + dnl CPPFLAGS. + AX_SAVEVAR_SAVE(CPPFLAGS) + CPPFLAGS="$CPPFLAGS -Werror" AC_CHECK_HEADER([libutil.h],[ AC_DEFINE([INCLUDE_LIBUTIL_H],[<libutil.h>],[libutil header file name]) ]) + AX_SAVEVAR_RESTORE(CPPFLAGS) AC_CACHE_CHECK([for openpty et al], [ax_cv_ptyfuncs_libs], [ for ax_cv_ptyfuncs_libs in -lutil "" NOT_FOUND; do if test "x$ax_cv_ptyfuncs_libs" = "xNOT_FOUND"; then -- 1.7.7.5 (Apple Git-26)
Giorgio Mossa
2012-Oct-03 10:01 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
It seems the patch worked, thank you very much!!! On Wed, Oct 03, 2012 at 10:31:57AM +0200, Roger Pau Monné wrote:> > According to the man pages <libutil.h> is only needed on BSDs to be able > to use openpty et al. Linux should not have this file, could you please > try the following patch? It should prevent configure (and thus libxl) > from including the bogus libutil.h header. > > --- > >From 250c0d533bab3c9705ade8e4bffed54abcb53b1c Mon Sep 17 00:00:00 2001 > From: Roger Pau Monne <roger.pau@citrix.com> > Date: Wed, 3 Oct 2012 10:22:21 +0200 > Subject: [PATCH] autoconf: add -Werror to libutil.h header check > > libutil.h is only needed on BSDs, but not in Linux. Debian package > libbsd-dev-0.3.0-1 installed a libutil.h overlay that contains a > #warning, thus making libxl compilation broken due to -Werror. > > Perform the libutil.h check with -Werror, so we don''t include this > bogus header. > > Signed-off-by: Roger Pau Monne <roger.pau@citrix.com> > --- > Please rerun autoconf after applying this patch > --- > tools/m4/ptyfuncs.m4 | 7 +++++++ > 1 files changed, 7 insertions(+), 0 deletions(-) > > diff --git a/tools/m4/ptyfuncs.m4 b/tools/m4/ptyfuncs.m4 > index bfea3e1..3e37b5a 100644 > --- a/tools/m4/ptyfuncs.m4 > +++ b/tools/m4/ptyfuncs.m4 > @@ -1,7 +1,14 @@ > AC_DEFUN([AX_CHECK_PTYFUNCS], [ > + dnl This is a workaround for a bug in Debian package > + dnl libbsd-dev-0.3.0-1. Once we no longer support that > + dnl package we can remove the addition of -Werror to > + dnl CPPFLAGS. > + AX_SAVEVAR_SAVE(CPPFLAGS) > + CPPFLAGS="$CPPFLAGS -Werror" > AC_CHECK_HEADER([libutil.h],[ > AC_DEFINE([INCLUDE_LIBUTIL_H],[<libutil.h>],[libutil header file name]) > ]) > + AX_SAVEVAR_RESTORE(CPPFLAGS) > AC_CACHE_CHECK([for openpty et al], [ax_cv_ptyfuncs_libs], [ > for ax_cv_ptyfuncs_libs in -lutil "" NOT_FOUND; do > if test "x$ax_cv_ptyfuncs_libs" = "xNOT_FOUND"; then > -- > 1.7.7.5 (Apple Git-26)
Giorgio Mossa
2012-Oct-03 10:01 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: [Xen-users] Problem compiling Xen 4.2 from sources)
It seems the patch worked, thank you very much!!! On Wed, Oct 03, 2012 at 10:31:57AM +0200, Roger Pau Monné wrote:> > According to the man pages <libutil.h> is only needed on BSDs to be able > to use openpty et al. Linux should not have this file, could you please > try the following patch? It should prevent configure (and thus libxl) > from including the bogus libutil.h header. > > --- > >From 250c0d533bab3c9705ade8e4bffed54abcb53b1c Mon Sep 17 00:00:00 2001 > From: Roger Pau Monne <roger.pau@citrix.com> > Date: Wed, 3 Oct 2012 10:22:21 +0200 > Subject: [PATCH] autoconf: add -Werror to libutil.h header check > > libutil.h is only needed on BSDs, but not in Linux. Debian package > libbsd-dev-0.3.0-1 installed a libutil.h overlay that contains a > #warning, thus making libxl compilation broken due to -Werror. > > Perform the libutil.h check with -Werror, so we don''t include this > bogus header. > > Signed-off-by: Roger Pau Monne <roger.pau@citrix.com> > --- > Please rerun autoconf after applying this patch > --- > tools/m4/ptyfuncs.m4 | 7 +++++++ > 1 files changed, 7 insertions(+), 0 deletions(-) > > diff --git a/tools/m4/ptyfuncs.m4 b/tools/m4/ptyfuncs.m4 > index bfea3e1..3e37b5a 100644 > --- a/tools/m4/ptyfuncs.m4 > +++ b/tools/m4/ptyfuncs.m4 > @@ -1,7 +1,14 @@ > AC_DEFUN([AX_CHECK_PTYFUNCS], [ > + dnl This is a workaround for a bug in Debian package > + dnl libbsd-dev-0.3.0-1. Once we no longer support that > + dnl package we can remove the addition of -Werror to > + dnl CPPFLAGS. > + AX_SAVEVAR_SAVE(CPPFLAGS) > + CPPFLAGS="$CPPFLAGS -Werror" > AC_CHECK_HEADER([libutil.h],[ > AC_DEFINE([INCLUDE_LIBUTIL_H],[<libutil.h>],[libutil header file name]) > ]) > + AX_SAVEVAR_RESTORE(CPPFLAGS) > AC_CACHE_CHECK([for openpty et al], [ax_cv_ptyfuncs_libs], [ > for ax_cv_ptyfuncs_libs in -lutil "" NOT_FOUND; do > if test "x$ax_cv_ptyfuncs_libs" = "xNOT_FOUND"; then > -- > 1.7.7.5 (Apple Git-26)
This link might have a more accurate list of dependencies than 4.1 instructions: http://wiki.xen.org/wiki/Xen_4.2_RC2_test_instructions On Tue, Oct 2, 2012 at 4:02 PM, Lukas Laukamp <lukas@laukamp.me> wrote:> Am 02.10.2012 20:00, schrieb Mark Pryor: > > inline >> >> >> >> ----- Original Message ----- >> From: Giorgio Mossa <mossa@poisson.phc.unipi.it> >> To: xen-users@lists.xen.org >> Cc: >> Sent: Tuesday, October 2, 2012 9:31 AM >> Subject: [Xen-users] Problem compiling Xen 4.2 from sources >> >> Hello everyone, >> I''m working on an Ubuntu 12.04 and I wanted to test >> Xen 4.2 (official repository offer just version 4.1), >> so I''ve downloaded the source tarball from the site, >> followed the instruction in the readme but when compiling >> I''m getting the following error: >> >> In file included from libxl_bootloader.c:21:0: >> /usr/include/libutil.h:33:2: error: #warning "Deprecated header, use >> <bsd/libutil.h> or libbsd-overlay.pc instead." [-Werror=cpp] >> cc1: all warnings being treated as errors >> make[3]: *** [libxl_bootloader.o] Error 1 >> >> could anyone explain how to solve this problem, without disabling the >> warning/errors compilation options? >> >> -------------- >> >> As Dariusz said, missing texinfo stopped my build too. >> >> Here is my apt log: >> >> ------------------------- apt history ------------- >> $ sudo grep -i commandline /var/log/apt/history.log >> Commandline: apt-get install nano ubuntu-minimal openssh-server >> Commandline: apt-get install linux-image-server grub >> Commandline: apt-get upgrade >> Commandline: apt-get install build-essential >> Commandline: apt-get install bcc bin86 gawk bridge-utils iproute libcurl3 >> libcurl4-openssl-dev bzip2 module-init-tools transfig tgif >> Commandline: apt-get install make gcc libc6-dev zlib1g-dev python >> python-dev python-twisted libncurses5-dev patch libvncserver-dev libsdl-dev >> libjpeg-dev >> Commandline: apt-get install iasl libbz2-dev e2fslibs-dev git-core >> uuid-dev ocaml ocaml-findlib libx11-dev bison flex xz-utils libyajl-dev >> Commandline: apt-get build-dep xen >> Commandline: apt-get install texinfo >> ------------------------------**--- snip --------------------- >> >> > Hello, > > when you compile the complete distribution from source (Hypervisor, utils, > lib, libxenstore) than make sure that also the build dependencies of this > packages are available on the system. As reference for Ubuntu I would check > the build dependencies of the source packages of the 4.1 trunk from the > Ubuntu repositories. > > Best Regards > > > ______________________________**_________________ > Xen-users mailing list > Xen-users@lists.xen.org > http://lists.xen.org/xen-users >_______________________________________________ Xen-users mailing list Xen-users@lists.xen.org http://lists.xen.org/xen-users
Ian Campbell
2012-Oct-08 11:19 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: Problem compiling Xen 4.2 from sources)
On Wed, 2012-10-03 at 09:31 +0100, Roger Pau Monne wrote:> From 250c0d533bab3c9705ade8e4bffed54abcb53b1c Mon Sep 17 00:00:00 2001 > From: Roger Pau Monne <roger.pau@citrix.com> > Date: Wed, 3 Oct 2012 10:22:21 +0200 > Subject: [PATCH] autoconf: add -Werror to libutil.h header check > > libutil.h is only needed on BSDs, but not in Linux. Debian package > libbsd-dev-0.3.0-1 installed a libutil.h overlay that contains a > #warning, thus making libxl compilation broken due to -Werror. > > Perform the libutil.h check with -Werror, so we don''t include this > bogus header. > > Signed-off-by: Roger Pau Monne <roger.pau@citrix.com>Acked-by: Ian Campbell <ian.campbell@citrix.com> and applied. Arguably, since we compile with -Werror we should run configure with it too -- but I bet the fallout from doing that would be horrific though! Ian.
Ian Campbell
2012-Oct-08 11:19 UTC
Re: libutil.h moved to bsd/libutil.h (Was: Re: [Xen-users] Problem compiling Xen 4.2 from sources)
On Wed, 2012-10-03 at 09:31 +0100, Roger Pau Monne wrote:> From 250c0d533bab3c9705ade8e4bffed54abcb53b1c Mon Sep 17 00:00:00 2001 > From: Roger Pau Monne <roger.pau@citrix.com> > Date: Wed, 3 Oct 2012 10:22:21 +0200 > Subject: [PATCH] autoconf: add -Werror to libutil.h header check > > libutil.h is only needed on BSDs, but not in Linux. Debian package > libbsd-dev-0.3.0-1 installed a libutil.h overlay that contains a > #warning, thus making libxl compilation broken due to -Werror. > > Perform the libutil.h check with -Werror, so we don''t include this > bogus header. > > Signed-off-by: Roger Pau Monne <roger.pau@citrix.com>Acked-by: Ian Campbell <ian.campbell@citrix.com> and applied. Arguably, since we compile with -Werror we should run configure with it too -- but I bet the fallout from doing that would be horrific though! Ian.