[Buildroot] [pkg-perl infra V3 00/12] a package infrastructure for Perl/CPAN modules

Arnout Vandecappelle arnout at mind.be
Tue Feb 4 08:49:57 UTC 2014


 Hi Francois,

 Now that we have some dedicated time at the BR developer days we are
finally getting around to reviewing your perl infrastructure update. I'm
going to write down some overall remarks, while Yann will be posting more
detailed feedback on the individual patches.

 First of all, it took a bit of effort to rebase on current master; if
you continue with this series, you can start with pulling it from
git at gitorious.org:buildroot/buildroot.git branch perl-fixup

On 23/11/13 10:25, Francois Perrad wrote:
> delta V2 vs V3 :
> 
> - [03/12] scancpan:
>     add options (including a update/force mode)
>     refactor with Pod::Usage
> 
> - [12/12] libxml-libxml-perl:
>     includes all its CPAN dependencies
> 
> Francois Perrad (12):
>   perl: new infrastructure

 For this one, there are some issues with the details but the basic
concept of adding a perl-package macro looks good.

 It would be good to add a dependency mechanism like for python: add perl
to the dependencies automatically, and remove it from the host
dependencies. That way you can also remove the explicit setting of host
dependencies because it will always be the same as target dependencies
(except for the manually edited packages but that's fine).

>   cpan: a home for Perl modules
>   scancpan: a new script

 This script looks really good as a way to semi-automatically keep our
perl packages up-to-date. However, we think that the packages should
really be committed buildroot and not be generated by the user. Even if
we add a few hundred perl packages, that's not a big deal: we do that for
xorg as well.

 For the naming of the packages, we prefer "perl-<pkgname>" rather than
the Debian naming "lib<pkgname>-perl".

 Given that you're using $debname, I wonder: is this script in any way
taken over from a Debian script? If so, you should credit the original
authors (even if it is just "inspired on ... by ...").

 Ideally, this scancpan support should save into BR2_EXTERNAL if that is
defined. How that can be done in practice may be tricky, however...
Perhaps the updating of the cpan/Config.in should _not_ be automated. Or
else the cpan directory can be given as an argument.

 When running the script, I've encountered an issue: on line 589:
$dist->{license} seems to be a single string, not an array.

 Also the example you give in the documentation could be something more
relevant - for example, the packages that we carry in buildroot.

 The perl_5 license should be added to our list of license (in a separate
patch).

 Maybe the generated files should be marked with an "Automatically
generated by" header - even though that violates our normal coding style.

 I think the _AUTHOR variable is redundant.

 The _LICENSE_FILES variable is not set by the script - most likely
because it is not always in the same file. This can be solved by manually
editing the packages which do have a license file. Yet another reason for
including the packages in buildroot instead of letting the user generate
them.

>   cpanminus: remove it
>   perl: remove useless patch
>   qemu: add a Config.in.host

 This one can probably be done independently of the rest (but then remove
the "after ..." comment).

>   host-libxml-parser-perl: move and refactor with perl infrastructure

 Why did you convert this into a host-only package?

 I think this one and the following ones should go to the beginning of
the series - before the cpan stuff which is more controversial.


>   host-libmodule-build-perl: new package
>   manual: adding packages perl
>   libcurses-perl: new package

make[2]: *** No rule to make target
`$(STAGING_DIR)/usr/lib/perl5/5.18.2/x86_64-linux/CORE/patchlevel-debian.h',
needed by `Curses.o'.  Stop.

(this is with a x86_64 target, and obviously on a debian host).

>   libnet-ssleay-perl: new package

 This one interactively asks me:
Do you want to run external tests?

 Is there any way to avoid that, i.e. preseeding the answer to "no"
(actually we don't want to run tests at all).

 It also fails because of the -debian thing.

>   libxml-libxml-perl: new package

 libxml-sax-perl also asks me something interactively.

 libxml-libxml-perl fails to build with:

make[2]: *** No rule to make target `pure_all'.  Stop.



 I'm sorry that we're giving you so much work :-)

 Regards,
 Arnout


> 
>  Config.in                                          |    7 +
>  docs/manual/adding-packages-perl.txt               |   91 +++
>  docs/manual/adding-packages.txt                    |    2 +
>  package/Config.in                                  |    3 +-
>  package/Config.in.host                             |    1 +
>  package/Makefile.in                                |   11 +-
>  package/cpan/Config.in                             |    6 +
>  package/cpan/cpan.mk                               |    1 +
>  package/cpan/libcurses-perl/Config.in              |    6 +
>  package/cpan/libcurses-perl/libcurses-perl.mk      |   15 +
>  .../libmodule-build-perl/libmodule-build-perl.mk   |   13 +
>  package/cpan/libnet-ssleay-perl/Config.in          |    6 +
>  .../cpan/libnet-ssleay-perl/libnet-ssleay-perl.mk  |   16 +
>  package/cpan/libxml-libxml-perl/Config.in          |    9 +
>  .../cpan/libxml-libxml-perl/libxml-libxml-perl.mk  |   22 +
>  .../cpan/libxml-namespacesupport-perl/Config.in    |    5 +
>  .../libxml-namespacesupport-perl.mk                |   16 +
>  .../cpan/libxml-parser-perl/libxml-parser-perl.mk  |   17 +
>  package/cpan/libxml-sax-base-perl/Config.in        |    5 +
>  .../libxml-sax-base-perl/libxml-sax-base-perl.mk   |   16 +
>  package/cpan/libxml-sax-perl/Config.in             |    7 +
>  package/cpan/libxml-sax-perl/libxml-sax-perl.mk    |   15 +
>  package/cpanminus/Config.in                        |   40 --
>  package/cpanminus/cpanminus.mk                     |   47 --
>  package/intltool/intltool.mk                       |    4 +-
>  package/libxml-parser-perl/Config.in               |   11 -
>  package/libxml-parser-perl/libxml-parser-perl.mk   |   35 -
>  package/perl/perl-fix-Module-Build.patch           |   16 -
>  package/pkg-perl.mk                                |  220 ++++++
>  package/qemu/Config.in.host                        |   10 +
>  support/scripts/scancpan                           |  700 ++++++++++++++++++++
>  31 files changed, 1216 insertions(+), 157 deletions(-)
>  create mode 100644 docs/manual/adding-packages-perl.txt
>  create mode 100644 package/cpan/Config.in
>  create mode 100644 package/cpan/cpan.mk
>  create mode 100644 package/cpan/libcurses-perl/Config.in
>  create mode 100644 package/cpan/libcurses-perl/libcurses-perl.mk
>  create mode 100644 package/cpan/libmodule-build-perl/libmodule-build-perl.mk
>  create mode 100644 package/cpan/libnet-ssleay-perl/Config.in
>  create mode 100644 package/cpan/libnet-ssleay-perl/libnet-ssleay-perl.mk
>  create mode 100644 package/cpan/libxml-libxml-perl/Config.in
>  create mode 100644 package/cpan/libxml-libxml-perl/libxml-libxml-perl.mk
>  create mode 100644 package/cpan/libxml-namespacesupport-perl/Config.in
>  create mode 100644 package/cpan/libxml-namespacesupport-perl/libxml-namespacesupport-perl.mk
>  create mode 100644 package/cpan/libxml-parser-perl/libxml-parser-perl.mk
>  create mode 100644 package/cpan/libxml-sax-base-perl/Config.in
>  create mode 100644 package/cpan/libxml-sax-base-perl/libxml-sax-base-perl.mk
>  create mode 100644 package/cpan/libxml-sax-perl/Config.in
>  create mode 100644 package/cpan/libxml-sax-perl/libxml-sax-perl.mk
>  delete mode 100644 package/cpanminus/Config.in
>  delete mode 100644 package/cpanminus/cpanminus.mk
>  delete mode 100644 package/libxml-parser-perl/Config.in
>  delete mode 100644 package/libxml-parser-perl/libxml-parser-perl.mk
>  delete mode 100644 package/perl/perl-fix-Module-Build.patch
>  create mode 100644 package/pkg-perl.mk
>  create mode 100644 package/qemu/Config.in.host
>  create mode 100755 support/scripts/scancpan
> 


-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
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


More information about the buildroot mailing list