Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Arnout Vandecappelle <arnout@mind.be>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/2] pkgconf: new package
Date: Tue, 25 Sep 2012 22:53:53 +0200	[thread overview]
Message-ID: <506219E1.5070508@mind.be> (raw)
In-Reply-To: <1348600115-27059-1-git-send-email-gustavo@zacarias.com.ar>

On 09/25/12 21:08, Gustavo Zacarias wrote:
> pkgconf is a drop-in replacement for pkg-config that doesn't need
> itself to build and just requires a C89 compiler.
>
> Instead of using a patch for hardcoded sysroot support (as the patch to
> pkg-config does) we instead rely on a wrapper script that takes the
> appropiate action.
>
> Signed-off-by: Gustavo Zacarias<gustavo@zacarias.com.ar>

Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>

  Minor nits below.

[snip]
> +HOST_PKGCONF_CONF_OPT = \
> +	--with-pkg-config-dir="$(STAGING_DIR)/usr/lib/pkgconfig:$(STAGING_DIR)/usr/share/pkgconfig"

  Since we anyway need a wrapper, wouldn't it be more consistent
to set PKG_CONFIG_PATH there instead?

> +
> +define PKGCONF_LINK_PKGCONFIG
> +	ln -sf pkgconf $(TARGET_DIR)/usr/bin/pkg-config
> +endef

  As long as pkg-config exists, I would wrap this in a
ifeq ($(BR2_PACKAGE_PKG_CONFIG),)


> +
> +define HOST_PKGCONF_INSTALL_WRAPPER
> +	$(INSTALL) -m 0755 -D package/pkgconf/pkg-config.in \
> +		$(HOST_DIR)/usr/bin/pkg-config
> +	$(SED) 's, at HOST_DIR@,$(HOST_DIR),' $(HOST_DIR)/usr/bin/pkg-config
> +	$(SED) 's, at STAGING_DIR@,$(STAGING_DIR),' $(HOST_DIR)/usr/bin/pkg-config
> +endef

  If for whatever reason, host-pkg-config is also built, the script
will be overwritten.  So to be safe, I'd remove host-pkg-config as well
(as a third patch).

> +
> +PKGCONF_POST_INSTALL_TARGET_HOOKS += PKGCONF_LINK_PKGCONFIG
> +HOST_PKGCONF_POST_INSTALL_HOOKS += HOST_PKGCONF_INSTALL_WRAPPER
> +
> +$(eval $(autotools-package))
> +$(eval $(host-autotools-package))
> +
> +PKG_CONFIG_HOST_BINARY:=$(HOST_DIR)/usr/bin/pkg-config

  Although this is just copy-pasted from pkg-config.mk, that's no reason
to break the buildroot conventions :-)

PKG_CONFIG_HOST_BINARY = $(HOST_DIR)/usr/bin/pkg-config



  Regards,
  Arnout

-- 
Arnout Vandecappelle                               arnout at mind be
Senior Embedded Software Architect                 +32-16-286540
Essensium/Mind                                     http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium                BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F

  parent reply	other threads:[~2012-09-25 20:53 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-25 19:08 [Buildroot] [PATCH 1/2] pkgconf: new package Gustavo Zacarias
2012-09-25 19:08 ` [Buildroot] [PATCH 2/2] packages: switch to pkgconf Gustavo Zacarias
2012-09-25 20:53 ` Arnout Vandecappelle [this message]
2012-09-25 21:00   ` [Buildroot] [PATCH 1/2] pkgconf: new package Gustavo Zacarias

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=506219E1.5070508@mind.be \
    --to=arnout@mind.be \
    --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