Re: Adapting Perl packages to GCC removal from Fedora 29 build root

2018-02-23 Thread Petr Pisar
On Fri, Feb 23, 2018 at 02:22:38PM +0100, Robert-André Mauchin wrote:
> What about packages that use perl(XSLoader) but not perl(Module::Build)? 
> Shouldn't they require gcc too?
> 
If you mean build-requiring gcc because your package run-requires XSLoader
because it packages an XS code the is compiled when building the package. Then
yes, you should have to build-require gcc. Otherwise the package won't build.

For example if you package uses ExtUtils::MakerMaker, then if Makefile.PL
detects XS files in the sources, it will generate Makefile that executes gcc
directly.

Because there is no intermediate module that would mandate dependency on gcc
there is no other way then to adding BuildRequires: gcc into the spec file. We
cannot add gcc dependency to perl-ExtUtils-MakeMaker because again majority of
Perl source packages do not need gcc.

If you mean run-requiring gcc, then no. There is no reason to run-require gcc
just only because the package loads an shared library with XSLoader.

-- Petr


signature.asc
Description: PGP signature
___
perl-devel mailing list -- perl-devel@lists.fedoraproject.org
To unsubscribe send an email to perl-devel-le...@lists.fedoraproject.org


Re: Adapting Perl packages to GCC removal from Fedora 29 build root

2018-02-23 Thread Paul Howarth
On Fri, 23 Feb 2018 13:56:58 +0100
Petr Pisar  wrote:

> It's a long time I sent a message here. And because your read my new
> message, it means something is wrong. Here it is:
> 
> GCC won't be in the minimal build root
> 
> since Fedora 29. That affects Perl packages that executes gcc at
> build time
> .
> 
> Many of them use ExtUtils::CBuilder
>  and thus
> Paul proposed adding dependency on gcc to perl-ExtUtils-CBuilder
>  instead of
> adding it to each of the affected spec file as C guidelines recommends
> .
> 
> It's true that the only reason for ExtUils::CBuilder existence is to
> build C code. Thus it is reasonable to require gcc from this package.
> 
> (ExtUils::CBuilder also supports C++ and I think it makes sense to
> require both gcc and gcc-c++.)
> 
> But if perl-ExtUtils-CBuilder will require gcc, then all
> Module::Build driven packages (403) will pull in gcc because current
> perl-Module-Build requires it. In reality there is only 59
> architecture specific packages that uses Module::Build.
> 
> So it's tempting to remove the ExtUtils::CBuilder dependency from
> perl-Module-Build. Can we do it?
> 
> "XS Extensions" section in Module::Build::Authoring reads:
> 
> Modules which need to compile XS code should list
> "ExtUtils::CBuilder" as a "build_requires" element.
> 
> Contrary to that Module-Build requires ExtUtils::CBuilder in it's
> META data. Thus I don't believe CPAN distribution authors or Fedora
> packagers do that. And indeed Fedora has 36 Module::Build packages
> that are missing ExtUtils::CBuilder build-dependency:
> 
> perl-Alien-ROOT
> perl-Alien-wxWidgets
> perl-Authen-DecHpwd
> perl-Boost-Geometry-Utils
> perl-Config-Augeas
> perl-Crypt-MySQL
> perl-Crypt-ScryptKDF
> perl-Data-Pond
> perl-Devel-GoFaster
> perl-File-Map
> perl-Hash-FieldHash
> perl-HTML-Escape
> perl-IO-Interface
> perl-JavaScript-Minifier-XS
> perl-Judy
> perl-KinoSearch1
> perl-Lexical-SealRequireHints
> perl-Lexical-Var
> perl-Lchown
> perl-Lingua-Stem-Snowball
> perl-Net-IDN-Encode
> perl-Net-LibIDN2
> perl-Params-Classify
> perl-Params-Validate
> perl-Parse-DMIDecode
> perl-PerlIO-buffersize
> perl-PerlIO-Layers
> perl-RPM2
> perl-Scalar-String
> perl-SDL
> perl-Socket-Netlink
> perl-Text-Xslate
> perl-Thread-SigMask
> perl-Time-timegm
> perl-Unicode-CaseFold
> remctl
> 
> I think it makes sense to implement this change:
> 
> (1) Add gcc and gcc-c++ dependency to perl-ExtUtils-CBuilder.
> (2) Replace ExtUtils::CBuilder hard dependency with a weak dependency
> at Recommends level in perl-Module-Build.
> (3) Add ExtUtils::CBuilder build-time dependency to those 36 packages.
> (4) Add gcc weak dependency at Recommends level to
> perl-ExtUtils-MakeMaker. (4) Add gcc build dependency to rest (mostly
> ExtUtils::MakeMaker-driven) spec files where it is missing.
> 
> Do you agree? Do you have a different opinion? Do you have a better
> plan?

That looks very reasonable to me.

Paul.
___
perl-devel mailing list -- perl-devel@lists.fedoraproject.org
To unsubscribe send an email to perl-devel-le...@lists.fedoraproject.org


Re: Adapting Perl packages to GCC removal from Fedora 29 build root

