Hello,
Trying to create a rpm package for perl-Tk-JBrowseEntry
I get:
Provides: perl-Tk-JBrowseEntry = 5.22-1.fc30 Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1 Checking for unpackaged file(s): /usr/lib/rpm/check-files /home/pdupre/rpmbuild/BUILDROOT/perl-Tk-JBrowseEntry-5.22-1.fc30.x86_64 error: Installed (but unpackaged) file(s) found: /usr/bin/JBrowseTest.pl
RPM build errors: Installed (but unpackaged) file(s) found: /usr/bin/JBrowseTest.pl
Any ideas? Thank.
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
On 6/9/19 2:27 PM, Patrick Dupre wrote:
RPM build errors: Installed (but unpackaged) file(s) found: /usr/bin/JBrowseTest.pl
Add that path to the %files section of the spec. If you're maintaining this for redistribution, you might want to list the path as "%{_bindir}/JBrowseTest.pl"
Thank.
Same issue with Tk-JFileDialog.spec In addition, I get: rpmbuild -bb perl-Tk-JFileDialog.spec error: Failed build dependencies: perl(Tk::JBrowseEntry) >= 4.63 is needed by perl-Tk-JFileDialog-2.20-1.fc30.noarch
while the installed version is 5.22
Could you tell me what is wrong?
Thank
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Sent: Monday, June 10, 2019 at 2:11 AM From: "Gordon Messmer" gordon.messmer@gmail.com To: users@lists.fedoraproject.org Subject: Re: rpmbuild
On 6/9/19 2:27 PM, Patrick Dupre wrote:
RPM build errors: Installed (but unpackaged) file(s) found: /usr/bin/JBrowseTest.pl
Add that path to the %files section of the spec. If you're maintaining this for redistribution, you might want to list the path as "%{_bindir}/JBrowseTest.pl" _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
On Mon, 10 Jun 2019 10:10:54 +0200 "Patrick Dupre" pdupre@gmx.com wrote:
Same issue with Tk-JFileDialog.spec In addition, I get: rpmbuild -bb perl-Tk-JFileDialog.spec error: Failed build dependencies: perl(Tk::JBrowseEntry) >= 4.63 is needed by perl-Tk-JFileDialog-2.20-1.fc30.noarch
while the installed version is 5.22
Could you tell me what is wrong?
It will be almost impossible to tell what is wrong without the build output. When you run rpmbuild add the following at the end of it. That will put the regular output in out.msg and the error output in out.ror. Then you have files of the output to analyze. Or post / paste (fedora has a facility called fpaste for this) for other people to analyze if you can't. You can view them with less out*
out.msg 2> out.ror
From the information you provide, it seems unlikely that this is the actual issue causing the build abort. Computers don't get things like a simple >= wrong.
Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
seems missing in the .spec file
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Same issue with Tk-JFileDialog.spec In addition, I get: rpmbuild -bb perl-Tk-JFileDialog.spec error: Failed build dependencies: perl(Tk::JBrowseEntry) >= 4.63 is needed by perl-Tk-JFileDialog-2.20-1.fc30.noarch
while the installed version is 5.22
Could you tell me what is wrong?
It will be almost impossible to tell what is wrong without the build output. When you run rpmbuild add the following at the end of it. That will put the regular output in out.msg and the error output in out.ror. Then you have files of the output to analyze. Or post / paste (fedora has a facility called fpaste for this) for other people to analyze if you can't. You can view them with less out*
out.msg 2> out.ror
From the information you provide, it seems unlikely that this is the actual issue causing the build abort. Computers don't get things like a simple >= wrong. _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
On Mon, 10 Jun 2019 15:35:22 +0200, Patrick Dupre wrote:
Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
seems missing in the .spec file
No. These are automatically created Provides/Requires for Perl Modules. You need to work with a package that _really_ includes and "Provides" the Tk:JBrowseEntry module with a sufficient version. If such a package is installed in the build environment, but doesn't contain the "Provides" tag, you will need to take a closer look at that package.
Sorry, when I run cpanspec Tk-JBrowseEntry-5.22.tar.gz
I get: Name: perl-Tk-JBrowseEntry Version: 5.22 Release: 1%{?dist} Summary: Full-featured "Combo-box" (Text-entry combined with drop-down listbox) derived from Tk::BrowseEntry with many additional features and options License: GPL+ or Artistic Group: Development/Libraries URL: http://search.cpan.org/dist/Tk-JBrowseEntry/ Source0: http://www.cpan.org/modules/by-module/Tk/Tk-JBrowseEntry-%%7Bversion%7D.tar.... BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: perl(ExtUtils::MakeMaker) BuildRequires: perl(Tk) Requires: perl(Tk) Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
%description Tk::JBrowseEntry is a derived widget from Tk::BrowseEntry, but adds numerous features and options. Among them are hash lists (one set of values is displayed for the user, but another is used as data), ability to disable either the text entry widget or the listbox, ability to allow user to delete items from the list, additional keyboard bindings, ability to have the drop-down list "fixed" (always displayed, ability to use Tk::HListbox, ie. to include thumbnail icons in the list), customized key bindings and behaviour, and much more!
%prep %setup -q -n Tk-JBrowseEntry-%{version}
%build %{__perl} Makefile.PL INSTALLDIRS=vendor make %{?_smp_mflags}
%install rm -rf $RPM_BUILD_ROOT
make pure_install PERL_INSTALL_ROOT=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ; find $RPM_BUILD_ROOT -depth -type d -exec rmdir {} 2>/dev/null ;
%{_fixperms} $RPM_BUILD_ROOT/*
%check make test
%clean rm -rf $RPM_BUILD_ROOT
%files %defattr(-,root,root,-) %doc Changes META.json README %{perl_vendorlib}/* %{_mandir}/man3/*
%changelog * Mon Jun 10 2019 Patrick Dupre pdupre@gmx.com 5.22-1 - Specfile autogenerated by cpanspec 1.78.
----------------------------------------------------------- Is there something in my .spec generation?
Anyway, addition: Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
fixes this issue
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Sent: Monday, June 10, 2019 at 5:22 PM From: "Michael Schwendt" mschwendt@gmail.com To: users@lists.fedoraproject.org Subject: Re: rpmbuild
On Mon, 10 Jun 2019 15:35:22 +0200, Patrick Dupre wrote:
Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
seems missing in the .spec file
No. These are automatically created Provides/Requires for Perl Modules. You need to work with a package that _really_ includes and "Provides" the Tk:JBrowseEntry module with a sufficient version. If such a package is installed in the build environment, but doesn't contain the "Provides" tag, you will need to take a closer look at that package. _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
On Mon, 10 Jun 2019 17:45:23 +0200, Patrick Dupre wrote:
Sorry, when I run cpanspec Tk-JBrowseEntry-5.22.tar.gz
I referred to _build time_ creation of inter-package dependencies. The step when rpmbuild adds Requires/Provides to the built packages. You are not supposed to hack a spec file as to add them manually for Perl Modules installed in Perl's paths for modules.
Is there something in my .spec generation?
Anyway, addition: Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
fixes this issue
Instead, use "BuildRequires: perl-generators" at build-time.
Hello,
I am not sure to take the point:
I can run cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz but that does not fill Provides: perl(Tk::JBrowseEntry) = %{version}-%{release} I can run cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz --add-provide "perl(Tk::JBrowseEntry) %{version}-%{release}"
If it is correct. Why is it not automatic?
Anyway, %{_bindir}/JBrowseTest.pl
is still missing in %files
Again, why the generation of the .spec is not automatic?
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Sent: Tuesday, June 11, 2019 at 12:46 PM From: "Michael Schwendt" mschwendt@gmail.com To: users@lists.fedoraproject.org Subject: Re: rpmbuild
On Mon, 10 Jun 2019 17:45:23 +0200, Patrick Dupre wrote:
Sorry, when I run cpanspec Tk-JBrowseEntry-5.22.tar.gz
I referred to _build time_ creation of inter-package dependencies. The step when rpmbuild adds Requires/Provides to the built packages. You are not supposed to hack a spec file as to add them manually for Perl Modules installed in Perl's paths for modules.
Is there something in my .spec generation?
Anyway, addition: Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
fixes this issue
Instead, use "BuildRequires: perl-generators" at build-time. _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
Samuel Sieb wrote:
On 6/11/19 12:13 PM, Patrick Dupre wrote:
Again, why the generation of the .spec is not automatic?
Because the script isn't perfect and it's a difficult problem to solve. cpanspec appears to be pretty dead upstream. You could try filing a bug in Fedora bugzilla.
FWIW, this issue is already noted here (nearly 2.5 years ago):
https://bugzilla.redhat.com/671445#c9
I suspect this won't be fixed anytime soon, unless someone steps up to provide a patch. Even that might not be enough, based on the fact that ticket still has an unapplied patch for other issues. :)
On Tue, 11 Jun 2019 21:13:10 +0200, Patrick Dupre wrote:
I am not sure to take the point:
You focus on something else.
I can run cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz --add-provide "perl(Tk::JBrowseEntry) %{version}-%{release}"
If it is correct.
It isn't. You are not supposed to add those Provides yourself. BuildRequires perl-generators would do it inside the built packages. Adding both makes no sense.
Why is it not automatic?
Other have answered that. I only tell you what needs to be present within the spec file for the built package dependencies to be added on-the-fly.
Instead, you expect the cpanspec generated file to be perfect, which is a different issue.
Hello,
Again, I am not sure to understand:
cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz
only add: BuildRequires: perl-generators in the .spec file
which does not help.
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Sent: Wednesday, June 12, 2019 at 2:26 PM From: "Michael Schwendt" mschwendt@gmail.com To: users@lists.fedoraproject.org Subject: Re: rpmbuild
On Tue, 11 Jun 2019 21:13:10 +0200, Patrick Dupre wrote:
I am not sure to take the point:
You focus on something else.
I can run cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz --add-provide "perl(Tk::JBrowseEntry) %{version}-%{release}"
If it is correct.
It isn't. You are not supposed to add those Provides yourself. BuildRequires perl-generators would do it inside the built packages. Adding both makes no sense.
Why is it not automatic?
Other have answered that. I only tell you what needs to be present within the spec file for the built package dependencies to be added on-the-fly.
Instead, you expect the cpanspec generated file to be perfect, which is a different issue. _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
On 6/12/19 1:43 PM, Patrick Dupre wrote:
Again, I am not sure to understand:
cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz
only add: BuildRequires: perl-generators in the .spec file
which does not help.
The spec file you get from cpanspec will need to be modified by you before it will work. You will need that %files entry as well. What is still not working for you?
Of course, I fixed the 2 or 3 issues manually.
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Sent: Thursday, June 13, 2019 at 4:50 AM From: "Samuel Sieb" samuel@sieb.net To: users@lists.fedoraproject.org Subject: Re: rpmbuild
On 6/12/19 1:43 PM, Patrick Dupre wrote:
Again, I am not sure to understand:
cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz
only add: BuildRequires: perl-generators in the .spec file
which does not help.
The spec file you get from cpanspec will need to be modified by you before it will work. You will need that %files entry as well. What is still not working for you? _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
On Wed, 12 Jun 2019 22:43:24 +0200, Patrick Dupre wrote:
Hello,
Again, I am not sure to understand:
cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz
only add: BuildRequires: perl-generators in the .spec file
which does not help.
It helps with automatic creation of Perl Module dependency metadata in the built packages. It does not add any Provides/Requires to the spec file, because that would be the wrong thing to do.
On Wed, 12 Jun 2019 22:43:24 +0200, Patrick Dupre wrote:
Hello,
Again, I am not sure to understand:
cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz
only add: BuildRequires: perl-generators in the .spec file
which does not help.
It helps with automatic creation of Perl Module dependency metadata in the built packages. It does not add any Provides/Requires to the spec file, because that would be the wrong thing to do.
Maybe, however, some perl packages require packages with a version number higher than a certain value. Thus, if the Provides/Requires instructions are not set properly, all the packages requiring other packages fail, either at the build or installation step. In my opinion, all the perl packages need to be checked to go through the distribution without requiring to use capnspec by the final user.
On Thu, 13 Jun 2019 23:09:58 +0200, Patrick Dupre wrote:
Maybe, however, some perl packages require packages with a version number higher than a certain value. Thus, if the Provides/Requires instructions are not set properly, all the packages requiring other packages fail, either at the build or installation step.
That doesn't make any sense at all.
The Provides/Requires dependencies are set automatically at build-time. One package _provides_ exactly what is found within in. Another package _requires_ exactly what it uses in its code. These automatic dependencies are correct at build-time, if and only if none of the providing packages is taken away or replaced with something incompatible (such as failing to satisfy >= requirements due to API changes or runtime behaviour changes).
If a Perl Module included in an RPM package is version X.Y, the package must not be used, if a package requires a version higher than X.Y. The package metadata must only provide exactly the version of the Perl Module that is included. That is why perl-generators is used to create these dependencies at build-time. If a newer version of the Perl Module is needed, an update to the package collection may be needed.
If you hack a spec file with manually added "Provides:" for a higher version, you are working against the entire system of package dependencies.
In my opinion, all the perl packages need to be checked to go through the distribution without requiring to use capnspec by the final user.
That is entirely unrelated to this mailing-list thread. It could be that there are perl-* RPM packages included in Fedora's package collection, which are missing the perl-generators build requirement and which are missing "perl(A::B) = version" provides. If that is the case, file a bug report. Or step up as co-maintainer, if you depend on such packages.
On 6/12/19 1:43 PM, Patrick Dupre wrote:
cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz
only add: BuildRequires: perl-generators in the .spec file
which does not help.
Sure, it does. The purpose of the "perl-generators" package is to include information about what a perl package "provides" and "requires" automaticaly, so that you don't have to. If I build Tk-JBrowseEntry with BuildRequires: perl-generators, then I get this on the resulting package:
# rpm -q --provides perl-Tk-JBrowseEntry-5.22-1.fc30.noarch perl(Tk::JBrowseEntry) = 5.22 perl-Tk-JBrowseEntry = 5.22-1.fc30
If I run the command you included above, there are several changes we'd want to make to the spec to bring it more in line with Fedora's packaging guidelines. "Group" and "BuildRoot" aren't used in Fedora, so those lines can be removed. The "make" command can be replaced with "%{make_build}". The %install section should not remove the build root. The %clean section should be removed. We need to add "PERL5LIB=%{buildroot}%{perl_vendorlib}" to the "make test" command in order for it to find the modules it installed in the build root (although some tests don't work without an X11 connection). "%defattr" isn't required in Fedora. Finally, we need to add "%{_bindir}/*" or "%{_bindir}/JBrowseTest.pl" to the %files section (or, alternatively, remove that file in the %install section if it should not be included in the package). A patch is attached with those changes, for a more literal specification of the changes.
I can use that modified spec to build a package, and move on to building the other package you mentioned, perl-Tk-JFileDialog. That package requires very similar changes, with the exception that "make test" actually fails, so I removed that rather than resolve the issue because I'm not working on pushing this through formal review. :)
After making the same changes to perl-Tk-JFileDialog, and building the package, both packages can be installed:
# rpm -q perl-Tk-JFileDialog perl-Tk-JBrowseEntry perl-Tk-JFileDialog-2.20-1.fc30.noarch perl-Tk-JBrowseEntry-5.22-1.fc30.noarch
On 6/10/19 1:10 AM, Patrick Dupre wrote:
Same issue with Tk-JFileDialog.spec In addition, I get: rpmbuild -bb perl-Tk-JFileDialog.spec error: Failed build dependencies: perl(Tk::JBrowseEntry) >= 4.63 is needed by perl-Tk-JFileDialog-2.20-1.fc30.noarch
while the installed version is 5.22
I believe you got this because your build environment did not include the perl-generator package. Once you add that to your BuildRequires, then the perl-Tk-JBrowseEntry package will automatically provide "perl(Tk::JBrowseEntry)", and resolve the dependency reported in this error message.
Thank you for these details. However 1) I expect that I would have to edit the .spec file 2) After that I install the package perl-Tk-JBrowseEntry-5.22-1.fc30.noarch I generate a perl-Tk-JFileDialog.spec which contains: BuildRequires: perl(Tk::JBrowseEntry) >= 4.63
Why that? When I want to install perl-Tk-JFileDialog-2.20-1.fc30.noarch.rpm
I get Error: Problem: conflicting requests - nothing provides perl(Tk::JBrowseEntry) >= 4.63 needed by perl-Tk-JFileDialog-2.20-1.fc30.noarch (try to add '--skip-broken' to skip uninstallable packages)
The solutions that I found are: 1) add Provides: perl(Tk::JBrowseEntry) = %{version}-%{release} in perl-Tk-JBrowseEntry.spec or 2) remove BuildRequires: perl(Tk::JBrowseEntry) >= 4.63 in perl-Tk-JFileDialog.spec
In my opinion, I should not have to edit the .spec files
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Sent: Friday, June 14, 2019 at 7:06 PM From: "Gordon Messmer" gordon.messmer@gmail.com To: users@lists.fedoraproject.org Subject: Re: rpmbuild
On 6/12/19 1:43 PM, Patrick Dupre wrote:
cpanspec --add-buildrequires perl-generators Tk-JBrowseEntry-5.22.tar.gz
only add: BuildRequires: perl-generators in the .spec file
which does not help.
Sure, it does. The purpose of the "perl-generators" package is to include information about what a perl package "provides" and "requires" automaticaly, so that you don't have to. If I build Tk-JBrowseEntry with BuildRequires: perl-generators, then I get this on the resulting package:
# rpm -q --provides perl-Tk-JBrowseEntry-5.22-1.fc30.noarch perl(Tk::JBrowseEntry) = 5.22 perl-Tk-JBrowseEntry = 5.22-1.fc30
If I run the command you included above, there are several changes we'd want to make to the spec to bring it more in line with Fedora's packaging guidelines. "Group" and "BuildRoot" aren't used in Fedora, so those lines can be removed. The "make" command can be replaced with "%{make_build}". The %install section should not remove the build root. The %clean section should be removed. We need to add "PERL5LIB=%{buildroot}%{perl_vendorlib}" to the "make test" command in order for it to find the modules it installed in the build root (although some tests don't work without an X11 connection). "%defattr" isn't required in Fedora. Finally, we need to add "%{_bindir}/*" or "%{_bindir}/JBrowseTest.pl" to the %files section (or, alternatively, remove that file in the %install section if it should not be included in the package). A patch is attached with those changes, for a more literal specification of the changes.
I can use that modified spec to build a package, and move on to building the other package you mentioned, perl-Tk-JFileDialog. That package requires very similar changes, with the exception that "make test" actually fails, so I removed that rather than resolve the issue because I'm not working on pushing this through formal review. :)
After making the same changes to perl-Tk-JFileDialog, and building the package, both packages can be installed:
# rpm -q perl-Tk-JFileDialog perl-Tk-JBrowseEntry perl-Tk-JFileDialog-2.20-1.fc30.noarch perl-Tk-JBrowseEntry-5.22-1.fc30.noarch
On 6/10/19 1:10 AM, Patrick Dupre wrote:
Same issue with Tk-JFileDialog.spec In addition, I get: rpmbuild -bb perl-Tk-JFileDialog.spec error: Failed build dependencies: perl(Tk::JBrowseEntry) >= 4.63 is needed by perl-Tk-JFileDialog-2.20-1.fc30.noarch
while the installed version is 5.22
I believe you got this because your build environment did not include the perl-generator package. Once you add that to your BuildRequires, then the perl-Tk-JBrowseEntry package will automatically provide "perl(Tk::JBrowseEntry)", and resolve the dependency reported in this error message.
users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
On 6/14/19 2:38 PM, Patrick Dupre wrote:
- I expect that I would have to edit the .spec file
That's right. You do. And that's expected. http://cpanspec.sourceforge.net/ indicates: "It is assumed that maintainers will need to do some (hopefully small) amount of work to clean up the generated spec file to make the package build and to verify that all of the information contained in the spec file is correct. "
cpanspec was never expected to be a 100% solution. It's a tool that assists packagers, but packagers still need to do some work.
- After that I install the package
perl-Tk-JBrowseEntry-5.22-1.fc30.noarch I generate a perl-Tk-JFileDialog.spec which contains: BuildRequires: perl(Tk::JBrowseEntry) >= 4.63
Why that?
cpanspec reads the META.json file provided by Tk-JFileDialog, which indicates that it needs Tk::JBrowseEntry >= 4.63, and then translates that information into the spec so that rpm will also know about that requirement.
Error: Problem: conflicting requests
- nothing provides perl(Tk::JBrowseEntry) >= 4.63 needed by perl-Tk-JFileDialog-2.20-1.fc30.noarch
The solutions that I found are:
- add Provides: perl(Tk::JBrowseEntry) = %{version}-%{release} in perl-Tk-JBrowseEntry.spec or
- remove BuildRequires: perl(Tk::JBrowseEntry) >= 4.63 in perl-Tk-JFileDialog.spec
There is a third solution: Add "BuildRequires: perl-generators" in perl-Tk-JBrowseEntry.spec (or use the "--add-buildrequires perl-generators" argument to cpanspec). That will automatically generate the "provides" so that you don't have to do #1 yourself.
In my opinion, I should not have to edit the .spec files
cpanspec appears to be unmaintained, and Fedora guidelines have changed since 2013. I outlined a number of improvements that should be made in order to conform to current guidelines, but only two stand out as being strictly necessary: adding the missing installed files to the %files section, and adding a buildrequires for perl-generators.
I'd encourage you to remember that Free Software is built on a culture of participation. I understand that the tool you are using isn't perfect, but no one here is the maintainer of that tool. Complaining about it will not solve the problem, but participating might. If you think the tool needs to be improved, please create a fork and improve the tool.
On Fri, 14 Jun 2019 23:38:56 +0200, Patrick Dupre wrote:
perl-Tk-JBrowseEntry-5.22-1.fc30.noarch
The solutions that I found are:
- add Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
in perl-Tk-JBrowseEntry.spec or 2) remove BuildRequires: perl(Tk::JBrowseEntry) >= 4.63 in perl-Tk-JFileDialog.spec
These two steps contradict eachother.
The package created by step 1 meets the build requirements of the package you want to build. 5.22 >= 4.63, so it is not necessary to remove the BuildRequires tag in step 2.
In step 1, prefer "BuildRequires: perl-generators" instead of adding the "Provides" tag manually. A Perl Module package may include more than a single module.
In my opinion, I should not have to edit the .spec files
If the output from cpanspec were perfect *and* would meet Fedora's Packaging Guidelines, too, you would not need to.
OK, Thank Michael and Gordon.
The package perl-generators was not installed. Now it makes more sense.
Another question How could I get %{_bindir}/* added in the %files section without having to edit the generated .spec file (i.e. when I run cpanspec)?
Thank
=========================================================================== Patrick DUPRÉ | | email: pdupre@gmx.com Laboratoire interdisciplinaire Carnot de Bourgogne 9 Avenue Alain Savary, BP 47870, 21078 DIJON Cedex FRANCE Tel: +33 (0)380395988 ===========================================================================
Sent: Saturday, June 15, 2019 at 5:41 PM From: "Michael Schwendt" mschwendt@gmail.com To: users@lists.fedoraproject.org Subject: Re: rpmbuild
On Fri, 14 Jun 2019 23:38:56 +0200, Patrick Dupre wrote:
perl-Tk-JBrowseEntry-5.22-1.fc30.noarch
The solutions that I found are:
- add Provides: perl(Tk::JBrowseEntry) = %{version}-%{release}
in perl-Tk-JBrowseEntry.spec or 2) remove BuildRequires: perl(Tk::JBrowseEntry) >= 4.63 in perl-Tk-JFileDialog.spec
These two steps contradict eachother.
The package created by step 1 meets the build requirements of the package you want to build. 5.22 >= 4.63, so it is not necessary to remove the BuildRequires tag in step 2.
In step 1, prefer "BuildRequires: perl-generators" instead of adding the "Provides" tag manually. A Perl Module package may include more than a single module.
In my opinion, I should not have to edit the .spec files
If the output from cpanspec were perfect *and* would meet Fedora's Packaging Guidelines, too, you would not need to. _______________________________________________ users mailing list -- users@lists.fedoraproject.org To unsubscribe send an email to users-leave@lists.fedoraproject.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org