Skip to contentSkip to conversation

ndctl: SUSE spec file fixups

PATCH New Dan Williams 1 participant 1 message Mar 31, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ndctl: SUSE spec file fixups

Per recent build.opensuse.org results:

1/ The SLE_12 target still mandates use of %defattr

2/ The SUSE-rpmlint system now enforces license names from
https://license.opensuse.org

3/ The libndctl version suffix needs to account for LIBNDCTL_AGE, not
just LIBNDCTL_CURRENT.

---
 Makefile.am   |    6 ++++--
 ndctl.spec.in |    3 +++
 2 files changed, 7 insertions(+), 2 deletions(-)
Makefile.am +4 -2
index 3f7dca3d37e8..7de3d3c3c9eb 100644
@@ -56,12 +56,14 @@ CLEANFILES += $(noinst_SCRIPTS)
 
 do_rhel_subst = sed -e 's,VERSION,$(VERSION),g' \
             -e 's,DNAME,ndctl-devel,g' \
-            -e 's,LNAME,ndctl-libs,g'
+            -e '/^%defattr.*/d' \
+	    -e 's,LNAME,ndctl-libs,g'
 
 do_sles_subst = sed -e 's,VERSION,$(VERSION),g' \
             -e 's,DNAME,libndctl-devel,g' \
             -e 's,%license,%doc,g' \
-            -e 's,LNAME,libndctl$(LIBNDCTL_CURRENT),g'
+            -e 's,\(^License:.*GPL\)v2,\1-2.0,g' \
+            -e "s,LNAME,libndctl$$(($(LIBNDCTL_CURRENT) - $(LIBNDCTL_AGE))),g"
 
 rhel/ndctl.spec: ndctl.spec.in Makefile.am
 	$(AM_V_GEN)$(MKDIR_P) rhel; $(do_rhel_subst) < $< > $@
ndctl.spec.in +3 -0
index 6f6e99bd743b..e24b31cc54f0 100644
@@ -65,16 +65,19 @@ make check
 %postun -n LNAME -p /sbin/ldconfig
 
 %files
+%defattr(-,root,root)
 %license licenses/GPLv2 licenses/BSD-MIT licenses/CC0
 %{_bindir}/ndctl
 %{_mandir}/man1/*
 
 %files -n LNAME
+%defattr(-,root,root)
 %doc README.md
 %license COPYING licenses/BSD-MIT licenses/CC0
 %{_libdir}/libndctl.so.*
 
 %files -n DNAME
+%defattr(-,root,root)
 %license COPYING
 %{_includedir}/ndctl/
 %{_libdir}/libndctl.so

_______________________________________________
Linux-nvdimm mailing list
[email protected]
https://lists.01.org/mailman/listinfo/linux-nvdimm