Spec URL: ftp://ftp.uni-siegen.de/pub/review/zef/spec/zef.spec SRPM URL: ftp://ftp.uni-siegen.de/pub/review/zef/srpm/zef-0.20170520git.1490608-1.fc25.src.rpm Description: Zef is a Perl6 module manager. Fedora Account System Username: gerd
scratch builds are: rawhide: - https://koji.fedoraproject.org/koji/taskinfo?taskID=19672189 f26: - https://koji.fedoraproject.org/koji/taskinfo?taskID=19672686 f25: - https://koji.fedoraproject.org/koji/taskinfo?taskID=19672198
I added a version dependent Requires to rakudo. Requires: rakudo >= %(rpm -q --queryformat="%{Version}" rakudo) I am not sure if this is necessary. The requires '/usr/bin/perl6' and '/usr/bin/perl6-m' are added automatically. May be it is nice to be sure to have the same binary version. $ rpm -q --requires zef /usr/bin/perl6 /usr/bin/perl6-m rakudo >= 0.2017.04.2 ... A new F25 scratch build with that is at: - https://koji.fedoraproject.org/koji/taskinfo?taskID=19684275
enhanced Description is: %description Zef is a Perl6 module manager that query, download, update and install modules from of a file path (starting with . or /), URNs, URLs, paths, or identities from the Perl6 modules directory: https://modules.perl6.org/ It automates and simplifies the installation. Depending on your privileges zef installs the modules at the system directories or at the home directory in '.perl6' or if you specify a destination then to that destination directory. May be the package better should be renamed to 'rakudo-zef' or 'perl6-zef'. I would prefer the 'rakudo' prefix if a prefix should be added. At the URL ftp://ftp.uni-siegen.de/pub/review/rakudo-xml-writer/spec/rakudo-xml-writer.spec is a spec-file of a Perl6 module that would build with having this zef package installed. I hope the review of the zef package will not be difficult.
A few quick comments: I think running rpm database queries in the package build is a bad idea. This may fail when building in a chroot environment populated using a version of rpm using a different version of libdb to the target for instance. Can't you get the rakudo version from rakudo itself? Do you know of any other perl6 packages in Fedora already? At this stage there don't appear to be any Perl6 packaging guidelines so it would be good to at least be consistent with what's there already, if anything. I don't think you need to gzip the manpage; rpm should do that itself, and may choose to use a different compression format in the future. You should BR: perl-podlators for pod2man. Consider also optionally adding BR: for coreutils and sed, which the spec calls for in %install.
(In reply to Paul Howarth from comment #4) > A few quick comments: > > I think running rpm database queries in the package build is a bad idea. > This may fail when building in a chroot environment populated using a > version of rpm using a different version of libdb to the target for > instance. Can't you get the rakudo version from rakudo itself? The command perl6 -e 'say $*PERL.version' v6.c do not what we need. As far as I know there is no special variable for it. The only think I know is to filter the output of 'perl6 -v' For example: perl6 -v | head -n1 | sed -e 's/This is Rakudo version //' | sed -e 's/ built on.*// > Do you know of any other perl6 packages in Fedora already? At this stage > there don't appear to be any Perl6 packaging guidelines so it would be good > to at least be consistent with what's there already, if anything. There are currently only the packages MoarVM > NQP > rakudo in Fedora. My be could have a group package (rakudo-star) on top, for installing all the stuff together like it is for livetex. Perhaps the experience of packaging Perl 5 will help. > > I don't think you need to gzip the manpage; rpm should do that itself, and > may choose to use a different compression format in the future. > > You should BR: perl-podlators for pod2man. Consider also optionally adding > BR: for coreutils and sed, which the spec calls for in %install. The new srpm-URL is: ftp://ftp.uni-siegen.de/pub/review/zef/srpm/zef-0.20170520git.1490608-2.fc25.src.rpm ftp://ftp.uni-siegen.de/pub/review/zef/spec/zef.spec links to version 2 of the spec file. - the manpage is not explicitly gzipped any more - add BR: coreutils sed and perl-podlators
I could add a file with the rakudo rpm version at the rakudo package.
I see some interesting discussion on Perl6 packaging (for debian, but similar considerations apply in Fedora): https://github.com/ugexe/zef/issues/117 It would be nice to be able to use --install-to=vendor but zef doesn't currently appear to support a --destdir=%{buildroot} sort of thing. I think it could be useful for rakudo to drop a file into /usr/lib/rpm/macros.d (like perl-macros does) containing its version number, which would be a convenient way for module packagers to add the necessary dependency. Such a file might also include definitions like %perl6_vendorlib, %perl6_sitearch etc.
From the current git checkout of zef it is only possible to use: -install-to=%{buildroot}.. But the zef command from the package works. > https://github.com/ugexe/zef/issues/117 It is interesting to read this imported information. > > It would be nice to be able to use --install-to=vendor but zef doesn't > currently appear to support a --destdir=%{buildroot} sort of thing. > > I think it could be useful for rakudo to drop a file into /usr/lib/rpm/macros.d > (like perl-macros does) containing its version number, which would be a > convenient way for module packagers to add the necessary dependency. Such a > file might also include definitions like %perl6_vendorlib, %perl6_sitearch etc. > I think 'vendordir' and 'sitedir' should be get from the installed rakudo: > perl6 -e '.say for $*REPO.repo-chain;' inst#/home/userhome/.perl6 inst#/usr/lib64/perl6/site inst#/usr/lib64/perl6/vendor inst#/usr/lib64/perl6 CompUnit::Repository::AbsolutePath.new(next-repo => CompUnit::Repository::NQP.new(next-repo => CompUnit::Repository::Perl5.new(next-repo => CompUnit::Repository))) CompUnit::Repository::NQP.new(next-repo => CompUnit::Repository::Perl5.new(next-repo => CompUnit::Repository)) CompUnit::Repository::Perl5.new(next-repo => CompUnit::Repository) > (The command is at the URL: https://docs.perl6.org/language/5to6-perlvar) I also find something nice for the release version: > perl6 -e '.say for $*PERL.compiler.version;' v2017.04.2 >
In a first test I tried this: > cat /usr/lib/rpm/macros.d/macros.perl6 %rakudo_version %(perl6 -e 'say $*PERL.compiler.version;') >
The new srpm-URL is: ftp://ftp.uni-siegen.de/pub/review/zef/srpm/zef-0.20170520git.1490608-3.fc25.src.rpm ftp://ftp.uni-siegen.de/pub/review/zef/spec/zef.spec links to version 3 of the spec file. This macros are added: %define __perl6 /usr/bin/perl6 %define rakudo_rpm_version %(%{__perl6} -e 'say $*PERL.compiler.version;' | %{__sed} s/v/0./) I will drop the file /usr/lib/rpm/macros.d/macros.perl6 with equivalent macros at the next update of the rakudo package. Suggestions for more perl6 macros are welcome. I am not sure if it would be perhaps better to hard-code the rakudo rpm version number at the build of rakudo in the macro file.
I created a github repository https://github.com/gerd/macro.perl6.git with a draft for the file macros.perl6 (https://github.com/gerd/macro.perl6/blob/master/macros.perl6) to collect code and suggestions.
I think perl6 code in rpms should be in the vendor directories rather than the site directories. I think the precompiling of the code should happen in the rpm, as is done for python packages, but how tight a dependency on compiler version would that require? I imagine having to do a mass rebuild of all perl6 modules for minor updates of rakudo would be an onerous task if it was necessary. (In reply to Gerd Pokorra from comment #11) > I created a github repository > > https://github.com/gerd/macro.perl6.git > > with a draft for the file macros.perl6 > (https://github.com/gerd/macro.perl6/blob/master/macros.perl6) to collect > code and suggestions. I think hard-coding version numbers and directory locations is fine, particularly if the file comes with/is built from the rakudo package itself, which is where these things would be specified anyway. Everything should at least be consistent then. I think now is probably a time to brainstorm how to do perl6 packaging rather moving forward with it just yet: I'll have limited computer access next week and Petr may be busy with the Perl 5.26 mass rebuild in rawhide, though i think Jitka is running with that.
Thank you for your support so far Paul. I like the idea that the rakudo package should provide a macro file. Thank you for the information and organisation that someone is running on that. I will be on a trip this weekend. Next week I will not have much time. So I can not do a rakudo package update before the next 7 or 14 days.
Builds for rakudo that adds a RPM build macro file for Perl6 modules are done. rawhide (f27): https://koji.fedoraproject.org/koji/taskinfo?taskID=19902606 f26: https://koji.fedoraproject.org/koji/taskinfo?taskID=19908927 according Update URL: https://bodhi.fedoraproject.org/updates/FEDORA-2017-75884c20f5 or https://bodhi.fedoraproject.org/updates/rakudo-0.2017.04.2-4.fc26 f25: https://koji.fedoraproject.org/koji/taskinfo?taskID=19908941 according Update URL: https://bodhi.fedoraproject.org/updates/FEDORA-2017-8affb99954 or https://bodhi.fedoraproject.org/updates/rakudo-0.2017.04.2-4.fc25 The content of the /usr/lib/rpm/macros.d/macros.perl6 file for a 64bit architecture is: > cat /usr/lib/rpm/macros.d/macros.perl6 # Perl6-specific RPM build macros for Perl6 modules. # %__perl6 /usr/bin/perl6 %rakudo_rpm_version 0.2017.04.2 %perl6_vendor_dir /usr/lib64/perl6/vendor %perl6_site_dir /usr/lib64/perl6/site >
Brainstorming how to do perl6 module packaging: I will try the perl6 script 'tools/install-dist.pl' from the rakudo sources and report about it here.
It is easier and better to use the perl6 script 'tools/install-dist.pl' to packaging perl6 modules, I think. At the URL - ftp://ftp.uni-siegen.de/pub/review/rakudo-json-tiny/srpm/rakudo-json-tiny-0.20170612git-1.fc25.src.rpm I uploaded an srpm as example that uses the perl6 program 'install-dist.pl'. The file is included as Source1 and taken from Radkudo 2017.05 and is the same in Raduod-Star 2017.05. I intend to make a new rakudo package that provides the install-dist.pl tool and store it as %{_libdir}/perl6/bin/mod_inst.pl. I intent also to add a macro for it: %perl6_mod_inst /usr/lib64/perl6/bin/mod_inst.pl The SRPM rakudo-json-tiny uses the macros (rakudo_rpm_version and erl6_vendor_dir) from the rakudo package that is currently in the testing state: $ bodhi rakudo | head -2 No handlers could be found for logger "fedora.client.bodhi" 14 updates found (14 shown) rakudo-0.2017.04.2-4.fc25 enhancement testing 2017-06-09 rakudo-0.2017.04.2-4.fc26 enhancement testing 2017-06-09 $ Could the review of the zef package go on? It is at least a nice tool to list the installed Perl6 modules: $ zef list --installed ===> Found via /usr/lib64/perl6/site zef:ver('0.1.14'):auth('github:ugexe') XML::Writer ===> Found via /usr/lib64/perl6 CORE:ver('6.c'):auth('perl') ===> Found via /usr/lib64/perl6/vendor JSON::Tiny $ Is the use of export QA_SKIP_BUILD_ROOT=1 a reason that the package can not pass the review or does it not matter? As next I will make builds that use the new macros. For the zef package I like the %{perl6_site_dir} as destination.
The new srpm-URL is: - ftp://ftp.uni-siegen.de/pub/review/zef/srpm/zef-0.20170520git.1490608-4.fc25.src.rpm ftp://ftp.uni-siegen.de/pub/review/zef/spec/zef.spec links to version 4 of the spec file. rawhide scratch build URL: - https://koji.fedoraproject.org/koji/taskinfo?taskID=20001297 The rpmlint output looks normal: $ rpmlint zef.spec zef.spec: W: no-%build-section 0 packages and 1 specfiles checked; 0 errors, 1 warnings. $ $ rpmlint /home/gz016/rpmbuild/RPMS/x86_64/zef-0.20170520git.1490608-4.fc25.x86_64.rpm zef.x86_64: E: no-binary zef.x86_64: W: only-non-binary-in-usr-lib 1 packages and 0 specfiles checked; 1 errors, 1 warnings. $
- remove QA_SKIP_BUILD_ROOT variable - split installation in two steps - add information of the creating of the tar archive - rename the package to rakudo-zef - update to 0.20170619git.48efafc Successful scratch builds: F25: https://koji.fedoraproject.org/koji/taskinfo?taskID=20065540 F26: https://koji.fedoraproject.org/koji/taskinfo?taskID=20065487 The new srpm-URL is: ftp://ftp.uni-siegen.de/pub/review/zef/srpm/rakudo-zef-0.20170619git.48efafc-1.fc25.src.rpm ftp://ftp.uni-siegen.de/pub/review/zef/spec/rakudo-zef.spec links to version 1 of the new rakudo-zef spec file of the new zef version. I renamed the package to rakudo-zef, because with installing 'dnf install rakudo-*' the package manager should be installed. rakudo builds of 2017.06 are done and provides the script tools/install-dist.pl with macro as: %perl6_mod_inst /usr/lib64/perl6/bin/mod_inst.pl This rakudo updates are at: F25: https://bodhi.fedoraproject.org/updates/FEDORA-2017-0e46c90218 F26: https://bodhi.fedoraproject.org/updates/FEDORA-2017-38e81c3b2c The rakudo-zef spec file do not use the tools/install-dist.pl script, I like to use the own 'bin/zef install' command for the zef build. The rakudo-zef package need the macros provided from the rakudo-version >= 0.2017.04.2-4 to build which is in the update repository of F25 and F26.
After removing the BUILD directory I noticed that the package do not work any more. So I uploaded again a new version without that problem: The new srpm-URL is: - ftp://ftp.uni-siegen.de/pub/review/zef/srpm/rakudo-zef-0.20170619git.48efafc-1.fc25.src.rpm ftp://ftp.uni-siegen.de/pub/review/zef/spec/rakudo-zef.spec links to version 2 of the rakudo-zef spec file. - added check-section - switched to install with the 'tools/install-dist.pl' script from the rakudo sources - install to vendor_dir URL of a rawhide scratch build: https://koji.fedoraproject.org/koji/taskinfo?taskID=20070176 rakudo-zef builds with the rakudo version 0.2017.06 in rawhide and the currently updates in the testing repository of F25 and F26.
- get the sources from the Perl6 directory of CPAN The spec file corresponds to the 'Fedora Packaging Guidelines for Perl 6 Modules' - https://fedoraproject.org/wiki/Packaging/Perl6?rd=Packaging/Perl6 The new srpm-URL is: - ftp://ftp.uni-siegen.de/pub/review/zef/srpm/rakudo-zef-0.1.15-1.fc25.src.rpm - ftp://ftp.uni-siegen.de/pub/review/zef/spec/rakudo-zef.spec links to version 3 of the rakudo-zef spec file. Successful scratch builds are at: F25 https://koji.fedoraproject.org/koji/taskinfo?taskID=20262875 F26 https://koji.fedoraproject.org/koji/taskinfo?taskID=20264274 F27 https://koji.fedoraproject.org/koji/taskinfo?taskID=20262886 The rakudo-zef package could be installed from the scratch build > wget https://kojipkgs.fedoraproject.org//work/tasks/2877/20262877/rakudo-zef-0.1.15-1.fc25.x86_64.rpm > dnf install rakudo-zef-0.1.15-1.fc25.x86_64.rpm and works fine: > zef list --installed ===> Found via /usr/lib64/perl6 CORE:ver('6.c'):auth('perl') ===> Found via /usr/lib64/perl6/vendor zef:ver('0.1.15'):auth('github:ugexe') >
Hello, - https://travis-ci.org/ugexe/zef doesn't seem to be a suitable URL for a homepage. Check https://github.com/ugexe/zef instead - The latest published version on https://github.com/ugexe/zef is 0.1.27, I guess you should bump the package like this: URL: https://github.com/ugexe/zef Source0: %url/archive/v%{version}/%{name}-%{version}.tar.gz Although the package builds fine on Fedora 27, it fails to build on Rawhide: >+ /usr/lib64/perl6/bin/mod_inst.pl --to=/builddir/build/BUILDROOT/rakudo-zef-0.1.27-1.fc28.x86_64/usr/lib64/perl6/vendor --for=vendor >Unhandled exception: While looking for 'ModuleLoader.moarvm': no such file or directory > at <unknown>:1 (/usr/lib64/perl6/runtime/perl6.moarvm:<dependencies+deserialize>) > I'm not a Perl specialist, maybe you have some insight as to why it fails with such error.
I have done a test build in rawhide. A complete rebuild of the rakudo stack (moarvm, nqp and rakudo rpms) fixed the problem in rawhide. The specfile is changed to take the source tar file from Github. Rakudo 2017.08 do not build on the architectures s390x ppc64, so the zef package do need also to exclude them. The appropriate changelog entry is: - get the sources from Github - need to exclude the architectures: s390x ppc64 - update to 0.1.29 The new srpm-URL is: - ftp://ftp.uni-siegen.de/pub/review/zef/srpm/rakudo-zef-0.1.29-1.fc26.src.rpm - ftp://ftp.uni-siegen.de/pub/review/zef/spec/rakudo-zef.spec links to version 5 of the rakudo-zef spec file. Successful scratch builds are at: F28 (rawhide): https://koji.fedoraproject.org/koji/taskinfo?taskID=21877183 F27: https://koji.fedoraproject.org/koji/taskinfo?taskID=21877346 F26: https://koji.fedoraproject.org/koji/taskinfo?taskID=21877459
Perfect, package accepted. Thanks for your work!
(fedrepo-req-admin): The Pagure repository was created at https://src.fedoraproject.org/rpms/rakudo-zef
Thank you very much for the review!!
rakudo-zef-0.1.29-1.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-fe72d7dbfc
rakudo-zef-0.1.29-1.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-fe72d7dbfc
rakudo-zef-0.1.29-1.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.