qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: "Lluís Vilanova" <vilanova@ac.upc.edu>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] build: Use separate makefile for "trace/"
Date: Fri, 14 Dec 2012 03:14:03 -0500 (EST)	[thread overview]
Message-ID: <1936665411.23874741.1355472843936.JavaMail.root@redhat.com> (raw)
In-Reply-To: <87mwxi81b5.fsf@fimbulvetr.bsc.es>


> > Yeah, make it
> 
> > oslib-obj-y += trace/
> 
> > and get rid of trace-obj-y.
> 
> Mmm, but according to Makefile.objs:
> 
>   oslib-obj-y is code depending on the OS (win32 vs posix)

True... I'd like to simplify this jungle sooner or later though.

We can keep trace-obj-y, but please do leave out qemu-timer-common.o

> > > I'm not sure how the subdir magic treats paths, but mapping all paths
> > > in final vars into their respective absolute path should simplify things.
> 
> > Difficult to do in make. :(
> 
> Among many other things, AFAIR the linux kernel build system uses absolute
> paths, but I think it also uses make to get into each subdirectory (as opposed
> to QEMU), which I simplifies coding such a build system.

We already use recursive make to compile each target.  I think the current QEMU
build system is a good balance between non-recursive and recursive make.

> > I'm sure this has already been previously discussed to the point of extenuation,
> > but what are the reasons for not using autotools?
> 
> > Autoconf -> no point, but someone needs to do the work.
> 
> > Automake -> the build system is just too different.
> 
> > Libtool -> using it already. :)
> 
> 
> Ok, so it's not something against the suite per-se, but about porting work.
> 
> The thing I like about automake is that it provides a clear set of vars to
> manage the per-dir builds, thanks to using a per-dir $(MAKE); but I'm
> not sure how the per-target build would be managed (except by having a
> separate configure+make for each of them).

Yes, that would be it.  Even an autoconf conversion probably would have
to use separate configure scripts for the global project and for each
target.

> This could also be provided by having the QEMU build infrastructure use $(MAKE)
> to enter into each directory, and having it produce an ar file (or a
> set of them) with a "standard" name as a result (using libtool).

Doesn't need to use libtool.  Static libraries are just fine.  The problem
is that ar doesn't work well with constructors, which we use for module.c.
It is what QEMU used to use, but Andreas moved away a couple of years ago
and I think it is an improvement.

> But I'm not sure how well would that work when building in Windows
> (is libtool available there?).

Yes.

Paolo

  reply	other threads:[~2012-12-14  9:37 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-11 21:44 [Qemu-devel] [PATCH] build: Use separate makefile for "trace/" Lluís Vilanova
2012-12-12  8:43 ` Paolo Bonzini
2012-12-12 14:53   ` Lluís Vilanova
2012-12-13  8:44     ` Paolo Bonzini
2012-12-13 14:38       ` Lluís Vilanova
2012-12-14  8:14         ` Paolo Bonzini [this message]
2012-12-14 13:46           ` Lluís Vilanova
2012-12-14 13:50             ` Paolo Bonzini
2012-12-14 15:04               ` Lluís Vilanova
  -- strict thread matches above, loose matches on Subject: below --
2012-12-11 21:49 Lluís Vilanova
2012-12-14 18:34 Lluís Vilanova

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1936665411.23874741.1355472843936.JavaMail.root@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=vilanova@ac.upc.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).