For starters, the title says **most of**, because I'm not including EPEL5 :p
To the point. Now that we have some common ground between the packaging guidelines, I'm trying to get together a template for packaging: fc19, fc20, fc21, el6, el7.
I haven't yet packaged anything for EPEL6, so I searched ruby-sig and found some answers. So far I have written down the R/BR, so please correct me I am wrong. Here goes:
``` %if 0%{?fc19} || 0%{?fc20} || 0%{?el7} Requires: ruby(release) Requires: ruby(rubygems) %endif
%if 0%{?el6} Requires: ruby(abi) >= %{rubyabi} Requires: ruby(rubygems) BuildRequires: ruby(abi) >= %{rubyabi} %else BuildRequires: ruby(release) %endif
BuildRequires: rubygems-devel
%if 0%{?fc19} || 0%{?fc20} || 0%{?el7} || 0%{?el6} Provides: rubygem(%{gem_name}) = %{version} %endif ```
Next parts are:
1) if gem has native extensions: different %install macro 2) if gem has minitest: build minitest5 for el7 [0]
If I left something out please advise.
Thanks!
[0] https://admin.fedoraproject.org/pkgdb/package/rubygem-minitest/
Better to not go this way ...
This is wrong:
ruby(abi) >= %{rubyabi}
it should be:
ruby(abi) = %{rubyabi}
Vít
Dne 18.6.2014 16:08, Achilleas Pipinellis napsal(a):
For starters, the title says **most of**, because I'm not including EPEL5 :p
To the point. Now that we have some common ground between the packaging guidelines, I'm trying to get together a template for packaging: fc19, fc20, fc21, el6, el7.
I haven't yet packaged anything for EPEL6, so I searched ruby-sig and found some answers. So far I have written down the R/BR, so please correct me I am wrong. Here goes:
%if 0%{?fc19} || 0%{?fc20} || 0%{?el7} Requires: ruby(release) Requires: ruby(rubygems) %endif %if 0%{?el6} Requires: ruby(abi) >= %{rubyabi} Requires: ruby(rubygems) BuildRequires: ruby(abi) >= %{rubyabi} %else BuildRequires: ruby(release) %endif BuildRequires: rubygems-devel %if 0%{?fc19} || 0%{?fc20} || 0%{?el7} || 0%{?el6} Provides: rubygem(%{gem_name}) = %{version} %endif
Next parts are:
- if gem has native extensions: different %install macro
- if gem has minitest: build minitest5 for el7 [0]
If I left something out please advise.
Thanks!
[0] https://admin.fedoraproject.org/pkgdb/package/rubygem-minitest/
On 06/18/2014 05:23 PM, Vít Ondruch wrote:
Better to not go this way ...
Do you mean this whole approach is wrong?
I guess the cleanest option would be to have separate branches.
This is wrong:
ruby(abi) >= %{rubyabi}
it should be:
ruby(abi) = %{rubyabi}
Vít
Dne 18.6.2014 16:08, Achilleas Pipinellis napsal(a):
For starters, the title says **most of**, because I'm not including EPEL5 :p
To the point. Now that we have some common ground between the packaging guidelines, I'm trying to get together a template for packaging: fc19, fc20, fc21, el6, el7.
I haven't yet packaged anything for EPEL6, so I searched ruby-sig and found some answers. So far I have written down the R/BR, so please correct me I am wrong. Here goes:
%if 0%{?fc19} || 0%{?fc20} || 0%{?el7} Requires: ruby(release) Requires: ruby(rubygems) %endif %if 0%{?el6} Requires: ruby(abi) >= %{rubyabi} Requires: ruby(rubygems) BuildRequires: ruby(abi) >= %{rubyabi} %else BuildRequires: ruby(release) %endif BuildRequires: rubygems-devel %if 0%{?fc19} || 0%{?fc20} || 0%{?el7} || 0%{?el6} Provides: rubygem(%{gem_name}) = %{version} %endif
Next parts are:
- if gem has native extensions: different %install macro
- if gem has minitest: build minitest5 for el7 [0]
If I left something out please advise.
Thanks!
[0] https://admin.fedoraproject.org/pkgdb/package/rubygem-minitest/
ruby-sig mailing list ruby-sig@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/ruby-sig
Dne 18.6.2014 16:48, Achilleas Pipinellis napsal(a):
On 06/18/2014 05:23 PM, Vít Ondruch wrote:
Better to not go this way ...
Do you mean this whole approach is wrong?
I guess the cleanest option would be to have separate branches.
Yes, that is the point. I update the older branches just rarely, typically just due to security bug. In such case, it is typically easier just cherry-pick the single change.
On the other hand, conditions makes the file unreadable, fragile and it makes harder to fix the .spec file by migration scripts, if the guidelines are updated.
However some may disagree with me ;)
Vít
This is wrong:
ruby(abi) >= %{rubyabi}
it should be:
ruby(abi) = %{rubyabi}
Vít
Dne 18.6.2014 16:08, Achilleas Pipinellis napsal(a):
For starters, the title says **most of**, because I'm not including EPEL5 :p
To the point. Now that we have some common ground between the packaging guidelines, I'm trying to get together a template for packaging: fc19, fc20, fc21, el6, el7.
I haven't yet packaged anything for EPEL6, so I searched ruby-sig and found some answers. So far I have written down the R/BR, so please correct me I am wrong. Here goes:
%if 0%{?fc19} || 0%{?fc20} || 0%{?el7} Requires: ruby(release) Requires: ruby(rubygems) %endif %if 0%{?el6} Requires: ruby(abi) >= %{rubyabi} Requires: ruby(rubygems) BuildRequires: ruby(abi) >= %{rubyabi} %else BuildRequires: ruby(release) %endif BuildRequires: rubygems-devel %if 0%{?fc19} || 0%{?fc20} || 0%{?el7} || 0%{?el6} Provides: rubygem(%{gem_name}) = %{version} %endif
Next parts are:
- if gem has native extensions: different %install macro
- if gem has minitest: build minitest5 for el7 [0]
If I left something out please advise.
Thanks!
[0] https://admin.fedoraproject.org/pkgdb/package/rubygem-minitest/
ruby-sig mailing list ruby-sig@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/ruby-sig
Achilleas Pipinellis píše v st 18. 06. 2014 v 17:08 +0300:
To the point. Now that we have some common ground between the packaging guidelines, I'm trying to get together a template for packaging: fc19, fc20, fc21, el6, el7.
I haven't yet packaged anything for EPEL6, so I searched ruby-sig and found some answers. So far I have written down the R/BR, so please correct me I am wrong. Here goes:
%if 0%{?fc19} || 0%{?fc20} || 0%{?el7} Requires: ruby(release) Requires: ruby(rubygems) %endif %if 0%{?el6} Requires: ruby(abi) >= %{rubyabi} Requires: ruby(rubygems) BuildRequires: ruby(abi) >= %{rubyabi} %else BuildRequires: ruby(release) %endif BuildRequires: rubygems-devel %if 0%{?fc19} || 0%{?fc20} || 0%{?el7} || 0%{?el6} Provides: rubygem(%{gem_name}) = %{version} %endif
Next parts are:
- if gem has native extensions: different %install macro
- if gem has minitest: build minitest5 for el7 [0]
If I left something out please advise.
Plus "3)": add runtime gem-specific requires for Fedora <= 20 and EPEL <= 7.
Independently I got this result (with the explicit EPEL6 ABI fix):
%if 0%{?rhel} && 0%{?rhel} <= 6 Requires: ruby(abi) = %{rubyabi} %else Requires: ruby(release) %endif %if 0%{?fedora} && 0%{?fedora} <= 20 || 0%{?rhel} && 0%{?rhel} <= 7 Requires: ruby(rubygems) Provides: rubygem(%{gem_name}) = %{version} %endif
... which looks equivalent.
Cheers, Frantisek
ruby-sig@lists.fedoraproject.org