Patchwork Fix out-of-tree and cross compile builds for pixman

login
register
mail settings
Submitter Eric Johnson
Date Nov. 7, 2012, 8:57 p.m.
Message ID <AD431C1EF67D4B4B801AEC089EB7ED4801448878C5@exchdb03.mips.com>
Download mbox | patch
Permalink /patch/197729/
State New
Headers show

Comments

Eric Johnson - Nov. 7, 2012, 8:57 p.m.
Sorry, I didn’t let the make finish but I think there will be linking errors with the previous because libpixman-1.a may not be built.

The following changes to Gerd's rebase/pixman branch will completely build (except s390x).
On RHEL 5.7 (no pixman on system):
$ ../kraxel.org/configure --without-system-pixman
$ make -k -j8


cc1: warnings being treated as errors
/home/ericj/work/qemu/kraxel.org/hw/s390x/event-facility.c: In function 'command_handler':
/home/ericj/work/qemu/kraxel.org/hw/s390x/event-facility.c:110: warning: 'rc' may be used uninitialized in this function
make[1]: *** [hw/s390x/event-facility.o] Error 1

> -----Original Message-----

> From: qemu-devel-bounces+ericj=mips.com@nongnu.org [mailto:qemu-devel-

> bounces+ericj=mips.com@nongnu.org] On Behalf Of Johnson, Eric

> Sent: Wednesday, November 07, 2012 12:07 PM

> To: Gerd Hoffmann; Blue Swirl

> Cc: Peter Maydell; qemu-devel@nongnu.org

> Subject: Re: [Qemu-devel] [PATCH] Fix out-of-tree and cross compile builds

> for pixman

> 

> This may not be the prettiest fix for the pixman dependency but it seems

> to work.

> 

> diff --git a/configure b/configure

> index f0bc726..fcb744e 100755

> --- a/configure

> +++ b/configure

> @@ -4154,6 +4154,10 @@ echo "QEMU_CFLAGS+=$cflags" >> $config_target_mak

>  echo "QEMU_INCLUDES+=$includes" >> $config_target_mak

> 

>  done # for target in $targets

> +

> +if [ "$pixman" = "internal" ]; then

> +  echo "config-host.h: pixman/Makefile" >> $config_host_mak

> +fi

> 

>  # build tree in object directory in case the source is not in the current

> directory

>  DIRS="tests tests/tcg tests/tcg/cris tests/tcg/lm32"

> 

> > -----Original Message-----

> > From: qemu-devel-bounces+ericj=mips.com@nongnu.org [mailto:qemu-devel-

> > bounces+ericj=mips.com@nongnu.org] On Behalf Of Gerd Hoffmann

> > Sent: Wednesday, November 07, 2012 3:43 AM

> > To: Blue Swirl

> > Cc: Peter Maydell; qemu-devel@nongnu.org

> > Subject: Re: [Qemu-devel] [PATCH] Fix out-of-tree and cross compile

> builds

> > for pixman

> >

> > On 11/03/12 21:15, Blue Swirl wrote:

> > > On Sat, Nov 3, 2012 at 7:02 PM, Peter Maydell

> <peter.maydell@linaro.org>

> > wrote:

> > >> On 3 November 2012 19:47, Blue Swirl <blauwirbel@gmail.com> wrote:

> > >>> --- a/Makefile

> > >>> +++ b/Makefile

> > >>> @@ -122,7 +122,7 @@ subdir-pixman: pixman/Makefile

> > >>>         $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C pixman

> > V="$(V)" all,)

> > >>>

> > >>>  pixman/Makefile: $(SRC_PATH)/pixman/configure

> > >>> -       (cd pixman; $(SRC_PATH)/pixman/configure --disable-shared --

> > enable-static)

> > >>> +       (cd pixman; CC=$(CC) LD=$(LD) AR=$(AR) NM=$(NM)

> > RANLIB=$(RANLIB) $(SRC_PATH)/pixman/configure --disable-shared --enable-

> > static)

> > >>

> > >> Not tested, but aren't there quoting issues here if you're

> > >> building with --cc='ccache gcc' ?

> > >

> > > Yes. Also configure fails because the variables are not expanded and

> > > directory pixman/pixman does not exist. Funny how it worked earlier.

> >

> > Turned out part of the issue is that having pixman-devel installed

> > masked some of the build issues of the internal pixman even when

> > building --without-pixman-system, so my build testing was incomplete.

> >

> > Pushed test branch:

> >   git://git.kraxel.org/qemu rebase/pixman

> >

> > Dependency issue isn't tackled yet, but non-parallel builds are working

> > fine for me.  Feedback is welcome.

> >

> > cheers,

> >   Gerd

> >

Patch

diff --git a/configure b/configure

index f0bc726..d946937 100755

--- a/configure

+++ b/configure

@@ -3955,9 +3955,6 @@  if test "$target_softmmu" = "yes" ; then

   if test "$smartcard_nss" = "yes" ; then
     echo "subdir-$target: subdir-libcacard" >> $config_host_mak
   fi
-  if test "$pixman" = "internal" ; then

-    echo "subdir-$target: subdir-pixman" >> $config_host_mak

-  fi

   case "$target_arch2" in
     i386|x86_64)
       echo "CONFIG_HAVE_CORE_DUMP=y" >> $config_target_mak
@@ -4154,6 +4151,10 @@  echo "QEMU_CFLAGS+=$cflags" >> $config_target_mak

 echo "QEMU_INCLUDES+=$includes" >> $config_target_mak

 done # for target in $targets
+ 

+if [ "$pixman" = "internal" ]; then

+  echo "config-host.h: subdir-pixman" >> $config_host_mak

+fi


 # build tree in object directory in case the source is not in the current directory
 DIRS="tests tests/tcg tests/tcg/cris tests/tcg/lm32"