Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [RFC] Package infrastructure: make variables or make targets ?
Date: Tue, 3 Nov 2009 09:14:45 +0100	[thread overview]
Message-ID: <20091103091445.07b50723@surf> (raw)
In-Reply-To: <1257110818.2515.67.camel@coalu.atr>

Hello,

Thanks Lionel for your feedback.

Le Sun, 01 Nov 2009 22:26:58 +0100,
Lionel Landwerlin <llandwerlin@gmail.com> a ?crit :

> First thanks for your work. I like it much, it makes package's
> makefiles a lot more clean.

Thanks :)

> I have little question about the autotool stuff. I seen that the
> patching and the autoreconf steps has been merged together. Is it
> because you did not finish yet or do you plan keep it like that ?

I was planning to keep it like that, but if it's not satisfying, we can
probably find ways to improve it.

The generic package infrastructure, in package/Makefile.package.in [1]
is not supposed to know anything about autotools. Therefore, it
implements a set of generic steps :

 * Download
 * Extract
 * Patch
 * Configure
 * Build
 * Host installation
 * Target installation
 * Staging installation
 * Clean
 * Uninstall

? autoreconf ? is *not* one of these steps because it is autotools
specific.

Then, the package/Makefile.autotools.in [2] ? inherits ? from this
package infrastructure by :

 * Providing a definition for the Configure, Build, Host installation,
   Target installation, Staging installation, Clean and Uninstall
   steps ;

 * Add hooks for autoreconf and libtool patching. The autoreconf hook
   is attached to the $(PKG)_POST_PATCH_HOOKS hook point, and is
   therefore included into the generic ? Patch ? step in terms of stamp
   files and dependencies

Considering this more or less clean separation between generic
infrastructure and autotools infrastructure, I'd like (if possible) to
keep autotools-specific things outside the generic infrastructure.

> I'm asking that because I'm using buildroot more as a development tool
> than a rootfs generation tool. I try to work upstream with packages
> I'm hacking on. A few days ago I sent a patch to allow to retrigger
> some part of the build process on a particular package
> (http://lists.busybox.net/pipermail/buildroot/2009-October/030104.html).
> It currently only work with "autotooled" packages, but with you
> ongoing work it will be easier to provide that feature on all
> packages.
> 
> So to me, it is important to separate the patching from the
> autoreconfiguring part, because when adding new source files to an
> autotooled package there is a need to regenerate the Makefile.in files
> without repatching.

Would attaching the autoreconf hook to a
(not-yet-existing-but-easily-created) $(PKG)_PRE_CONFIGURE_HOOKS hook
point solve the problem ?

Sincerly,

Thomas

[1]
http://git.buildroot.net/~tpetazzoni/git/buildroot/tree/package/Makefile.package.in?h=package-infrastructure

[2]
http://git.buildroot.net/~tpetazzoni/git/buildroot/tree/package/Makefile.autotools.in?h=package-infrastructure
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com

  reply	other threads:[~2009-11-03  8:14 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-25 21:40 [Buildroot] [RFC] Package infrastructure: make variables or make targets ? Thomas Petazzoni
2009-10-25 23:51 ` Lionel Landwerlin
2009-10-26  8:35   ` Thomas Petazzoni
2009-10-27  8:06 ` Thomas Petazzoni
2009-10-29 15:39   ` Thomas Petazzoni
2009-10-29 17:11     ` H Hartley Sweeten
2009-10-29 21:01       ` Lionel Landwerlin
2009-10-29 17:41     ` Will Newton
2009-11-02 23:24     ` Thomas Petazzoni
2009-11-03  1:14       ` Lionel Landwerlin
2009-11-03  8:15         ` Thomas Petazzoni
2009-11-01 21:26   ` Lionel Landwerlin
2009-11-03  8:14     ` Thomas Petazzoni [this message]
2009-11-03 14:01       ` Lionel Landwerlin
2009-10-29 15:42 ` Thomas Petazzoni

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=20091103091445.07b50723@surf \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=buildroot@busybox.net \
    /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