2018-02-23 Thread Robert-André Mauchin
On vendredi 23 février 2018 13:56:58 CET Petr Pisar wrote:
> It's a long time I sent a message here. And because your read my new
> message, it means something is wrong. Here it is:
> 
> GCC won't be in the minimal build root
>  since
> Fedora 29. That affects Perl packages that executes gcc at build time
> .
> 
> Many of them use ExtUtils::CBuilder
>  and thus Paul
> proposed adding dependency on gcc to perl-ExtUtils-CBuilder
>  instead of adding it
> to each of the affected spec file as C guidelines recommends
>  quires>.
> 
> It's true that the only reason for ExtUils::CBuilder existence is to build
> C code. Thus it is reasonable to require gcc from this package.
> 
> (ExtUils::CBuilder also supports C++ and I think it makes sense to require
> both gcc and gcc-c++.)
> 
> But if perl-ExtUtils-CBuilder will require gcc, then all Module::Build
> driven packages (403) will pull in gcc because current perl-Module-Build
> requires it. In reality there is only 59 architecture specific packages
> that uses Module::Build.
> 
> So it's tempting to remove the ExtUtils::CBuilder dependency from
> perl-Module-Build. Can we do it?
> 
> "XS Extensions" section in Module::Build::Authoring reads:
> 
> Modules which need to compile XS code should list "ExtUtils::CBuilder"
> as a "build_requires" element.
> 
> Contrary to that Module-Build requires ExtUtils::CBuilder in it's META data.
> Thus I don't believe CPAN distribution authors or Fedora packagers do that.
> And indeed Fedora has 36 Module::Build packages that are missing
> ExtUtils::CBuilder build-dependency:
> 

What about packages that use perl(XSLoader) but not perl(Module::Build)? 
Shouldn't they require gcc too?

___
perl-devel mailing list -- perl-devel@lists.fedoraproject.org
To unsubscribe send an email to perl-devel-le...@lists.fedoraproject.org


Adapting Perl packages to GCC removal from Fedora 29 build root

2018-02-23 Thread Petr Pisar
It's a long time I sent a message here. And because your read my new message,
it means something is wrong. Here it is:

GCC won't be in the minimal build root
 since
Fedora 29. That affects Perl packages that executes gcc at build time
.

Many of them use ExtUtils::CBuilder
 and thus Paul
proposed adding dependency on gcc to perl-ExtUtils-CBuilder
 instead of adding it to
each of the affected spec file as C guidelines recommends
.

It's true that the only reason for ExtUils::CBuilder existence is to build
C code. Thus it is reasonable to require gcc from this package.

(ExtUils::CBuilder also supports C++ and I think it makes sense to require
both gcc and gcc-c++.)

But if perl-ExtUtils-CBuilder will require gcc, then all Module::Build driven
packages (403) will pull in gcc because current perl-Module-Build requires
it. In reality there is only 59 architecture specific packages that uses
Module::Build.

So it's tempting to remove the ExtUtils::CBuilder dependency from
perl-Module-Build. Can we do it?

"XS Extensions" section in Module::Build::Authoring reads:

Modules which need to compile XS code should list "ExtUtils::CBuilder"
as a "build_requires" element.

Contrary to that Module-Build requires ExtUtils::CBuilder in it's META data.
Thus I don't believe CPAN distribution authors or Fedora packagers do that.
And indeed Fedora has 36 Module::Build packages that are missing
ExtUtils::CBuilder build-dependency:

perl-Alien-ROOT
perl-Alien-wxWidgets
perl-Authen-DecHpwd
perl-Boost-Geometry-Utils
perl-Config-Augeas
perl-Crypt-MySQL
perl-Crypt-ScryptKDF
perl-Data-Pond
perl-Devel-GoFaster
perl-File-Map
perl-Hash-FieldHash
perl-HTML-Escape
perl-IO-Interface
perl-JavaScript-Minifier-XS
perl-Judy
perl-KinoSearch1
perl-Lexical-SealRequireHints
perl-Lexical-Var
perl-Lchown
perl-Lingua-Stem-Snowball
perl-Net-IDN-Encode
perl-Net-LibIDN2
perl-Params-Classify
perl-Params-Validate
perl-Parse-DMIDecode
perl-PerlIO-buffersize
perl-PerlIO-Layers
perl-RPM2
perl-Scalar-String
perl-SDL
perl-Socket-Netlink
perl-Text-Xslate
perl-Thread-SigMask
perl-Time-timegm
perl-Unicode-CaseFold
remctl

I think it makes sense to implement this change:

(1) Add gcc and gcc-c++ dependency to perl-ExtUtils-CBuilder.
(2) Replace ExtUtils::CBuilder hard dependency with a weak dependency at
Recommends level in perl-Module-Build.
(3) Add ExtUtils::CBuilder build-time dependency to those 36 packages.
(4) Add gcc weak dependency at Recommends level to perl-ExtUtils-MakeMaker.
(4) Add gcc build dependency to rest (mostly ExtUtils::MakeMaker-driven) spec
files where it is missing.

Do you agree? Do you have a different opinion? Do you have a better plan?

-- Petr


signature.asc
Description: PGP signature
___
perl-devel mailing list -- perl-devel@lists.fedoraproject.org
To unsubscribe send an email to perl-devel-le...@lists.fedoraproject.org