Skip to contentSkip to conversation

utils/scancpan: warn when a module is a perl core module

PATCH New Francois Perrad 2 participants 6 messages Jan 8, 2020

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/5 utils/scancpan: warn when a module is a perl core module

we don't want create new BR package with perl core module, because core modules are already included in perl distribution, and built with the BR package perl.

---
 utils/scancpan | 3 +++
 1 file changed, 3 insertions(+)
utils/scancpan +3 -0
index ac5fd5159..dbd8dab6d 100755
@@ -611,6 +611,9 @@ sub fetch {
     unless ($dist{$name} && !$top) {
         say qq{fetch ${name}} unless $quiet;
         my $result = $mcpan->release( distribution => $name );
+        my $main_module = $result->{main_module};
+        push @info, qq{[$name] $main_module is a core module}
+            if $top && Module::CoreList::is_core( $main_module, undef, $] );
         $dist{$name} = $result;
         $license_files{$name} = {};
         eval {
Signature · 1 line
2.20.1
#1 lore raw

PATCH v2 2/5 package/perl-digest-md5: remove it

Digest::MD5 is a Perl core module (ie. bundled with perl)

---
 Config.in.legacy                             |  8 ++++++++
 DEVELOPERS                                   |  1 -
 package/Config.in                            |  1 -
 package/perl-digest-md5/Config.in            | 10 ----------
 package/perl-digest-md5/perl-digest-md5.hash |  6 ------
 package/perl-digest-md5/perl-digest-md5.mk   | 14 --------------
 6 files changed, 8 insertions(+), 32 deletions(-)
 delete mode 100644 package/perl-digest-md5/Config.in
 delete mode 100644 package/perl-digest-md5/perl-digest-md5.hash
 delete mode 100644 package/perl-digest-md5/perl-digest-md5.mk
Config.in.legacy +8 -0
index aa66a564a..297a25994 100644
@@ -144,6 +144,14 @@ endif
 
 ###############################################################################
 
+comment "Legacy options removed in 2020.02"
+
+config BR2_PACKAGE_PERL_DIGEST_MD5
+	bool "perl-digest-md5 was removed"
+	select BR2_LEGACY
+	help
+	  Digest::MD5 is a Perl core module (ie. bundled with perl).
+
 comment "Legacy options removed in 2019.11"
 
 config BR2_PACKAGE_OPENVMTOOLS_PROCPS
DEVELOPERS +0 -1
index 6375e368e..b181cb6e1 100644
@@ -2284,7 +2284,6 @@ F:	package/perl-convert-asn1/
 F:	package/perl-crypt-blowfish/
 F:	package/perl-crypt-cbc/
 F:	package/perl-crypt-openssl-aes/
-F:	package/perl-digest-md5/
 F:	package/perl-math-bigint/
 F:	package/perl-math-prime-util/
 F:	package/perl-mime-base64-urlsafe/
package/Config.in +0 -1
index 5cff2d0c0..894a4d9b4 100644
@@ -717,7 +717,6 @@ menu "Perl libraries/modules"
 	source "package/perl-devel-stacktrace-ashtml/Config.in"
 	source "package/perl-device-serialport/Config.in"
 	source "package/perl-digest-hmac/Config.in"
-	source "package/perl-digest-md5/Config.in"
 	source "package/perl-digest-sha1/Config.in"
 	source "package/perl-dist-checkconflicts/Config.in"
 	source "package/perl-encode-detect/Config.in"
package/perl-digest-md5/Config.in deleted +0 -10
deleted file mode 100644
index 88aeab6fc..000000000
@@ -1,10 +0,0 @@
-config BR2_PACKAGE_PERL_DIGEST_MD5
-	bool "perl-digest-md5"
-	depends on !BR2_STATIC_LIBS
-	help
-	  Perl interface to the MD-5 algorithm.
-
-	  https://metacpan.org/release/Digest-MD5
-
-comment "perl-digest-md5 needs a toolchain w/ dynamic library"
-	depends on BR2_STATIC_LIBS
package/perl-digest-md5/perl-digest-md5.hash deleted +0 -6
deleted file mode 100644
index 3876f3aca..000000000
@@ -1,6 +0,0 @@
-# retrieved by scancpan from http://cpan.metacpan.org/
-md5    601519b826ca14c233f13a4578b967ef Digest-MD5-2.55.tar.gz
-sha256 03b198a2d14425d951e5e50a885d3818c3162c8fe4c21e18d7798a9a179d0e3c Digest-MD5-2.55.tar.gz
-
-# computed by scancpan
-sha256 f92f16702159fc57cd29c23f29b7f2420bff578ed72365d0225d2945a501cd5a README
package/perl-digest-md5/perl-digest-md5.mk deleted +0 -14
deleted file mode 100644
index 19c89d95a..000000000
@@ -1,14 +0,0 @@
-################################################################################
-#
-# perl-digest-md5
-#
-################################################################################
-
-PERL_DIGEST_MD5_VERSION = 2.55
-PERL_DIGEST_MD5_SOURCE = Digest-MD5-$(PERL_DIGEST_MD5_VERSION).tar.gz
-PERL_DIGEST_MD5_SITE = $(BR2_CPAN_MIRROR)/authors/id/G/GA/GAAS
-PERL_DIGEST_MD5_LICENSE = Artistic or GPL-1.0+
-PERL_DIGEST_MD5_LICENSE_FILES = README
-PERL_DIGEST_MD5_DISTNAME = Digest-MD5
-
-$(eval $(perl-package))
Signature · 1 line
2.20.1
#2 lore raw

PATCH v2 3/5 package/perl-math-bigint: remove it

In reply to Francois Perrad

Math::BigInt is a Perl core module (ie. bundled with perl)

This package was never released with BR,
so no need to add an entry in Config.legacy

---
 DEVELOPERS                                     |  1 -
 package/Config.in                              |  1 -
 package/perl-math-bigint/Config.in             |  6 ------
 package/perl-math-bigint/perl-math-bigint.hash |  6 ------
 package/perl-math-bigint/perl-math-bigint.mk   | 14 --------------
 5 files changed, 28 deletions(-)
 delete mode 100644 package/perl-math-bigint/Config.in
 delete mode 100644 package/perl-math-bigint/perl-math-bigint.hash
 delete mode 100644 package/perl-math-bigint/perl-math-bigint.mk
DEVELOPERS +0 -1
index b181cb6e1..071095ef6 100644
@@ -2284,7 +2284,6 @@ F:	package/perl-convert-asn1/
 F:	package/perl-crypt-blowfish/
 F:	package/perl-crypt-cbc/
 F:	package/perl-crypt-openssl-aes/
-F:	package/perl-math-bigint/
 F:	package/perl-math-prime-util/
 F:	package/perl-mime-base64-urlsafe/
 F:	package/perl-mojolicious-plugin-authentication/
package/Config.in +0 -1
index 894a4d9b4..6f0432a37 100644
@@ -751,7 +751,6 @@ menu "Perl libraries/modules"
 	source "package/perl-lwp-mediatypes/Config.in"
 	source "package/perl-mail-dkim/Config.in"
 	source "package/perl-mailtools/Config.in"
-	source "package/perl-math-bigint/Config.in"
 	source "package/perl-math-prime-util/Config.in"
 	source "package/perl-mime-base64/Config.in"
 	source "package/perl-mime-base64-urlsafe/Config.in"
package/perl-math-bigint/Config.in deleted +0 -6
deleted file mode 100644
index 89722e7b1..000000000
@@ -1,6 +0,0 @@
-config BR2_PACKAGE_PERL_MATH_BIGINT
-	bool "perl-math-bigint"
-	help
-	  Pure Perl module to test Math::BigInt with scalars.
-
-	  https://metacpan.org/release/Math-BigInt
package/perl-math-bigint/perl-math-bigint.hash deleted +0 -6
deleted file mode 100644
index ad3d66bbf..000000000
@@ -1,6 +0,0 @@
-# retrieved by scancpan from http://cpan.metacpan.org/
-md5    a6e5a6c391b453e04c2b60506e1b5342 Math-BigInt-1.999818.tar.gz
-sha256 b27634356ce2af9b7c0123ac8395a89a32fb15aeae82fcd39de8156cad278c15 Math-BigInt-1.999818.tar.gz
-
-# computed by scancpan
-sha256 b857edab549ac6893e2df5e1ec768ee46b62bcf1607a55e876f4d23f079eacce LICENSE
package/perl-math-bigint/perl-math-bigint.mk deleted +0 -14
deleted file mode 100644
index 156c6ce38..000000000
@@ -1,14 +0,0 @@
-################################################################################
-#
-# perl-math-bigint
-#
-################################################################################
-
-PERL_MATH_BIGINT_VERSION = 1.999818
-PERL_MATH_BIGINT_SOURCE = Math-BigInt-$(PERL_MATH_BIGINT_VERSION).tar.gz
-PERL_MATH_BIGINT_SITE = $(BR2_CPAN_MIRROR)/authors/id/P/PJ/PJACKLAM
-PERL_MATH_BIGINT_LICENSE = Artistic or GPL-1.0+
-PERL_MATH_BIGINT_LICENSE_FILES = LICENSE
-PERL_MATH_BIGINT_DISTNAME = Math-BigInt
-
-$(eval $(perl-package))
Signature · 1 line
2.20.1
#3 lore raw

PATCH v2 4/5 package/perl-mime-base64: remove it

In reply to Francois Perrad

MIME::Base64 is a Perl core module (ie. bundled with perl)

---
 Config.in.legacy                               |  6 ++++++
 DEVELOPERS                                     |  1 -
 package/Config.in                              |  1 -
 package/perl-mime-base64/Config.in             | 10 ----------
 package/perl-mime-base64/perl-mime-base64.hash |  6 ------
 package/perl-mime-base64/perl-mime-base64.mk   | 14 --------------
 6 files changed, 6 insertions(+), 32 deletions(-)
 delete mode 100644 package/perl-mime-base64/Config.in
 delete mode 100644 package/perl-mime-base64/perl-mime-base64.hash
 delete mode 100644 package/perl-mime-base64/perl-mime-base64.mk
Config.in.legacy +6 -0
index 297a25994..e1e868531 100644
@@ -152,6 +152,12 @@ config BR2_PACKAGE_PERL_DIGEST_MD5
 	help
 	  Digest::MD5 is a Perl core module (ie. bundled with perl).
 
+config BR2_PACKAGE_PERL_MIME_BASE64
+	bool "perl-mime-base64 was removed"
+	select BR2_LEGACY
+	help
+	  MIME::Base64 is a Perl core module (ie. bundled with perl).
+
 comment "Legacy options removed in 2019.11"
 
 config BR2_PACKAGE_OPENVMTOOLS_PROCPS
DEVELOPERS +0 -1
index 071095ef6..ba75f601f 100644
@@ -395,7 +395,6 @@ F:	package/perl-io-html/
 F:	package/perl-lwp-mediatypes/
 F:	package/perl-mail-dkim/
 F:	package/perl-mailtools/
-F:	package/perl-mime-base64/
 F:	package/perl-net-dns/
 F:	package/perl-net-http/
 F:	package/perl-netaddr-ip/
package/Config.in +0 -1
index 6f0432a37..5dab6ba31 100644
@@ -752,7 +752,6 @@ menu "Perl libraries/modules"
 	source "package/perl-mail-dkim/Config.in"
 	source "package/perl-mailtools/Config.in"
 	source "package/perl-math-prime-util/Config.in"
-	source "package/perl-mime-base64/Config.in"
 	source "package/perl-mime-base64-urlsafe/Config.in"
 	source "package/perl-mime-tools/Config.in"
 	source "package/perl-module-implementation/Config.in"
package/perl-mime-base64/Config.in deleted +0 -10
deleted file mode 100644
index ecb3d2ee6..000000000
@@ -1,10 +0,0 @@
-config BR2_PACKAGE_PERL_MIME_BASE64
-	bool "perl-mime-base64"
-	depends on !BR2_STATIC_LIBS
-	help
-	  The RFC 2045 encodings; base64 and quoted-printable.
-
-	  https://metacpan.org/release/MIME-Base64
-
-comment "perl-mime-base64 needs a toolchain w/ dynamic library"
-	depends on BR2_STATIC_LIBS
package/perl-mime-base64/perl-mime-base64.hash deleted +0 -6
deleted file mode 100644
index 77bd7b063..000000000
@@ -1,6 +0,0 @@
-# retrieved by scancpan from http://cpan.metacpan.org/
-md5    ef958dc2bf96be5f759391c6ac1debd4 MIME-Base64-3.15.tar.gz
-sha256 7f863566a6a9cb93eda93beadb77d9aa04b9304d769cea3bb921b9a91b3a1eb9 MIME-Base64-3.15.tar.gz
-
-# computed by scancpan
-sha256 08e6898e3d62619e83880832ec42ae8a2984257e4c244843db9d3b9b7fcff236 README
package/perl-mime-base64/perl-mime-base64.mk deleted +0 -14
deleted file mode 100644
index 201707d46..000000000
@@ -1,14 +0,0 @@
-################################################################################
-#
-# perl-mime-base64
-#
-################################################################################
-
-PERL_MIME_BASE64_VERSION = 3.15
-PERL_MIME_BASE64_SOURCE = MIME-Base64-$(PERL_MIME_BASE64_VERSION).tar.gz
-PERL_MIME_BASE64_SITE = $(BR2_CPAN_MIRROR)/authors/id/G/GA/GAAS
-PERL_MIME_BASE64_LICENSE = Artistic or GPL-1.0+
-PERL_MIME_BASE64_LICENSE_FILES = README
-PERL_MIME_BASE64_DISTNAME = MIME-Base64
-
-$(eval $(perl-package))
Signature · 1 line
2.20.1
#4 lore raw

PATCH v2 5/5 package/perl-net-ping: remove it

In reply to Francois Perrad

Net::Ping is a Perl core module (ie. bundled with perl)

---
 Config.in.legacy                         |  6 ++++++
 DEVELOPERS                               |  1 -
 package/Config.in                        |  1 -
 package/perl-net-ping/Config.in          |  6 ------
 package/perl-net-ping/perl-net-ping.hash |  6 ------
 package/perl-net-ping/perl-net-ping.mk   | 14 --------------
 6 files changed, 6 insertions(+), 28 deletions(-)
 delete mode 100644 package/perl-net-ping/Config.in
 delete mode 100644 package/perl-net-ping/perl-net-ping.hash
 delete mode 100644 package/perl-net-ping/perl-net-ping.mk
Config.in.legacy +6 -0
index e1e868531..85f88be15 100644
@@ -158,6 +158,12 @@ config BR2_PACKAGE_PERL_MIME_BASE64
 	help
 	  MIME::Base64 is a Perl core module (ie. bundled with perl).
 
+config BR2_PACKAGE_PERL_NET_PING
+	bool "perl-net-ping was removed"
+	select BR2_LEGACY
+	help
+	  Net::Ping is a Perl core module (ie. bundled with perl).
+
 comment "Legacy options removed in 2019.11"
 
 config BR2_PACKAGE_OPENVMTOOLS_PROCPS
DEVELOPERS +0 -1
index ba75f601f..4d2a442dc 100644
@@ -2286,7 +2286,6 @@ F:	package/perl-crypt-openssl-aes/
 F:	package/perl-math-prime-util/
 F:	package/perl-mime-base64-urlsafe/
 F:	package/perl-mojolicious-plugin-authentication/
-F:	package/perl-net-ping/
 F:	package/perl-net-snmp/
 F:	package/perl-net-ssh2/
 F:	package/perl-net-telnet/
package/Config.in +0 -1
index 5dab6ba31..fc97e6eb4 100644
@@ -761,7 +761,6 @@ menu "Perl libraries/modules"
 	source "package/perl-moo/Config.in"
 	source "package/perl-net-dns/Config.in"
 	source "package/perl-net-http/Config.in"
-	source "package/perl-net-ping/Config.in"
 	source "package/perl-net-snmp/Config.in"
 	source "package/perl-net-ssh2/Config.in"
 	source "package/perl-net-ssleay/Config.in"
package/perl-net-ping/Config.in deleted +0 -6
deleted file mode 100644
index 21239a095..000000000
@@ -1,6 +0,0 @@
-config BR2_PACKAGE_PERL_NET_PING
-	bool "perl-net-ping"
-	help
-	  check a remote host for reachability.
-
-	  https://metacpan.org/release/Net-Ping
package/perl-net-ping/perl-net-ping.hash deleted +0 -6
deleted file mode 100644
index 2842827c8..000000000
@@ -1,6 +0,0 @@
-# retrieved by scancpan from http://cpan.metacpan.org/
-md5    eb90f86dcc31126e88be02ecb62d5303 Net-Ping-2.72.tar.gz
-sha256 555af602f54229cd81fef7da1a81516800f3155c6dc4d07dc71be1de3253dd6a Net-Ping-2.72.tar.gz
-
-# computed by scancpan
-sha256 9441a22309a2b40ff1282ac1906c137f07f5e521e7b1ec162b251f6006051b47 README
package/perl-net-ping/perl-net-ping.mk deleted +0 -14
deleted file mode 100644
index b422c4eab..000000000
@@ -1,14 +0,0 @@
-################################################################################
-#
-# perl-net-ping
-#
-################################################################################
-
-PERL_NET_PING_VERSION = 2.72
-PERL_NET_PING_SOURCE = Net-Ping-$(PERL_NET_PING_VERSION).tar.gz
-PERL_NET_PING_SITE = $(BR2_CPAN_MIRROR)/authors/id/R/RU/RURBAN
-PERL_NET_PING_LICENSE = Artistic or GPL-1.0+
-PERL_NET_PING_LICENSE_FILES = README
-PERL_NET_PING_DISTNAME = Net-Ping
-
-$(eval $(perl-package))
Signature · 1 line
2.20.1
#5 lore raw

PATCH v2 1/5 utils/scancpan: warn when a module is a perl core module

In reply to Francois Perrad

Fran?ois, All,

On 2020-01-08 16:10 +0100, Francois Perrad spake thusly:

Quoted 5 lines

we don't want create new BR package with perl core module, because core modules are already included in perl distribution, and built with the BR package perl.

Serries applied to master, thanks.

However, I was a bit disapointed that a series sent just a few hours ago did not apply cleanly on master: I had to rework all the patches because they were conflicting with changes in Config.in.legacy that have been there since ctober.

So I don't know what your series was based off, but next time, please rebase it before sending, so there is no conflict...

Regards,
Yann E. MORIN.

Quoted 25 lines
---
 utils/scancpan | 3 +++
 1 file changed, 3 insertions(+)
utils/scancpan +3 -0
index ac5fd5159..dbd8dab6d 100755
@@ -611,6 +611,9 @@ sub fetch {
     unless ($dist{$name} && !$top) {
         say qq{fetch ${name}} unless $quiet;
         my $result = $mcpan->release( distribution => $name );
+        my $main_module = $result->{main_module};
+        push @info, qq{[$name] $main_module is a core module}
+            if $top && Module::CoreList::is_core( $main_module, undef, $] );
         $dist{$name} = $result;
         $license_files{$name} = {};
         eval {
Signature · 6 lines
2.20.1

_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'