All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] package/rrdtool: add support for perl bindings
@ 2016-06-23  7:12 Yann E. MORIN
  2016-06-24 15:58 ` Thomas Petazzoni
  0 siblings, 1 reply; 3+ messages in thread
From: Yann E. MORIN @ 2016-06-23  7:12 UTC (permalink / raw)
  To: buildroot

From: Cedric Chedaleux <cedric.chedaleux@orange.com>

Signed-off-by: Cedric Chedaleux <cedric.chedaleux@orange.com>
[yann.morin at orange.com: slight cleanup in code layout, change leading
spaces with leading tabs, rebase on top of master]
Signed-off-by: "Yann E. MORIN" <yann.morin@orange.com>
---
 package/rrdtool/rrdtool.mk | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/package/rrdtool/rrdtool.mk b/package/rrdtool/rrdtool.mk
index 6d6ab0c..589e4a3 100644
--- a/package/rrdtool/rrdtool.mk
+++ b/package/rrdtool/rrdtool.mk
@@ -19,11 +19,22 @@ RRDTOOL_CONF_OPTS = \
 	--disable-librados \
 	--disable-libwrap \
 	--disable-lua \
-	--disable-perl \
 	--disable-python \
 	--disable-ruby \
 	--disable-tcl
 
+ifeq ($(BR2_PACKAGE_PERL),y)
+RRDTOOL_DEPENDENCIES += host-perl
+RRDTOOL_CONF_OPTS += --enable-perl
+RRDTOOL_CONF_ENV += \
+	ac_cv_path_PERL=$(HOST_DIR)/usr/bin/perl \
+	PERLCC="$(TARGET_CC_NOCCACHE)" \
+	PERLCCFLAGS="$(TARGET_CFLAGS)" \
+	PERLLDFLAGS="$(TARGET_LDFLAGS)"
+else
+RRDTOOL_CONF_OPTS += --disable-perl
+endif
+
 ifeq ($(BR2_PACKAGE_RRDTOOL_RRDGRAPH),y)
 RRDTOOL_DEPENDENCIES += cairo pango
 else
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [Buildroot] [PATCH] package/rrdtool: add support for perl bindings
  2016-06-23  7:12 [Buildroot] [PATCH] package/rrdtool: add support for perl bindings Yann E. MORIN
@ 2016-06-24 15:58 ` Thomas Petazzoni
  2016-06-28  8:30   ` yann.morin at orange.com
  0 siblings, 1 reply; 3+ messages in thread
From: Thomas Petazzoni @ 2016-06-24 15:58 UTC (permalink / raw)
  To: buildroot

Hello,

On Thu, 23 Jun 2016 09:12:43 +0200, Yann E. MORIN wrote:

> +ifeq ($(BR2_PACKAGE_PERL),y)
> +RRDTOOL_DEPENDENCIES += host-perl

It is somewhat weird, one would expect to see a dependency on "perl"
here, not "host-perl".

However, maybe you simply need host-perl at *build* time to build the
bindings, and the target perl is only needed at *runtime*. If that's
the case, then a comment above this dependency would be good to have.

If you confirm my understanding, I can also just add the comment when
applying.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Buildroot] [PATCH] package/rrdtool: add support for perl bindings
  2016-06-24 15:58 ` Thomas Petazzoni
@ 2016-06-28  8:30   ` yann.morin at orange.com
  0 siblings, 0 replies; 3+ messages in thread
From: yann.morin at orange.com @ 2016-06-28  8:30 UTC (permalink / raw)
  To: buildroot

Thomas, All,

On 2016-06-24 17:58 +0200, Thomas Petazzoni spake thusly:
> On Thu, 23 Jun 2016 09:12:43 +0200, Yann E. MORIN wrote:
> > +ifeq ($(BR2_PACKAGE_PERL),y)
> > +RRDTOOL_DEPENDENCIES += host-perl
> It is somewhat weird, one would expect to see a dependency on "perl"
> here, not "host-perl".
> 
> However, maybe you simply need host-perl at *build* time to build the
> bindings, and the target perl is only needed at *runtime*. If that's
> the case, then a comment above this dependency would be good to have.
> 
> If you confirm my understanding, I can also just add the comment when
> applying.

In fact, the host-perl is only used for a few things:

 1- extract some configuration:

    - the perl version: we need host-perl because otherwise the host
      system perl may be a different version;

    - the compiler used to build perl: this is not OK, because we'd get
      the host compiler, not the target one. This is why we override it
      in the RRDTOOL_CONF_ENV.

 2- generate the Makefiles from Makefile.PL templates.


However, I withdraw this patch, as it breaks now with the paranoid
wrapper. I'll fix that in the coming days.

Regards,
Yann E. MORIN.

-- 
                                        ____________
.-----------------.--------------------:       _    :------------------.
|  Yann E. MORIN  | Real-Time Embedded |    __/ )   | /"\ ASCII RIBBON |
| +33 299.124.769 | Software  Designer |  _/ - /'   | \ / CAMPAIGN     |
|         824.769 '--------------------: (_    `--, |  X  AGAINST      |
|      yann.morin (at) orange.com      |_="    ,--' | / \ HTML MAIL    |
'--------------------------------------:______/_____:------------------'


_________________________________________________________________________________________________________________________

Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc
pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler
a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration,
Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci.

This message and its attachments may contain confidential or privileged information that may be protected by law;
they should not be distributed, used or copied without authorisation.
If you have received this email in error, please notify the sender and delete this message and its attachments.
As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified.
Thank you.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-06-28  8:30 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-23  7:12 [Buildroot] [PATCH] package/rrdtool: add support for perl bindings Yann E. MORIN
2016-06-24 15:58 ` Thomas Petazzoni
2016-06-28  8:30   ` yann.morin at orange.com

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.