Spec URL: https://raw.githubusercontent.com/bkircher/botan2-fedora/master/botan2.spec SRPM URL: https://github.com/bkircher/botan2-fedora/raw/master/botan2-2.2.0-1.fc26.src.rpm Description: Botan is a BSD-licensed crypto library written in C++. It provides a wide variety of basic cryptographic algorithms, X.509 certificates and CRLs, PKCS \#10 certificate requests, a filter/pipe message processing system, and a wide variety of other features, all written in portable C++. The API reference, tutorial, and examples may help impart the flavor of the library. This is the current stable release branch 2.x of Botan. Fedora Account System Username: bkircher copr repo for F26: https://copr.fedorainfracloud.org/coprs/bkircher/botan2/
Hello, - Requires: pkgconfig is not needed - The Group: tag is not used in Fedora. See https://fedoraproject.org/wiki/Packaging:Guidelines#Tags_and_Sections - You could use %make_build instead of make %{?_smp_mflags} - You could use pkgconfig for your BR: BuildRequires: pkgconfig(bzip2) BuildRequires: pkgconfig(zlib) BuildRequires: pkgconfig(openssl) - You don't need to repeat the following BR for the devel subpackage: Requires: bzip2-devel Requires: zlib-devel Requires: openssl-devel - Use %{python3_version} instead of $(rpm -q --provides python3 |grep -i abi|awk '{ print $3 }') - You must add license.txt in %license for all the subpackages combinaisons: %files %license license.txt %dir %{_pkgdocdir} %{_pkgdocdir}/*.txt %{_libdir}/libbotan-%{major_version}.so.* %{_bindir}/botan %files devel %{_includedir}/* %exclude %{_libdir}/libbotan-%{major_version}.a %{_libdir}/libbotan-%{major_version}.so %{_libdir}/pkgconfig/botan-%{major_version}.pc %files doc %license license.txt %dir %{_pkgdocdir} %{_pkgdocdir}/manual %files -n python3-%{name} %license license.txt %{python3_sitearch}/%{name}2.py %{python3_sitearch}/__pycache__/* - There are a couple of relevant rpmlint errors: botan.x86_64: E: binary-or-shlib-defines-rpath /usr/bin/botan ['$ORIGIN'] See https://fedoraproject.org/wiki/Packaging:Guidelines#Removing_Rpath for how to remove Rpath. python3-botan.x86_64: E: non-executable-script /usr/lib64/python3.6/site-packages/botan2.py 644 /usr/bin/env python You need to set this script executable in %install. Regarding your sponsorship, I can't help you, but you should introduce yourself on fedora-devel and do some informal reviews of other packages to show potential sponsors that you understand Fedora Packaging Guidelines.
Thanks for reviewing, appreciated :) All done, except: > - You could use pkgconfig for your BR: > > BuildRequires: pkgconfig(bzip2) > BuildRequires: pkgconfig(zlib) > BuildRequires: pkgconfig(openssl) With the rpath issue > botan.x86_64: E: binary-or-shlib-defines-rpath /usr/bin/botan ['$ORIGIN'] I added a patch that removes -rpath from the linker flags on gcc. New files: Spec URL: https://raw.githubusercontent.com/bkircher/botan2-fedora/master/botan2.spec SRPM URL: https://github.com/bkircher/botan2-fedora/raw/master/botan2-2.2.0-2.fc26.src.rpm
A couple of issues: - botan-test doesn't find its library in the path because botan2 is not technically installed at that point, just packaged. So to solve this, I add %{buildroot}%{_libdir} to the library path: %check export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{_libdir} ./botan-test - Second issue is your package doesn't generate debugging symbols, thus mock fails: RPM build errors: error: Empty %files file /builddir/build/BUILD/Botan-2.2.0/debugsourcefiles.list Empty %files file /builddir/build/BUILD/Botan-2.2.0/debugsourcefiles.list To solve this, add: --with-debug-info to the configure script. Package Review ============== Legend: [x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated [ ] = Manual review needed Issues: ======= - All build dependencies are listed in BuildRequires, except for any that are listed in the exceptions section of Packaging Guidelines. Note: These BR are not needed: gcc-c++ See: http://fedoraproject.org/wiki/Packaging/Guidelines#Exceptions_2 ===== MUST items ===== C/C++: [ ]: Package does not contain kernel modules. [ ]: Package contains no static executables. [x]: Header files in -devel subpackage, if present. [x]: ldconfig called in %post and %postun if required. [x]: Package does not contain any libtool archives (.la) [x]: Rpath absent or only used for internal libs. [x]: Development (unversioned) .so files in -devel subpackage, if present. Generic: [x]: Package is licensed with an open-source compatible license and meets other legal requirements as defined in the legal section of Packaging Guidelines. [x]: License field in the package spec file matches the actual license. Note: Checking patched sources after %prep for licenses. Licenses found: "BSD (unspecified)", "BSD (2 clause)", "Unknown or generated". 1855 files have unknown license. Detailed output of licensecheck in /home/bob/packaging/review/botan/review-botan2/licensecheck.txt [x]: License file installed when any subpackage combination is installed. [x]: %build honors applicable compiler flags or justifies otherwise. [x]: Package contains no bundled libraries without FPC exception. [x]: Changelog in prescribed format. [x]: Sources contain only permissible code or content. [-]: Package contains desktop file if it is a GUI application. [x]: Development files must be in a -devel package [x]: Package uses nothing in %doc for runtime. [x]: Package consistently uses macros (instead of hard-coded directory names). [x]: Package is named according to the Package Naming Guidelines. [x]: Package does not generate any conflict. [x]: Package obeys FHS, except libexecdir and /usr/target. [-]: If the package is a rename of another package, proper Obsoletes and Provides are present. [x]: Requires correct, justified where necessary. [x]: Spec file is legible and written in American English. [-]: Package contains systemd file(s) if in need. [!]: Useful -debuginfo package or justification otherwise. [x]: Package is not known to require an ExcludeArch tag. [-]: Large documentation must go in a -doc subpackage. Large could be size (~1MB) or number of files. Note: Documentation size is 215040 bytes in 5 files. [x]: Package complies to the Packaging Guidelines [x]: Package successfully compiles and builds into binary rpms on at least one supported primary architecture. [x]: Package installs properly. [x]: Rpmlint is run on all rpms the build produces. Note: There are rpmlint messages (see attachment). [x]: If (and only if) the source package includes the text of the license(s) in its own file, then that file, containing the text of the license(s) for the package is included in %license. [x]: Package requires other packages for directories it uses. [x]: Package must own all directories that it creates. [x]: Package does not own files or directories owned by other packages. [x]: Package uses either %{buildroot} or $RPM_BUILD_ROOT [x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the beginning of %install. [x]: Macros in Summary, %description expandable at SRPM build time. [x]: Dist tag is present. [x]: Package does not contain duplicates in %files. [x]: Permissions on files are set properly. [x]: Package use %makeinstall only when make install DESTDIR=... doesn't work. [x]: Package is named using only allowed ASCII characters. [x]: Package does not use a name that already exists. [x]: Package is not relocatable. [x]: Sources used to build the package match the upstream source, as provided in the spec URL. [x]: Spec file name must match the spec package %{name}, in the format %{name}.spec. [x]: File names are valid UTF-8. [x]: Packages must not store files under /srv, /opt or /usr/local Python: [x]: Python eggs must not download any dependencies during the build process. [x]: A package which is used by another package via an egg interface should provide egg info. [x]: Package meets the Packaging Guidelines::Python [x]: Package contains BR: python2-devel or python3-devel [x]: Binary eggs must be removed in %prep ===== SHOULD items ===== Generic: [-]: Avoid bundling fonts in non-fonts packages. Note: Package contains font files [-]: If the source package does not include license text(s) as a separate file from upstream, the packager SHOULD query upstream to include it. [x]: Final provides and requires are sane (see attachments). [x]: Fully versioned dependency in subpackages if applicable. Note: No Requires: %{name}%{?_isa} = %{version}-%{release} in botan2-doc , python3-botan2 , botan2-debuginfo [?]: Package functions as described. [x]: Latest version is packaged. [x]: Package does not include license text files separate from upstream. [x]: Patches link to upstream bugs/comments/lists or are otherwise justified. [x]: Scriptlets must be sane, if used. [-]: Description and summary sections in the package spec file contains translations for supported Non-English languages, if available. [x]: Package should compile and build into binary rpms on all supported architectures. [x]: %check is present and all tests pass. [x]: Packages should try to preserve timestamps of original installed files. [x]: Reviewer should test that the package builds in mock. [x]: Buildroot is not present [x]: Package has no %clean section with rm -rf %{buildroot} (or $RPM_BUILD_ROOT) [x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin. [x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file [x]: The placement of pkgconfig(.pc) files are correct. [x]: Sources can be downloaded from URI in Source: tag [x]: SourceX is a working URL. [x]: Spec use %global instead of %define unless justified. ===== EXTRA items ===== Generic: [x]: Rpmlint is run on debuginfo package(s). Note: There are rpmlint messages (see attachment). [x]: Rpmlint is run on all installed packages. Note: There are rpmlint messages (see attachment). [x]: Large data in /usr/share should live in a noarch subpackage if package is arched. [x]: Spec file according to URL is the same as in SRPM. Rpmlint ------- Checking: botan2-2.2.0-2.fc28.x86_64.rpm botan2-devel-2.2.0-2.fc28.x86_64.rpm botan2-doc-2.2.0-2.fc28.noarch.rpm python3-botan2-2.2.0-2.fc28.x86_64.rpm botan2-debuginfo-2.2.0-2.fc28.x86_64.rpm botan2-2.2.0-2.fc28.src.rpm botan2.x86_64: W: spelling-error Summary(en_US) Crypto -> Crypt, Crypts, Crypt o botan2.x86_64: W: spelling-error %description -l en_US Botan -> Wotan, Baton, Botany botan2.x86_64: W: spelling-error %description -l en_US crypto -> crypt, crypts, crypt o botan2.x86_64: W: spelling-error %description -l en_US cryptographic -> cryptography, cryptographer, crystallographic botan2.x86_64: W: hidden-file-or-dir /usr/lib/.build-id botan2.x86_64: W: hidden-file-or-dir /usr/lib/.build-id botan2.x86_64: W: no-manual-page-for-binary botan botan2-devel.x86_64: W: only-non-binary-in-usr-lib botan2-devel.x86_64: W: no-documentation python3-botan2.x86_64: W: only-non-binary-in-usr-lib python3-botan2.x86_64: W: no-documentation python3-botan2.x86_64: E: wrong-script-interpreter /usr/lib64/python3.6/site-packages/botan2.py /usr/bin/env python3 botan2.src: W: spelling-error Summary(en_US) Crypto -> Crypt, Crypts, Crypt o botan2.src: W: spelling-error %description -l en_US Botan -> Wotan, Baton, Botany botan2.src: W: spelling-error %description -l en_US crypto -> crypt, crypts, crypt o botan2.src: W: spelling-error %description -l en_US cryptographic -> cryptography, cryptographer, crystallographic 6 packages and 0 specfiles checked; 1 errors, 15 warnings.
You should also note that the tests fail on arch i686: Log: https://kojipkgs.fedoraproject.org//work/tasks/2044/21662044/build.log from Koji build: https://koji.fedoraproject.org/koji/taskinfo?taskID=21662044
Yes I noticed too. Sorry for that :/ Apparently my test runs were flawed because I had an older version of botan2 installed on the machine. I run rpmlint with `fedora-review --rpm-spec -n file.src.rpm` and it gives me headaches because I have to disable repos and stuff. How do you run rpmlint so quick and in a clean environment?
I just run: fedora-review -m fedora-rawhide-x86_64 -n botan2 It uses a mock chroot so it's clean. If it's not "clean enough", you can scrub the chroot: mock -r fedora-rawhide-x86_64 --scrub=all It's not quick though.
Ah, thanks! Now I know how to test against Rawhide which I should do anyway :) Fixed above issues. rpmlint still reports two errors, though. python3-botan2.x86_64: E: wrong-script-interpreter /usr/lib64/python3.6/site-packages/botan2.py /usr/bin/env python3 botan2-debuginfo.x86_64: E: useless-provides debuginfo(build-id) Both are errors in rpmlint, methinks. But I can be wrong. New/updated files: Spec URL: https://raw.githubusercontent.com/bkircher/botan2-fedora/master/botan2.spec SRPM URL: https://github.com/bkircher/botan2-fedora/raw/master/botan2-2.2.0-3.fc26.src.rpm
Tests still fail on i686, you should probably file a bug report upstream, and use ExclusiveArch to enable build on all arches but %{ix86}.
> Tests still fail on i686, you should probably file a bug report upstream Done (https://github.com/randombit/botan/issues/1192) and issue got already solved upstream. I added a patch to backport the fix. Upstream supports i686 explicitly so I think its best to not exclude it. New files: Spec URL: https://raw.githubusercontent.com/bkircher/botan2-fedora/master/botan2.spec SRPM URL: https://github.com/bkircher/botan2-fedora/raw/master/botan2-2.2.0-4.fc26.src.rpm
Perfect, package accepted.
Hi, Fedora Botan (1.X) packager here - would you be interested in me co-maintaining that package? I think before importing the package, you have to remove gost_3410, and maybe some of the elliptic curves (even from the tarball!) for patent reasons. spot, could you comment, please? Maybe a full legal review should be done. I currently don't have an overview of all algorithms that have been added to Botan2 compared to Botan1.
Upstream maintainer here. I'm not aware of any patents (whatsoever, in any jurisdiction) on GOST-34.10 signature scheme. Nor am I aware of any (unexpired) patents affecting the ECC code. Obviously you can remove whatever you like, but if your legal knows something I don't please share. I know Fedora previously excluded RC5 and RC6, Botan 2.x doesn't include either of those anymore (though I believe all patents there have expired in any case). Only thing added in 2.x that I know is patented is OCB mode, for which there is a free license for open source code. OpenSSL has OCB as well so I guess you would just follow whatever decision you made for them.
(In reply to Jack Lloyd from comment #12) > Upstream maintainer here. I'm not aware of any patents (whatsoever, in any > jurisdiction) on GOST-34.10 signature scheme. Nor am I aware of any > (unexpired) patents affecting the ECC code. Obviously you can remove > whatever you like, but if your legal knows something I don't please share. That's why I put spot on CC. He (with his Fedora Legal Hat on) is the one to answer what can be kept and what has to be removed. (Earlier experience shows that it might not be possible for the Legal Team to share the exact reasoning, though.) Blocking FE-Legal now. But don't get me wrong: I'd be totally happy to get their OK. > Only thing added in 2.x that I know is patented is OCB mode, for which there > is a free license for open source code. OpenSSL has OCB as well so I guess > you would just follow whatever decision you made for them. Just looking at http://web.cs.ucdavis.edu/~rogaway/ocb/license.htm , I see there is a special license for OpenSSL. I would think that we need a similar license for Botan, or we have to remove OCB from the Fedora package. The reason is, that (in my own terms, IANAL) Fedora packages need to be free and not limited to Open Source projects (for the same reason the NC variants of CC are not allowed in Fedora).
> Fedora packages need to be free and not limited to Open Source projects That logic would prohibit a GPLv3 library such as readline. The standard OCB license allows commercial use, simply requires the code be open source.
FWIW, packages updated to new upstream 2.3.0 release. New/updated files: Spec URL: https://raw.githubusercontent.com/bkircher/botan2-fedora/master/botan2.spec SRPM URL: https://github.com/bkircher/botan2-fedora/raw/master/botan2-2.3.0-1.fc27.src.rpm New Copr builds are also available: https://copr.fedorainfracloud.org/coprs/bkircher/botan2/
I'm comfortable with the standard OCB patent grant license, as it would apply to Botan's implementation of OCB. GOST-34.10 is cleared for inclusion. I'm lifting FE-Legal, Botan v2 is okay to merge into Fedora. Jack, thank you for your continued due-diligence on legal issues.
Cool. I'd be interested in co-maintaining the package if applicable.
Updated for new upstream 2.4.0 release. New/updated files: Spec URL: https://raw.githubusercontent.com/bkircher/botan2-fedora/master/botan2.spec SRPM URL: https://github.com/bkircher/botan2-fedora/raw/master/botan2-2.4.0-1.fc27.src.rpm New Copr builds here: https://copr.fedorainfracloud.org/coprs/bkircher/botan2/
(In reply to Tom "spot" Callaway from comment #16) > I'm lifting FE-Legal, Botan v2 is okay to merge into Fedora. Thanks Tom, for the clarification. I read that as "the package can be imported as is, without removing anything", (especially: "all included curves are OK"). (In reply to Benjamin Kircher from comment #18) Benjamin, unfortunately I cannot sponsor you. Should I proceed and import the package for the time being?
In reply to Thomas Moschny from comment #19 > Should I proceed and import the package for the time being? Sure, but wait a second. I want to fix one more thing in the spec file.
Changes: removed INSTALL_ variables in `make install` step; not used anymore with 2.4.0 New/updated files: Spec URL: https://raw.githubusercontent.com/bkircher/botan2-fedora/master/botan2.spec SRPM URL: https://github.com/bkircher/botan2-fedora/raw/master/botan2-2.4.0-2.fc27.src.rpm New Copr builds here: https://copr.fedorainfracloud.org/coprs/bkircher/botan2/
So, trying to create a request for a new package failed with: Error: The Bugzilla bug's review was approved over 60 days ago :( Need to find out what to do in such a case.
Now retry.
Love this tool.
Can't create the repo: The Bugzilla review bug creator didn't match the requester in Pagure. https://pagure.io/releng/fedora-scm-requests/issue/4270
Benjamin Kircher needs to do it then.
If I can be of any help here, ping me (bkircher) on #fedora-devel or shoot me a mail.
bkircher is not yet sponsored either, I can help out in that regard. Now, you (bkircher) can try: fedrepo-req botan2 -t 1487067
(fedrepo-req-admin): The Pagure repository was created at https://src.fedoraproject.org/rpms/botan2
Imported into https://src.fedoraproject.org/rpms/botan2 for rawhide/f29 Build https://koji.fedoraproject.org/koji/buildinfo?buildID=1054353
FYI, looks like botan2 hard-codes a bunch of it's own compiler/link flags, see: src/build-data/cc/gcc.txt (and throws away the distro default ones apparently)
Benjamin, as said earlier, I can co-maintain the package, if you want.
Re compile flags, configure.py script consumes flags from CXXFLAGS if set in the environment, which will override the defaults. Is there something else we should be doing here?
(In reply to Jack Lloyd from comment #33) > Re compile flags, configure.py script consumes flags from CXXFLAGS if set in > the environment, which will override the defaults. Is there something else > we should be doing here? No, that's fine. In many cases, spec files use %configure, which sets (amongst others) CXXFLAGS, but as %configure is not used here, we should use export CXXFLAGS=%{optflags} instead.
(In reply to Thomas Moschny from comment #32) > Benjamin, as said earlier, I can co-maintain the package, if you want. Of course. Any advice and help is greatly appreciated. I added you (thm) as admin to the repo on src.fedoraproject.org. If there is anything else I need to do, please let me know.
(In reply to Rex Dieter from comment #31) > FYI, looks like botan2 hard-codes a bunch of it's own compiler/link flags, > see: > src/build-data/cc/gcc.txt > (and throws away the distro default ones apparently) Fixed: https://src.fedoraproject.org/rpms/botan2/c/9c37fc9601eb1f5714a93d54c29502b94f15c92f?branch=master
Mind building botan2 for at least f27 too?
> Mind building botan2 for at least f27 too? Not from my side. Thomas, is this okay with you?
(In reply to Benjamin Kircher from comment #38) > > Mind building botan2 for at least f27 too? > > Not from my side. Thomas, is this okay with you? Sure, no objections.
https://pagure.io/releng/fedora-scm-requests/issue/5529
botan2-2.4.0-10.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-34628c68a4
botan2-2.4.0-10.fc27 has been pushed to the Fedora 27 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-2018-34628c68a4
botan2-2.4.0-10.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.