pkg-perl: add PREFER_INSTALLER variable
PATCH v2 1/3 pkg-perl: add PREFER_INSTALLER variable
--- docs/manual/adding-packages-perl.txt | 8 ++++++-- package/pkg-perl.mk | 20 ++++++++++++++------ 2 files changed, 20 insertions(+), 8 deletions(-)
docs/manual/adding-packages-perl.txt +6 -2
@@ -68,8 +68,8 @@ As a policy, packages that provide Perl/CPAN modules should all be named +perl-<something>+ in Buildroot. This infrastructure handles various Perl build systems : -+ExtUtils-MakeMaker+, +Module-Build+ and +Module-Build-Tiny+. -+Build.PL+ is always preferred when a package provides a +Makefile.PL+ ++ExtUtils-MakeMaker+ (EUMM), +Module-Build+ (MB) and +Module-Build-Tiny+. ++Build.PL+ is preferred by default when a package provides a +Makefile.PL+ and a +Build.PL+. The main macro of the Perl/CPAN package infrastructure is
@@ -97,6 +97,10 @@ A few additional variables, specific to the Perl/CPAN infrastructure, can also be defined. Many of them are only useful in very specific cases, typical packages will therefore only use a few of them. +* +PERL_FOO_PREFER_INSTALLER+/+HOST_PERL_FOO_PREFER_INSTALLER+, with the + value 'EUMM', the use of +Makefile.PL+ is prefered at +Build.PL+. + By default, 'MB'. + * +PERL_FOO_CONF_ENV+/+HOST_PERL_FOO_CONF_ENV+, to specify additional environment variables to pass to the +perl Makefile.PL+ or +perl Build.PL+. By default, empty.
package/pkg-perl.mk +14 -6
@@ -49,6 +49,14 @@ else $(2)_DEPENDENCIES += host-perl endif +# From http://perldoc.perl.org/CPAN.html#Config-Variables - prefer_installer +# legal values are MB and EUMM: if a module comes +# with both a Makefile.PL and a Build.PL, use the +# former (EUMM) or the latter (MB); if the module +# comes with only one of the two, that one will be +# used no matter the setting +$(2)_PREFER_INSTALLER ?= MB + # # Configure step. Only define it if not already defined by the package # .mk file. And take care of the differences between host and target
@@ -59,7 +67,7 @@ ifeq ($(4),target) # Configure package for target define $(2)_CONFIGURE_CMDS - cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] ; then \ + cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] && [ $$($(2)_PREFER_INSTALLER) != "EUMM" ] ; then \ $$($(2)_CONF_ENV) \ PERL_MM_USE_DEFAULT=1 \ $$(PERL_RUN) Build.PL \
@@ -109,7 +117,7 @@ else # Configure package for host define $(2)_CONFIGURE_CMDS - cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] ; then \ + cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] && [ $$($(2)_PREFER_INSTALLER) != "EUMM" ] ; then \ $$($(2)_CONF_ENV) \ PERL_MM_USE_DEFAULT=1 \ $$(PERL_RUN) Build.PL \
@@ -135,7 +143,7 @@ ifeq ($(4),target) # Build package for target define $(2)_BUILD_CMDS - cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] ; then \ + cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] && [ $$($(2)_PREFER_INSTALLER) != "EUMM" ] ; then \ $$(PERL_RUN) Build $$($(2)_BUILD_OPTS) build; \ else \ $$(MAKE1) \
@@ -148,7 +156,7 @@ else # Build package for host define $(2)_BUILD_CMDS - cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] ; then \ + cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] && [ $$($(2)_PREFER_INSTALLER) != "EUMM" ] ; then \ $$(PERL_RUN) Build $$($(2)_BUILD_OPTS) build; \ else \ $$(MAKE1) $$($(2)_BUILD_OPTS) pure_all; \
@@ -163,7 +171,7 @@ endif # ifndef $(2)_INSTALL_CMDS define $(2)_INSTALL_CMDS - cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] ; then \ + cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] && [ $$($(2)_PREFER_INSTALLER) != "EUMM" ] ; then \ $$(PERL_RUN) Build $$($(2)_INSTALL_TARGET_OPTS) install; \ else \ $$(MAKE1) $$($(2)_INSTALL_TARGET_OPTS) pure_install; \
@@ -177,7 +185,7 @@ endif # ifndef $(2)_INSTALL_TARGET_CMDS define $(2)_INSTALL_TARGET_CMDS - cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] ; then \ + cd $$($$(PKG)_SRCDIR) && if [ -f Build.PL ] && [ $$($(2)_PREFER_INSTALLER) != "EUMM" ] ; then \ $$(PERL_RUN) Build $$($(2)_INSTALL_TARGET_OPTS) install; \ else \ $$(MAKE1) $$($(2)_INSTALL_TARGET_OPTS) pure_install; \
Signature · 1 line
2.9.3
PATCH v2 2/3 perl-gd: bump to version 2.56
Now, GD supplies a Build.PL, but this one is not cross-compil friendly. So, we still use Makefile.PL like in previous version.
--- package/perl-gd/0002-lgd.patch | 4 ++-- package/perl-gd/0003-force.patch | 2 +- package/perl-gd/0004-gdlib-config-is-now-configurable.patch | 2 +- package/perl-gd/Config.in | 2 +- package/perl-gd/perl-gd.hash | 4 ++-- package/perl-gd/perl-gd.mk | 5 +++-- 6 files changed, 10 insertions(+), 9 deletions(-)
package/perl-gd/0002-lgd.patch +2 -2
@@ -7,7 +7,7 @@ Index: b/Makefile.PL =================================================================== --- a/Makefile.PL +++ b/Makefile.PL -@@ -34,9 +34,9 @@ +@@ -42,9 +42,9 @@ END }
@@ -18,7 +18,7 @@ Index: b/Makefile.PL # support for AMD64 libraries if (-d '/usr/lib64') { -@@ -291,7 +291,6 @@ +@@ -294,7 +294,6 @@ @$LIBPATH = map {s/^-L// && "-L$_"} split /\s+/,$ldflags; @$LIBS = split /\s+/,$libs;
package/perl-gd/0003-force.patch +1 -1
@@ -7,7 +7,7 @@ Index: b/Makefile.PL =================================================================== --- a/Makefile.PL +++ b/Makefile.PL -@@ -35,13 +35,15 @@ +@@ -43,13 +43,15 @@ } push @LIBS, "-lgd";
package/perl-gd/0004-gdlib-config-is-now-configurable.patch +1 -1
@@ -53,7 +53,7 @@ index dfe8ad7..0fa6ef3 100644 ############################################################################################# if ($^O eq 'VMS'){ -@@ -275,7 +286,7 @@ exit 0; +@@ -278,7 +289,7 @@ exit 0; sub try_to_autoconfigure { my ($options,$lib_gd_path,$INC,$LIBPATH,$LIBS) = @_;
package/perl-gd/Config.in +1 -1
@@ -6,7 +6,7 @@ config BR2_PACKAGE_PERL_GD select BR2_PACKAGE_FREETYPE select BR2_PACKAGE_GD help - Interface to Gd Graphics Library + Perl interface to the gd2 graphics library https://metacpan.org/release/GD
package/perl-gd/perl-gd.hash +2 -2
@@ -1,3 +1,3 @@ # retrieved by scancpan from http://cpan.metacpan.org/ -md5 d2c9b18123bcaff8672eb50f2eb37ed3 GD-2.53.tar.gz -sha256 d05d01fe95e581adb3468cf05ab5d405db7497c0fb3ec7ecf23d023705fab7aa GD-2.53.tar.gz +md5 c4b3afd98b2c4ce3c2e1027d101a8f1e GD-2.56.tar.gz +sha256 1f103d1c98de8621504642ed7fb79f1b40f5f6a63c2abe9390a8ab78617248f9 GD-2.56.tar.gz
package/perl-gd/perl-gd.mk +3 -2
@@ -4,12 +4,13 @@ # ################################################################################ -PERL_GD_VERSION = 2.53 +PERL_GD_VERSION = 2.56 PERL_GD_SOURCE = GD-$(PERL_GD_VERSION).tar.gz PERL_GD_SITE = $(BR2_CPAN_MIRROR)/authors/id/L/LD/LDS PERL_GD_DEPENDENCIES = zlib libpng freetype gd -PERL_GD_LICENSE = Artistic-2.0 or GPLv1+ +PERL_GD_LICENSE = Artistic or GPLv1+ PERL_GD_LICENSE_FILES = LICENSE +PERL_GD_PREFER_INSTALLER = EUMM PERL_GD_CONF_OPTS = \ -options=FT,PNG \
Signature · 1 line
2.9.3
PATCH v2 3/3 perl-gdgraph: bump to version 1.54
In reply to Francois Perrad--- package/perl-gdgraph/perl-gdgraph.hash | 4 ++-- package/perl-gdgraph/perl-gdgraph.mk | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-)
package/perl-gdgraph/perl-gdgraph.hash +2 -2
@@ -1,3 +1,3 @@ # retrieved by scancpan from http://cpan.metacpan.org/ -md5 8bb270a30fea27491302b39b701b3d4e GDGraph-1.49.tar.gz -sha256 d26538c827e35c1d4b27f3c045b60f1ab6b45401c54a87e86103cd7c2374cff5 GDGraph-1.49.tar.gz +md5 38c6a188519e6272e9b2b722b315c3d8 GDGraph-1.54.tar.gz +sha256 b96f5c10b656c17d16ab65a1777c908297b028d3b6815f6d54b2337f006bfa4f GDGraph-1.54.tar.gz
package/perl-gdgraph/perl-gdgraph.mk +1 -1
@@ -4,7 +4,7 @@ # ################################################################################ -PERL_GDGRAPH_VERSION = 1.49 +PERL_GDGRAPH_VERSION = 1.54 PERL_GDGRAPH_SOURCE = GDGraph-$(PERL_GDGRAPH_VERSION).tar.gz PERL_GDGRAPH_SITE = $(BR2_CPAN_MIRROR)/authors/id/R/RU/RUZ PERL_GDGRAPH_DEPENDENCIES = perl-gd perl-gdtextutil
Signature · 1 line
2.9.3
PATCH v2 1/3 pkg-perl: add PREFER_INSTALLER variable
In reply to Francois PerradHello,
Quoted 5 lines · Francois Perrad
Signed-off-by Francois Perrad <[email protected]>--- docs/manual/adding-packages-perl.txt | 8 ++++++-- package/pkg-perl.mk | 20 ++++++++++++++------ 2 files changed, 20 insertions(+), 8 deletions(-)
Thanks for this v2, but I've already reviewed and it doesn't seem like you have taken into account my comments. There has been no reply from you to the comments I made on the v1, and there is no changelog in your v2 to understand what has changed compared to v1.
When there are review comments, it would be useful if you could *reply* rather than just sending a new version that fixes some of the comments and totally ignores the rest of the comments ?
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com
PATCH v2 1/3 pkg-perl: add PREFER_INSTALLER variable
In reply to Francois PerradHello,
Quoted 5 lines · Francois Perrad
Signed-off-by Francois Perrad <[email protected]>--- docs/manual/adding-packages-perl.txt | 8 ++++++-- package/pkg-perl.mk | 20 ++++++++++++++------ 2 files changed, 20 insertions(+), 8 deletions(-)
Entire series applied, thanks! I did some tweaks to the documentation changes before applying, but nothing major.
Thanks again!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com