Whamcloud - gitweb
LU-8934 spec: Use correct provides in lustre-dkms 17/25417/4
authorNathaniel Clark <nathaniel.l.clark@intel.com>
Mon, 13 Feb 2017 14:55:49 +0000 (09:55 -0500)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 9 Mar 2017 06:13:23 +0000 (06:13 +0000)
Provide kmod-lustre instead of lustre-kmod so that the lustre rpm
requires matches up correctly.

This also adds some support for suse which names thier kmod packages
differently.

Test-Parameters: trivial
Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Ifd3484ade6a90d4492852c7b61db629b934d5a03
Reviewed-on: https://review.whamcloud.com/25417
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre-dkms.spec.in

index 9c30502..8b8aa2f 100644 (file)
@@ -7,6 +7,12 @@
     %define module  @PACKAGE@-client
 %endif
 
+%if %{_vendor}=="redhat" || %{_vendor}=="fedora"
+       %global requires_kmod_name kmod-%{module}
+%else  #for Suse
+       %global requires_kmod_name %{module}-kmp
+%endif
+
 %define buildid 1
 
 Name:           %{module}-dkms
@@ -34,7 +40,7 @@ Requires:       %{module}-osd-zfs-mount
 %endif
 Requires:       gcc, make, perl
 Requires:       kernel-devel
-Provides:       %{module}-kmod = %{version}
+Provides:       %{requires_kmod_name} = %{version}
 Provides:       %{module}-modules = %{version}
 %if %{with servers}
 # Only zfs Lustre DKMS Server is supported