* [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories
@ 2018-08-13 17:56 Christopher McCrory
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package Christopher McCrory
` (2 more replies)
0 siblings, 3 replies; 10+ messages in thread
From: Christopher McCrory @ 2018-08-13 17:56 UTC (permalink / raw)
To: buildroot
When perl modules have Makefiles in subdirectories, not all of the
arguments to Makefile.PL get propagated to subdirectory/Makefile.PL.
This causes compile failures. Two examples are template-toolkit and
xml-parser. A hack is to fix them after the usual configure step.
Something like this:
$(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(@D)/Expat/Makefile
for AR, CC, xFLAGS, etc. This "works", but there should be a better
way. Hence the RFC.
Also there is a package, libxml-parser-perl, that is a host only perl
xml-parser package needed by host-intltool and metacity. Should they
stay seprate or be merged?
Christopher McCrory (2):
perl-template-toolkit: new package
perl-xml-parser: new package
DEVELOPERS | 2 ++
package/Config.in | 2 ++
package/perl-template-toolkit/Config.in | 11 ++++++++
.../perl-template-toolkit.hash | 6 ++++
.../perl-template-toolkit/perl-template-toolkit.mk | 32 ++++++++++++++++++++++
5 files changed, 53 insertions(+)
create mode 100644 package/perl-template-toolkit/Config.in
create mode 100644 package/perl-template-toolkit/perl-template-toolkit.hash
create mode 100644 package/perl-template-toolkit/perl-template-toolkit.mk
--
2.14.4
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package
2018-08-13 17:56 [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories Christopher McCrory
@ 2018-08-13 17:56 ` Christopher McCrory
2018-08-14 4:21 ` François Perrad
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 2/2] perl-xml-parser: " Christopher McCrory
2018-08-13 21:03 ` [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories Thomas Petazzoni
2 siblings, 1 reply; 10+ messages in thread
From: Christopher McCrory @ 2018-08-13 17:56 UTC (permalink / raw)
To: buildroot
Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
---
DEVELOPERS | 1 +
package/Config.in | 1 +
package/perl-template-toolkit/Config.in | 11 ++++++++
.../perl-template-toolkit.hash | 6 ++++
.../perl-template-toolkit/perl-template-toolkit.mk | 32 ++++++++++++++++++++++
5 files changed, 51 insertions(+)
create mode 100644 package/perl-template-toolkit/Config.in
create mode 100644 package/perl-template-toolkit/perl-template-toolkit.hash
create mode 100644 package/perl-template-toolkit/perl-template-toolkit.mk
diff --git a/DEVELOPERS b/DEVELOPERS
index 6d0e3ecceb..d35cf3fb72 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -501,6 +501,7 @@ F: package/perl-params-util/
F: package/perl-sub-install/
F: package/perl-sys-meminfo/
F: package/perl-sys-mmap/
+F: package/perl-template-toolkit/
N: Clayton Shotwell <clayton.shotwell@rockwellcollins.com>
F: package/audit/
diff --git a/package/Config.in b/package/Config.in
index 85046ae56e..6437cc0451 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -728,6 +728,7 @@ menu "Perl libraries/modules"
source "package/perl-sub-install/Config.in"
source "package/perl-sys-meminfo/Config.in"
source "package/perl-sys-mmap/Config.in"
+ source "package/perl-template-toolkit/Config.in"
source "package/perl-time-hires/Config.in"
source "package/perl-timedate/Config.in"
source "package/perl-try-tiny/Config.in"
diff --git a/package/perl-template-toolkit/Config.in b/package/perl-template-toolkit/Config.in
new file mode 100644
index 0000000000..1caca074aa
--- /dev/null
+++ b/package/perl-template-toolkit/Config.in
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_PERL_TEMPLATE_TOOLKIT
+ bool "perl-template-toolkit"
+ depends on !BR2_STATIC_LIBS
+ select BR2_PACKAGE_PERL_APPCONFIG
+ help
+ comprehensive template processing system
+
+ https://metacpan.org/release/Template-Toolkit
+
+comment "perl-template-toolkit needs a toolchain w/ dynamic library"
+ depends on BR2_STATIC_LIBS
diff --git a/package/perl-template-toolkit/perl-template-toolkit.hash b/package/perl-template-toolkit/perl-template-toolkit.hash
new file mode 100644
index 0000000000..54d4553695
--- /dev/null
+++ b/package/perl-template-toolkit/perl-template-toolkit.hash
@@ -0,0 +1,6 @@
+# retrieved by scancpan from http://cpan.metacpan.org/
+md5 a7fae5d4fe5918f33105d92a62134067 Template-Toolkit-2.27.tar.gz
+sha256 1311a403264d0134c585af0309ff2a9d5074b8ece23ece5660d31ec96bf2c6dc Template-Toolkit-2.27.tar.gz
+
+# computed by scancpan
+sha256 d897b2d98affd4f0489340e54ceb542383101e3d21408dfad025df71d770d842 README
diff --git a/package/perl-template-toolkit/perl-template-toolkit.mk b/package/perl-template-toolkit/perl-template-toolkit.mk
new file mode 100644
index 0000000000..875437dead
--- /dev/null
+++ b/package/perl-template-toolkit/perl-template-toolkit.mk
@@ -0,0 +1,32 @@
+################################################################################
+#
+# perl-template-toolkit
+#
+################################################################################
+
+PERL_TEMPLATE_TOOLKIT_VERSION = 2.27
+PERL_TEMPLATE_TOOLKIT_SOURCE = Template-Toolkit-$(PERL_TEMPLATE_TOOLKIT_VERSION).tar.gz
+PERL_TEMPLATE_TOOLKIT_SITE = $(BR2_CPAN_MIRROR)/authors/id/A/AB/ABW
+PERL_TEMPLATE_TOOLKIT_DEPENDENCIES = perl-appconfig
+PERL_TEMPLATE_TOOLKIT_LICENSE = Artistic or GPL-1.0+
+PERL_TEMPLATE_TOOLKIT_LICENSE_FILES = README
+
+# There has got to be a better way... :(
+# Some arguments to Makefile.PL do not get propagated to subdirectories
+# similar to:
+# https://rt.cpan.org/Public/Bug/Display.html?id=28632
+define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
+ $(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(@D)/xs/Makefile
+ $(SED) "s:^FULL_AR = .*:FULL_AR = $(TARGET_AR):g" $(@D)/xs/Makefile
+ $(SED) "s:^CC = .*:CC = $(TARGET_CC):g" $(@D)/xs/Makefile
+ $(SED) "s:^CCFLAGS = .*:CCFLAGS = $(TARGET_CFLAGS):g" $(@D)/xs/Makefile
+ $(SED) "s:^LD = .*:LD = $(TARGET_CC):g" $(@D)/xs/Makefile
+ $(SED) "s:^LDDLFLAGS = .*:LDDLFLAGS = -shared $(TARGET_LDFLAGS):g" $(@D)/xs/Makefile
+ $(SED) "s:^LDLFLAGS = .*:LDLFLAGS = $(TARGET_LDFLAGS):g" $(@D)/xs/Makefile
+ $(SED) "s:^DESTDIR = .*:DESTDIR = $(TARGET_DIR):g" $(@D)/xs/Makefile
+endef
+
+PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_HOOKS += PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
+
+
+$(eval $(perl-package))
--
2.14.4
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 2/2] perl-xml-parser: new package
2018-08-13 17:56 [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories Christopher McCrory
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package Christopher McCrory
@ 2018-08-13 17:56 ` Christopher McCrory
2018-08-13 21:05 ` Thomas Petazzoni
2018-08-13 21:03 ` [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories Thomas Petazzoni
2 siblings, 1 reply; 10+ messages in thread
From: Christopher McCrory @ 2018-08-13 17:56 UTC (permalink / raw)
To: buildroot
Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
---
DEVELOPERS | 1 +
package/Config.in | 1 +
2 files changed, 2 insertions(+)
diff --git a/DEVELOPERS b/DEVELOPERS
index d35cf3fb72..8cd71c0cfd 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -502,6 +502,7 @@ F: package/perl-sub-install/
F: package/perl-sys-meminfo/
F: package/perl-sys-mmap/
F: package/perl-template-toolkit/
+F: package/perl-xml-parser/
N: Clayton Shotwell <clayton.shotwell@rockwellcollins.com>
F: package/audit/
diff --git a/package/Config.in b/package/Config.in
index 6437cc0451..a83015a819 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -736,6 +736,7 @@ menu "Perl libraries/modules"
source "package/perl-www-robotrules/Config.in"
source "package/perl-xml-libxml/Config.in"
source "package/perl-xml-namespacesupport/Config.in"
+ source "package/perl-xml-parser/Config.in"
source "package/perl-xml-sax/Config.in"
source "package/perl-xml-sax-base/Config.in"
endmenu
--
2.14.4
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories
2018-08-13 17:56 [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories Christopher McCrory
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package Christopher McCrory
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 2/2] perl-xml-parser: " Christopher McCrory
@ 2018-08-13 21:03 ` Thomas Petazzoni
2 siblings, 0 replies; 10+ messages in thread
From: Thomas Petazzoni @ 2018-08-13 21:03 UTC (permalink / raw)
To: buildroot
Hello,
On Mon, 13 Aug 2018 10:56:43 -0700, Christopher McCrory wrote:
> for AR, CC, xFLAGS, etc. This "works", but there should be a better
> way. Hence the RFC.
>
> Also there is a package, libxml-parser-perl, that is a host only perl
> xml-parser package needed by host-intltool and metacity. Should they
> stay seprate or be merged?
libxml-parser-perl is intentionally not using the perl-package
infrastructure, because we don't want to require building host-perl to
build host-intltool.
Some libxml-parser-perl is using the system-wide Perl, which is a
mandatory Buildroot dependency.
Perhaps we should add a comment in libxml-parser-perl.mk to explain
this.
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 2/2] perl-xml-parser: new package
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 2/2] perl-xml-parser: " Christopher McCrory
@ 2018-08-13 21:05 ` Thomas Petazzoni
2018-08-13 21:54 ` Christopher McCrory
0 siblings, 1 reply; 10+ messages in thread
From: Thomas Petazzoni @ 2018-08-13 21:05 UTC (permalink / raw)
To: buildroot
Hello,
On Mon, 13 Aug 2018 10:56:45 -0700, Christopher McCrory wrote:
> Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
This seems to be a partial patch.
Your patch series seems a bit messed up. You have sent:
RFC PATCH 0/2
RFC PATCH 1/2
RFC PATCH 2/2 (this patch, which is partial)
RFC PATCH 4/4
Could you fix this up and send a proper patch series ? If you're not
familiar yet with git send-email, I would suggest that you send your
patch series to yourself first, to make sure everything is correct,
before sending them to the Buildroot mailing list.
Thanks!
Thomas
--
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 2/2] perl-xml-parser: new package
2018-08-13 21:05 ` Thomas Petazzoni
@ 2018-08-13 21:54 ` Christopher McCrory
0 siblings, 0 replies; 10+ messages in thread
From: Christopher McCrory @ 2018-08-13 21:54 UTC (permalink / raw)
To: buildroot
Hello
On Mon, Aug 13, 2018, 2:05 PM Thomas Petazzoni <thomas.petazzoni@bootlin.com>
wrote:
> Hello,
>
> On Mon, 13 Aug 2018 10:56:45 -0700, Christopher McCrory wrote:
> > Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
>
> This seems to be a partial patch.
>
> Your patch series seems a bit messed up. You have sent:
>
> RFC PATCH 0/2
> RFC PATCH 1/2
> RFC PATCH 2/2 (this patch, which is partial)
> RFC PATCH 4/4
>
> Could you fix this up and send a proper patch series ? If you're not
> familiar yet with git send-email, I would suggest that you send your
> patch series to yourself first, to make sure everything is correct,
> before sending them to the Buildroot mailing list.
>
> On phone so formatting might be off. And I'm a little buzzed.
>
I had a mistake in that package and git reverted to re gen the commit, and
forgot the git add afterwards. I can regen, but is the whole sed thing the
way to deal with this quirk? Is there a better way that I am missing?
Hense the -- rfc.
And thank you for dealing with the whole Buildroot project.
>
> Thanks!
>
> Thomas
> --
> Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
> Embedded Linux and Kernel engineering
> https://bootlin.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20180813/c1f7095a/attachment.html>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package Christopher McCrory
@ 2018-08-14 4:21 ` François Perrad
2018-08-15 12:03 ` Christopher McCrory
0 siblings, 1 reply; 10+ messages in thread
From: François Perrad @ 2018-08-14 4:21 UTC (permalink / raw)
To: buildroot
2018-08-13 19:56 GMT+02:00 Christopher McCrory <chrismcc@gmail.com>:
> Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
> ---
> DEVELOPERS | 1 +
> package/Config.in | 1 +
> package/perl-template-toolkit/Config.in | 11 ++++++++
> .../perl-template-toolkit.hash | 6 ++++
> .../perl-template-toolkit/perl-template-toolkit.mk | 32
> ++++++++++++++++++++++
> 5 files changed, 51 insertions(+)
> create mode 100644 package/perl-template-toolkit/Config.in
> create mode 100644 package/perl-template-toolkit/
> perl-template-toolkit.hash
> create mode 100644 package/perl-template-toolkit/perl-template-toolkit.mk
>
> diff --git a/DEVELOPERS b/DEVELOPERS
> index 6d0e3ecceb..d35cf3fb72 100644
> --- a/DEVELOPERS
> +++ b/DEVELOPERS
> @@ -501,6 +501,7 @@ F: package/perl-params-util/
> F: package/perl-sub-install/
> F: package/perl-sys-meminfo/
> F: package/perl-sys-mmap/
> +F: package/perl-template-toolkit/
>
> N: Clayton Shotwell <clayton.shotwell@rockwellcollins.com>
> F: package/audit/
> diff --git a/package/Config.in b/package/Config.in
> index 85046ae56e..6437cc0451 100644
> --- a/package/Config.in
> +++ b/package/Config.in
> @@ -728,6 +728,7 @@ menu "Perl libraries/modules"
> source "package/perl-sub-install/Config.in"
> source "package/perl-sys-meminfo/Config.in"
> source "package/perl-sys-mmap/Config.in"
> + source "package/perl-template-toolkit/Config.in"
> source "package/perl-time-hires/Config.in"
> source "package/perl-timedate/Config.in"
> source "package/perl-try-tiny/Config.in"
> diff --git a/package/perl-template-toolkit/Config.in
> b/package/perl-template-toolkit/Config.in
> new file mode 100644
> index 0000000000..1caca074aa
> --- /dev/null
> +++ b/package/perl-template-toolkit/Config.in
> @@ -0,0 +1,11 @@
> +config BR2_PACKAGE_PERL_TEMPLATE_TOOLKIT
> + bool "perl-template-toolkit"
> + depends on !BR2_STATIC_LIBS
> + select BR2_PACKAGE_PERL_APPCONFIG
> + help
> + comprehensive template processing system
> +
> + https://metacpan.org/release/Template-Toolkit
> +
> +comment "perl-template-toolkit needs a toolchain w/ dynamic library"
> + depends on BR2_STATIC_LIBS
> diff --git a/package/perl-template-toolkit/perl-template-toolkit.hash
> b/package/perl-template-toolkit/perl-template-toolkit.hash
> new file mode 100644
> index 0000000000..54d4553695
> --- /dev/null
> +++ b/package/perl-template-toolkit/perl-template-toolkit.hash
> @@ -0,0 +1,6 @@
> +# retrieved by scancpan from http://cpan.metacpan.org/
> +md5 a7fae5d4fe5918f33105d92a62134067 Template-Toolkit-2.27.tar.gz
> +sha256 1311a403264d0134c585af0309ff2a9d5074b8ece23ece5660d31ec96bf2c6dc
> Template-Toolkit-2.27.tar.gz
> +
> +# computed by scancpan
> +sha256 d897b2d98affd4f0489340e54ceb542383101e3d21408dfad025df71d770d842
> README
> diff --git a/package/perl-template-toolkit/perl-template-toolkit.mk
> b/package/perl-template-toolkit/perl-template-toolkit.mk
> new file mode 100644
> index 0000000000..875437dead
> --- /dev/null
> +++ b/package/perl-template-toolkit/perl-template-toolkit.mk
> @@ -0,0 +1,32 @@
> +###########################################################
> #####################
> +#
> +# perl-template-toolkit
> +#
> +###########################################################
> #####################
> +
> +PERL_TEMPLATE_TOOLKIT_VERSION = 2.27
> +PERL_TEMPLATE_TOOLKIT_SOURCE = Template-Toolkit-$(PERL_
> TEMPLATE_TOOLKIT_VERSION).tar.gz
> +PERL_TEMPLATE_TOOLKIT_SITE = $(BR2_CPAN_MIRROR)/authors/id/A/AB/ABW
> +PERL_TEMPLATE_TOOLKIT_DEPENDENCIES = perl-appconfig
> +PERL_TEMPLATE_TOOLKIT_LICENSE = Artistic or GPL-1.0+
> +PERL_TEMPLATE_TOOLKIT_LICENSE_FILES = README
> +
> +# There has got to be a better way... :(
> +# Some arguments to Makefile.PL do not get propagated to subdirectories
> +# similar to:
> +# https://rt.cpan.org/Public/Bug/Display.html?id=28632
> +define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
> + $(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(@D)/xs/Makefile
> + $(SED) "s:^FULL_AR = .*:FULL_AR = $(TARGET_AR):g"
> $(@D)/xs/Makefile
> + $(SED) "s:^CC = .*:CC = $(TARGET_CC):g" $(@D)/xs/Makefile
> + $(SED) "s:^CCFLAGS = .*:CCFLAGS = $(TARGET_CFLAGS):g"
> $(@D)/xs/Makefile
> + $(SED) "s:^LD = .*:LD = $(TARGET_CC):g" $(@D)/xs/Makefile
> + $(SED) "s:^LDDLFLAGS = .*:LDDLFLAGS = -shared
> $(TARGET_LDFLAGS):g" $(@D)/xs/Makefile
> + $(SED) "s:^LDLFLAGS = .*:LDLFLAGS = $(TARGET_LDFLAGS):g"
> $(@D)/xs/Makefile
> + $(SED) "s:^DESTDIR = .*:DESTDIR = $(TARGET_DIR):g"
> $(@D)/xs/Makefile
> +endef
>
If you put this block of code in a function (in pkg-perl.mk) with the
filename as parameter,
you could just call it, in each module
define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
$(call,foo,$(@D)/xs/Makefile)
endef
Fran?ois
> +
> +PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_HOOKS += PERL_TEMPLATE_TOOLKIT_POST_
> CONFIGURE_SED
> +
> +
> +$(eval $(perl-package))
> --
> 2.14.4
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20180814/49392ddd/attachment.html>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package
2018-08-14 4:21 ` François Perrad
@ 2018-08-15 12:03 ` Christopher McCrory
2018-08-15 18:06 ` François Perrad
0 siblings, 1 reply; 10+ messages in thread
From: Christopher McCrory @ 2018-08-15 12:03 UTC (permalink / raw)
To: buildroot
hello
On Mon, Aug 13, 2018 at 9:21 PM, Fran?ois Perrad <francois.perrad@gadz.org>
wrote:
>
>
> 2018-08-13 19:56 GMT+02:00 Christopher McCrory <chrismcc@gmail.com>:
>
>> Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
>> ---
>>
>>
<snip>
> +# There has got to be a better way... :(
>> +# Some arguments to Makefile.PL do not get propagated to subdirectories
>> +# similar to:
>> +# https://rt.cpan.org/Public/Bug/Display.html?id=28632
>> +define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>> + $(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(@D)/xs/Makefile
>> + $(SED) "s:^FULL_AR = .*:FULL_AR = $(TARGET_AR):g"
>> $(@D)/xs/Makefile
>> + $(SED) "s:^CC = .*:CC = $(TARGET_CC):g" $(@D)/xs/Makefile
>> + $(SED) "s:^CCFLAGS = .*:CCFLAGS = $(TARGET_CFLAGS):g"
>> $(@D)/xs/Makefile
>> + $(SED) "s:^LD = .*:LD = $(TARGET_CC):g" $(@D)/xs/Makefile
>> + $(SED) "s:^LDDLFLAGS = .*:LDDLFLAGS = -shared
>> $(TARGET_LDFLAGS):g" $(@D)/xs/Makefile
>> + $(SED) "s:^LDLFLAGS = .*:LDLFLAGS = $(TARGET_LDFLAGS):g"
>> $(@D)/xs/Makefile
>> + $(SED) "s:^DESTDIR = .*:DESTDIR = $(TARGET_DIR):g"
>> $(@D)/xs/Makefile
>> +endef
>>
>
> If you put this block of code in a function (in pkg-perl.mk) with the
> filename as parameter,
> you could just call it, in each module
> define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
> $(call,foo,$(@D)/xs/Makefile)
> endef
>
>
My makefile skills aren't good enough to handle the subtleties of the
entire buildroot process. Is that something you want to handle? Or use
these as is until someone has some time to work on the pkg-perl.mk bits? Or
other?
Thanks for looking at all these packages I sent.
> Fran?ois
>
>
>> +
>> +PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_HOOKS +=
>> PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>> +
>> +
>> +$(eval $(perl-package))
>> --
>> 2.14.4
>>
>>
>
--
Christopher McCrory
To the optimist, the glass is half full.
To the pessimist, the glass is half empty.
To the engineer, the glass is twice as big as it needs to be.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20180815/bec7df93/attachment.html>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package
2018-08-15 12:03 ` Christopher McCrory
@ 2018-08-15 18:06 ` François Perrad
2018-08-15 20:24 ` Christopher McCrory
0 siblings, 1 reply; 10+ messages in thread
From: François Perrad @ 2018-08-15 18:06 UTC (permalink / raw)
To: buildroot
2018-08-15 14:03 GMT+02:00 Christopher McCrory <chrismcc@gmail.com>:
> hello
>
> On Mon, Aug 13, 2018 at 9:21 PM, Fran?ois Perrad <francois.perrad@gadz.org
> > wrote:
>
>>
>>
>> 2018-08-13 19:56 GMT+02:00 Christopher McCrory <chrismcc@gmail.com>:
>>
>>> Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
>>> ---
>>>
>>>
> <snip>
>
>
>> +# There has got to be a better way... :(
>>> +# Some arguments to Makefile.PL do not get propagated to subdirectories
>>> +# similar to:
>>> +# https://rt.cpan.org/Public/Bug/Display.html?id=28632
>>> +define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>>> + $(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(@D)/xs/Makefile
>>> + $(SED) "s:^FULL_AR = .*:FULL_AR = $(TARGET_AR):g"
>>> $(@D)/xs/Makefile
>>> + $(SED) "s:^CC = .*:CC = $(TARGET_CC):g" $(@D)/xs/Makefile
>>> + $(SED) "s:^CCFLAGS = .*:CCFLAGS = $(TARGET_CFLAGS):g"
>>> $(@D)/xs/Makefile
>>> + $(SED) "s:^LD = .*:LD = $(TARGET_CC):g" $(@D)/xs/Makefile
>>> + $(SED) "s:^LDDLFLAGS = .*:LDDLFLAGS = -shared
>>> $(TARGET_LDFLAGS):g" $(@D)/xs/Makefile
>>> + $(SED) "s:^LDLFLAGS = .*:LDLFLAGS = $(TARGET_LDFLAGS):g"
>>> $(@D)/xs/Makefile
>>> + $(SED) "s:^DESTDIR = .*:DESTDIR = $(TARGET_DIR):g"
>>> $(@D)/xs/Makefile
>>> +endef
>>>
>>
>> If you put this block of code in a function (in pkg-perl.mk) with the
>> filename as parameter,
>> you could just call it, in each module
>> define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>> $(call,foo,$(@D)/xs/Makefile)
>> endef
>>
>>
> My makefile skills aren't good enough to handle the subtleties of the
> entire buildroot process. Is that something you want to handle? Or use
> these as is until someone has some time to work on the pkg-perl.mk bits?
> Or other?
>
>
It is just like that :
define patch_sub_makefile
$(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(1)
$(SED) "s:^FULL_AR = .*:FULL_AR = $(TARGET_AR):g" $(1)
$(SED) "s:^CC = .*:CC = $(TARGET_CC):g" $(1)
$(SED) "s:^CCFLAGS = .*:CCFLAGS = $(TARGET_CFLAGS):g" $(1)
$(SED) "s:^LD = .*:LD = $(TARGET_CC):g" $(1)
$(SED) "s:^LDDLFLAGS = .*:LDDLFLAGS = -shared $(TARGET_LDFLAGS):g" $(1)
$(SED) "s:^LDLFLAGS = .*:LDLFLAGS = $(TARGET_LDFLAGS):g" $(1)
$(SED) "s:^DESTDIR = .*:DESTDIR = $(TARGET_DIR):g" $(1)
endef
define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
$(call patch_sub_makefile,$(@D)/xs/Makefile)
endef
Fran?ois
> Thanks for looking at all these packages I sent.
>
>
>> Fran?ois
>>
>>
>>> +
>>> +PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_HOOKS +=
>>> PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>>> +
>>> +
>>> +$(eval $(perl-package))
>>> --
>>> 2.14.4
>>>
>>>
>>
>
>
> --
> Christopher McCrory
> To the optimist, the glass is half full.
> To the pessimist, the glass is half empty.
> To the engineer, the glass is twice as big as it needs to be.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20180815/f15391c5/attachment.html>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package
2018-08-15 18:06 ` François Perrad
@ 2018-08-15 20:24 ` Christopher McCrory
0 siblings, 0 replies; 10+ messages in thread
From: Christopher McCrory @ 2018-08-15 20:24 UTC (permalink / raw)
To: buildroot
Sorry for top posting, on phone
I'll gen up a patch with this tomorrow. You are awesome!
On Wed, Aug 15, 2018, 11:06 AM Fran?ois Perrad <francois.perrad@gadz.org>
wrote:
>
>
> 2018-08-15 14:03 GMT+02:00 Christopher McCrory <chrismcc@gmail.com>:
>
>> hello
>>
>> On Mon, Aug 13, 2018 at 9:21 PM, Fran?ois Perrad <
>> francois.perrad at gadz.org> wrote:
>>
>>>
>>>
>>> 2018-08-13 19:56 GMT+02:00 Christopher McCrory <chrismcc@gmail.com>:
>>>
>>>> Signed-off-by: Christopher McCrory <chrismcc@gmail.com>
>>>> ---
>>>>
>>>>
>> <snip>
>>
>>
>>> +# There has got to be a better way... :(
>>>> +# Some arguments to Makefile.PL do not get propagated to subdirectories
>>>> +# similar to:
>>>> +# https://rt.cpan.org/Public/Bug/Display.html?id=28632
>>>> +define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>>>> + $(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(@D)/xs/Makefile
>>>> + $(SED) "s:^FULL_AR = .*:FULL_AR = $(TARGET_AR):g"
>>>> $(@D)/xs/Makefile
>>>> + $(SED) "s:^CC = .*:CC = $(TARGET_CC):g" $(@D)/xs/Makefile
>>>> + $(SED) "s:^CCFLAGS = .*:CCFLAGS = $(TARGET_CFLAGS):g"
>>>> $(@D)/xs/Makefile
>>>> + $(SED) "s:^LD = .*:LD = $(TARGET_CC):g" $(@D)/xs/Makefile
>>>> + $(SED) "s:^LDDLFLAGS = .*:LDDLFLAGS = -shared
>>>> $(TARGET_LDFLAGS):g" $(@D)/xs/Makefile
>>>> + $(SED) "s:^LDLFLAGS = .*:LDLFLAGS = $(TARGET_LDFLAGS):g"
>>>> $(@D)/xs/Makefile
>>>> + $(SED) "s:^DESTDIR = .*:DESTDIR = $(TARGET_DIR):g"
>>>> $(@D)/xs/Makefile
>>>> +endef
>>>>
>>>
>>> If you put this block of code in a function (in pkg-perl.mk) with the
>>> filename as parameter,
>>> you could just call it, in each module
>>> define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>>> $(call,foo,$(@D)/xs/Makefile)
>>> endef
>>>
>>>
>> My makefile skills aren't good enough to handle the subtleties of the
>> entire buildroot process. Is that something you want to handle? Or use
>> these as is until someone has some time to work on the pkg-perl.mk bits?
>> Or other?
>>
>>
> It is just like that :
>
> define patch_sub_makefile
> $(SED) "s:^AR = .*:AR = $(TARGET_AR):g" $(1)
> $(SED) "s:^FULL_AR = .*:FULL_AR = $(TARGET_AR):g" $(1)
> $(SED) "s:^CC = .*:CC = $(TARGET_CC):g" $(1)
> $(SED) "s:^CCFLAGS = .*:CCFLAGS = $(TARGET_CFLAGS):g" $(1)
> $(SED) "s:^LD = .*:LD = $(TARGET_CC):g" $(1)
> $(SED) "s:^LDDLFLAGS = .*:LDDLFLAGS = -shared $(TARGET_LDFLAGS):g" $(1)
> $(SED) "s:^LDLFLAGS = .*:LDLFLAGS = $(TARGET_LDFLAGS):g" $(1)
> $(SED) "s:^DESTDIR = .*:DESTDIR = $(TARGET_DIR):g" $(1)
> endef
>
> define PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
> $(call patch_sub_makefile,$(@D)/xs/Makefile)
> endef
>
> Fran?ois
>
>
>
>> Thanks for looking at all these packages I sent.
>>
>>
>>> Fran?ois
>>>
>>>
>>>> +
>>>> +PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_HOOKS +=
>>>> PERL_TEMPLATE_TOOLKIT_POST_CONFIGURE_SED
>>>> +
>>>> +
>>>> +$(eval $(perl-package))
>>>> --
>>>> 2.14.4
>>>>
>>>>
>>>
>>
>>
>> --
>> Christopher McCrory
>> To the optimist, the glass is half full.
>> To the pessimist, the glass is half empty.
>> To the engineer, the glass is twice as big as it needs to be.
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20180815/390a6283/attachment.html>
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2018-08-15 20:24 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-13 17:56 [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories Christopher McCrory
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 1/2] perl-template-toolkit: new package Christopher McCrory
2018-08-14 4:21 ` François Perrad
2018-08-15 12:03 ` Christopher McCrory
2018-08-15 18:06 ` François Perrad
2018-08-15 20:24 ` Christopher McCrory
2018-08-13 17:56 ` [Buildroot] [RFC PATCH 2/2] perl-xml-parser: " Christopher McCrory
2018-08-13 21:05 ` Thomas Petazzoni
2018-08-13 21:54 ` Christopher McCrory
2018-08-13 21:03 ` [Buildroot] [RFC PATCH 0/2] Hack for perl module subdirectories Thomas Petazzoni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox