spec: rpmlint fixes in preparation for Fedora packaging
Subsystems (2)
cover spec: rpmlint fixes in preparation for Fedora packaging
This series addresses the remaining rpm issues that I'm aware of.
Jens: Once the patches are merged and you publish a 0.1 release tag I could roll the first liburing rpm for Fedora. liburing itself is in good shape for wider consumption but maybe it makes sense to wait for kernel issues to settle. There are qemu-iotests failures that are probably kernel bugs (hopefully known ones!) and will be investigated soon.
Stefan Hajnoczi (4):
COPYING: update to latest LGPL v2.1 text
spec: use Fedora "LGPLv2+" license identifier
spec: add URL tag
spec: fix <liburing/*.h> permissions
COPYING | 79 +++++++++++++++++++++------------------------------ liburing.spec | 5 ++-- 2 files changed, 36 insertions(+), 48 deletions(-)
Signature · 1 line
2.21.0
PATCH 1/4 COPYING: update to latest LGPL v2.1 text
rpmlint spotted that the LGPL v2.1 license file is outdated so I've replaced it with the latest one from
https://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt.
The Free Software Foundation address is outdated in COPYING and the file still mentions LGPL v2 where the latest text mentions v2.1:
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
+ version 2.1 of the License, or (at your option) any later version.
---
I'm not sure if the v2 vs v2.1 issue matters to the copyright holders of liburing. The reason I am posting this patch is to make rpmlint happy but we could leave the file unchanged if you prefer.
--- COPYING | 79 ++++++++++++++++++++++++--------------------------------- 1 file changed, 33 insertions(+), 46 deletions(-)
COPYING +33 -46
@@ -1,9 +1,8 @@ - GNU LESSER GENERAL PUBLIC LICENSE Version 2.1, February 1999 Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
@@ -23,8 +22,7 @@ specially designated software packages--typically libraries--of the Free Software Foundation and other authors who decide to use it. You can use it too, but we suggest you first think carefully about whether this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations -below. +strategy to use in any particular case, based on the explanations below. When we speak of free software, we are referring to freedom of use, not price. Our General Public Licenses are designed to make sure that
@@ -57,7 +55,7 @@ modified by someone else and passed on, the recipients should know that what they have is not the original version, so that the original author's reputation will not be affected by problems that might be introduced by others. -^L + Finally, software patents pose a constant threat to the existence of any free program. We wish to make sure that a company cannot effectively restrict the users of a free program by obtaining a
@@ -89,8 +87,7 @@ libraries. However, the Lesser license provides advantages in certain special circumstances. For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it -becomes +encourage the widest possible use of a certain library, so that it becomes a de-facto standard. To achieve this, non-free programs must be allowed to use the library. A more frequent case is that a free library does the same job as widely used non-free libraries. In this
@@ -114,7 +111,7 @@ modification follow. Pay close attention to the difference between a "work based on the library" and a "work that uses the library". The former contains code derived from the library, whereas the latter must be combined with the library in order to run. -^L + GNU LESSER GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
@@ -139,8 +136,7 @@ included without limitation in the term "modification".) "Source code" for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control -compilation +interface definition files, plus the scripts used to control compilation and installation of the library. Activities other than copying, distribution and modification are not
@@ -162,7 +158,7 @@ Library. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. - + 2. You may modify your copy or copies of the Library or any portion of it, thus forming a work based on the Library, and copy and distribute such modifications or work under the terms of Section 1
@@ -220,7 +216,7 @@ instead of to this License. (If a newer version than version 2 of the ordinary GNU General Public License has appeared, then you can specify that version instead if you wish.) Do not make any other change in these notices. -^L + Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy.
@@ -271,7 +267,7 @@ Library will still fall under Section 6.) distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself. -^L + 6. As an exception to the Sections above, you may also combine or link a "work that uses the Library" with the Library to produce a work containing portions of the Library, and distribute that work
@@ -333,7 +329,7 @@ restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute. -^L + 7. You may place library facilities that are a work based on the Library side-by-side in a single library together with other library facilities not covered by this License, and distribute such a combined
@@ -374,7 +370,7 @@ subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties with this License. -^L + 11. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or
@@ -388,10 +384,9 @@ all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Library. -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply, and the section as a whole is intended to apply in other -circumstances. +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any
@@ -409,11 +404,11 @@ be a consequence of the rest of this License. 12. If the distribution and/or use of the Library is restricted in certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License -may add an explicit geographical distribution limitation excluding those -countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. 13. The Free Software Foundation may publish revised and/or new versions of the Lesser General Public License from time to time.
@@ -427,7 +422,7 @@ conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation. -^L + 14. If you wish to incorporate parts of the Library into other free programs whose distribution conditions are incompatible with these, write to the author to ask for permission. For software which is
@@ -461,30 +456,27 @@ SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS -^L + How to Apply These Terms to Your New Libraries If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms -of the ordinary General Public License). +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). - To apply these terms, attach the following notices to the library. -It is safest to attach them to the start of each source file to most -effectively convey the exclusion of warranty; and each file should -have at least the "copyright" line and a pointer to where the full -notice is found. + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. - - <one line to give the library's name and a brief idea of what it -does.> + <one line to give the library's name and a brief idea of what it does.> Copyright (C) <year> <name of author> This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. + version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -493,23 +485,18 @@ does.> You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Also add information on how to contact you by electronic and paper -mail. +Also add information on how to contact you by electronic and paper mail. -You should also get your employer (if you work as a programmer) or -your +You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the library, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James -Random Hacker. + library `Frob' (a library for tweaking knobs) written by James Random Hacker. <signature of Ty Coon>, 1 April 1990 Ty Coon, President of Vice That's all there is to it! - -
Signature · 1 line
2.21.0
PATCH 2/4 spec: use Fedora "LGPLv2+" license identifier
In reply to Stefan Hajnoczirpmlint complains that "LGPL" is not a valid License tag. The License tag for "GNU Lesser General Public License v2 (or 2.1) or later" is "LGPLv2+" according to:
https://fedoraproject.org/wiki/Licensing:Main
--- liburing.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
liburing.spec +1 -1
@@ -2,7 +2,7 @@ Name: liburing Version: 0.1 Release: 1 Summary: Linux-native io_uring I/O access library -License: LGPL +License: LGPLv2+ Group: System Environment/Libraries Source: %{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-root
Signature · 1 line
2.21.0
PATCH 3/4 spec: add URL tag
In reply to Stefan Hajnoczirpmlint complains that there is no URL tag pointing to the software's website/documentation. Since liburing does not have a landing page, point to the cgit page where all information can be found.
--- liburing.spec | 1 + 1 file changed, 1 insertion(+)
liburing.spec +1 -0
@@ -6,6 +6,7 @@ License: LGPLv2+ Group: System Environment/Libraries Source: %{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-root +URL: http://git.kernel.dk/cgit/liburing/ %description Provides native async IO for the Linux kernel, in a fast and efficient
Signature · 1 line
2.21.0
PATCH 4/4 spec: fix <liburing/*.h> permissions
In reply to Stefan HajnocziThere are two issues with the <liburing/*.h> headers:
1. They are installed with 0755 permissions.
2. The empty /usr/include/liburing/ directory is left behind by rpm -e.
Fix this by specifying the directory (not just globbing the files inside it) and letting rpm use the default permissions on these files.
--- liburing.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
liburing.spec +1 -1
@@ -48,7 +48,7 @@ make install DESTDIR=$RPM_BUILD_ROOT %files devel %defattr(-,root,root) -%attr(0755,root,root) %{_includedir}/liburing/* +%attr(-,root,root) %{_includedir}/liburing/ %attr(0644,root,root) %{_includedir}/liburing.h %attr(0755,root,root) %{_libdir}/liburing.so %attr(0644,root,root) %{_libdir}/liburing.a
Signature · 1 line
2.21.0
Quoted 7 lines · Stefan Hajnoczi
This series addresses the remaining rpm issues that I'm aware of.
Jens: Once the patches are merged and you publish a 0.1 release tag I could roll the first liburing rpm for Fedora. liburing itself is in good shape for wider consumption but maybe it makes sense to wait for kernel issues to settle. There are qemu-iotests failures that are probably kernel bugs (hopefully known ones!) and will be investigated soon.
Applied all 4, thanks.
Any pointers to the qemu-iotests failures?
Signature · 1 line
Jens Axboe
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Jens Axboe
maintainerQuoted 30 lines · Stefan Hajnoczi
On Mon, Aug 05, 2019 at 05:14:11PM +0100, Stefan Hajnoczi wrote:
Sorry Jens, I had your old email address. Resent.
Quoted 26 lines
Hi Jens,
I've minimized one of the qemu-iotests failures and it looks like a kernel bug.io_uringcompletes a request with EAGAIN on anO_DIRECTfile with Linux 5.3-rc1 on XFS + dm-thin + dm-crypt:$ qemu-img create -f raw t.img 6G $ qemu-io -f raw -n -i io_uring -c "aio_write 0 1M" -c "aio_write 512 1M" t.img $ qemu-io -f raw -n -i io_uring -c "aio_write $((1 * 1024 * 1024)) 1M" -c "aio_write $((1 * 1024 * 1024 + 512)) 1M" t.img Formatting 'tests/qemu-iotests/scratch/t.img', fmt=raw size=6442450944 wrote 1048576/1048576 bytes at offset 0 1 MiB, 1 ops; 00.01 sec (128.598 MiB/sec and 128.5985 ops/sec) wrote 1048576/1048576 bytes at offset 512 1 MiB, 1 ops; 00.00 sec (201.017 MiB/sec and 201.0169 ops/sec) aio_write failed: Resource temporarily unavailable wrote 1048576/1048576 bytes at offset 1049088 1 MiB, 1 ops; 00.00 sec (391.620 MiB/sec and 391.6198 ops/sec)The third write request should not fail with EAGAIN ("Resource temporarily available"). I think device-mapper is returning EAGAIN at some point but I haven't gotten to the bottom of this yet.
Interestingly it only happens when qemu-img create is run before the test to create a new file. Rerun qemu-io on an existing raw image file and it succeeds. This could be because the failing request is XFS a metadata I/O request that only happens when writing the file for the first time.
It's due to how XFS handles (or doesn't handle) REQ_NOWAIT. I've got a patch for this that needs some testing, but I probably won't get to this until Monday, currently out on vacation until Sunday.
Signature · 1 line
Jens Axboe