The project contains code that is "GPLv2 with exceptions or MIT", code
that is "LGPLv2+ or MIT" and code that is "MIT" licensed. Unify in a
single expression.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
The development package files (--libdevdir=) have been separated from
the library runtime package files (--libdir=). Make sure to set
--libdevdir= so x86_64 Fedora RPMs are built for /usr/lib64 instead of
/usr/lib.
Cc: Stefan Metzmacher <metze@samba.org>
Fixes: 3e63af4f25
("Fix liburing.so symlink source if libdir != libdevdir")
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
rpmlint on Fedora 31 complains about "LGPLv2+ / MIT" because "/" is not
allowed. Use "or" instead.
Fixes: 783831a054
("Include MIT notice in rpm spec and debian package file")
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Cole Robinson made some more suggestions:
* Use %set_build_flags before ./configure to get the default compiler
flags.
* Use '%license COPYING' instead of %doc.
* Do not ship the static library. This is distro policy and Fedora
would ship a separate -static package if static libraries are
desired.
* Source: should be the URL to the sources. URL: should be the URL of
the website or git repo.
* The devel package needs
Requires: %{name}%{?_isa} = %{version}-%{release}
Acked-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Cole Robinson and Fabio Valenti made a number of suggestions for the
.spec file:
https://bugzilla.redhat.com/show_bug.cgi?id=1766157
* Release should be Release: 1%{?dist} so the .fcXX bits get appended
to the version string
* Source: should be a pointer to the upstream URL that hosts the
release. In this case I think it should be
https://github.com/axboe/liburing/archive/...
the ending weirdness is due to github renaming the archive strangely.
You might need to pass '-n %{name}-%{name}-%{version}' to
%setup/%autosetup to tell it what the extracted archive name is
* The %defattr lines should be removed:
https://pagure.io/packaging-committee/issue/77
* The Group: lines should be removed
* All the BuildRoot and RPM_BUILD_ROOT lines should be removed. %clean
should be removed
* The ./configure line should be replaced with just %configure
* The 'make' call should be %make_build
* The 'make install' call should be %make_install
* The %pre and %post sections can be entirely removed, ldconfig is
done automatically:
https://fedoraproject.org/wiki/Changes/Removing_ldconfig_scriptlets
* The devel package 'Requires: liburing' should instead be: Requires:
%{name} = %{version}-%{release}
* The devel package should also have Requires: pkgconfig
* I think all the %attr usage can be entirely removed, unless they are
doing something that the build system isn't doing.
* The Provides: liburing.so.1 shouldn't be necessary, I'm pretty sure
RPM automatically adds annotations like this
* Replace %setup with %autosetup, which will automatically apply any
listed Patch: in the spec if anything is backported in the future.
It's a small maintenace optimization
These changes work on Fedora 31 and openSUSE Leap 15.1. Therefore they
are likely to work on other rpm-based distributions too.
Acked-by: Jeff Moyer <jmoyer@redhat.com>
Tested-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
There 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.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
rpmlint 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.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
It is not possible to install barrier.h and compat.h into the top-level
/usr/include directly since they are likely to conflict with other
software. io_uring.h could be confused with the system's kernel header
file.
Put liburing headers into <liburing/*.h> so there is no chance of
conflicts or confusion.
Existing applications continue to build successfully since the location
of <liburing.h> is unchanged. In-tree examples and tests require
modification because src/liburing.h is moved to src/include/liburing.h.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Commit fd26c1a2f0 ("configure: move directory options to ./configure")
moved --prefix=PREFIX and other directory options to ./configure.
Invoke ./configure with these options instead of passing them to the
makefile.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Yum doesn't like packages taking ownership of
directories provided by other packages.
Signed-off-by: Hrvoje Zeba <zeba.hrvoje@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
pkgconfig file is installed but not referenced in the
rpm's spec file so rpmbuild fails.
Signed-off-by: Hrvoje Zeba <zeba.hrvoje@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>