rpms/smartmontools/devel smartmontools-5.38-lowcap.patch, 1.1, 1.2 smartmontools.spec, 1.57, 1.58

Michal Hlavinka mhlavink at fedoraproject.org
Wed Aug 26 15:41:27 UTC 2009


Author: mhlavink

Update of /cvs/extras/rpms/smartmontools/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv10550

Modified Files:
	smartmontools-5.38-lowcap.patch smartmontools.spec 
Log Message:
updated patch for lower capabilities


smartmontools-5.38-lowcap.patch:
 Makefile.am  |    2 +-
 configure.in |   34 ++++++++++++++++++++++++++++++++++
 smartd.cpp   |   12 ++++++++++++
 3 files changed, 47 insertions(+), 1 deletion(-)

Index: smartmontools-5.38-lowcap.patch
===================================================================
RCS file: /cvs/extras/rpms/smartmontools/devel/smartmontools-5.38-lowcap.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- smartmontools-5.38-lowcap.patch	21 Aug 2009 11:02:44 -0000	1.1
+++ smartmontools-5.38-lowcap.patch	26 Aug 2009 15:41:26 -0000	1.2
@@ -1,18 +1,50 @@
 diff -urp smartmontools-5.38.orig/configure.in smartmontools-5.38/configure.in
 --- smartmontools-5.38.orig/configure.in	2009-08-16 07:42:57.000000000 -0400
-+++ smartmontools-5.38/configure.in	2009-08-16 08:07:53.000000000 -0400
-@@ -143,6 +143,8 @@ if test "$with_selinux" = "yes"; then
++++ smartmontools-5.38/configure.in	2009-08-21 12:07:15.000000000 -0400
+@@ -143,6 +143,40 @@ if test "$with_selinux" = "yes"; then
  	AC_DEFINE(WITH_SELINUX, [1], [Define to 1 if SELinux support is enabled])
  fi
  
-+LIBCAP_NG_PATH
++  AC_ARG_WITH(libcap-ng,
++    [  --with-libcap-ng=[auto/yes/no]  Add Libcap-ng support [default=auto]],,
++    with_libcap_ng=auto)
++
++# Check for Libcap-ng API
++#
++# libcap-ng detection
++
++if test x$with_libcap_ng = xno ; then
++    have_libcap_ng=no;
++else
++    # Start by checking for header file
++    AC_CHECK_HEADER(cap-ng.h, capng_headers=yes, capng_headers=no)
++
++    # See if we have libcap-ng library
++    AC_CHECK_LIB(cap-ng, capng_clear, CAPNG_LDADD=-lcap-ng,)
++
++    # Check results are usable
++    if test x$with_libcap_ng = xyes -a x$CAPNG_LDADD = x ; then
++       AC_MSG_ERROR(libcap-ng support was requested and the library was not found)
++    fi
++    if test x$CAPNG_LDADD != x -a $capng_headers = no ; then
++       AC_MSG_ERROR(libcap-ng libraries found but headers are missing)
++    fi
++fi
++AC_SUBST(CAPNG_LDADD)
++AC_MSG_CHECKING(whether to use libcap-ng)
++if test x$CAPNG_LDADD != x ; then
++    AC_DEFINE(HAVE_LIBCAP_NG,1,[libcap-ng support])
++    AC_MSG_RESULT(yes)
++else
++    AC_MSG_RESULT(no)
++fi
 +
  if test "$prefix" = "NONE"; then
      dnl no prefix and no mandir, so use ${prefix}/share/man as default
      if test "$mandir" = '${prefix}/man'; then
 diff -urp smartmontools-5.38.orig/Makefile.am smartmontools-5.38/Makefile.am
 --- smartmontools-5.38.orig/Makefile.am	2009-08-16 07:42:57.000000000 -0400
-+++ smartmontools-5.38/Makefile.am	2009-08-16 08:07:53.000000000 -0400
++++ smartmontools-5.38/Makefile.am	2009-08-21 11:28:22.000000000 -0400
 @@ -35,7 +35,7 @@ smartd_SOURCES =  smartd.cpp      \
                    utility.cpp     \
                    utility.h
@@ -24,7 +56,7 @@ diff -urp smartmontools-5.38.orig/Makefi
  EXTRA_smartd_SOURCES = os_darwin.cpp    \
 diff -urp smartmontools-5.38.orig/smartd.cpp smartmontools-5.38/smartd.cpp
 --- smartmontools-5.38.orig/smartd.cpp	2009-08-16 07:42:57.000000000 -0400
-+++ smartmontools-5.38/smartd.cpp	2009-08-16 08:08:27.000000000 -0400
++++ smartmontools-5.38/smartd.cpp	2009-08-21 11:28:22.000000000 -0400
 @@ -74,6 +74,10 @@ extern "C" int __stdcall FreeConsole(voi
  #include <io.h> // setmode()
  #endif // __CYGWIN__


Index: smartmontools.spec
===================================================================
RCS file: /cvs/extras/rpms/smartmontools/devel/smartmontools.spec,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -p -r1.57 -r1.58
--- smartmontools.spec	21 Aug 2009 11:02:44 -0000	1.57
+++ smartmontools.spec	26 Aug 2009 15:41:26 -0000	1.58
@@ -1,7 +1,7 @@
 Summary:	Tools for monitoring SMART capable hard disks
 Name:		smartmontools
 Version:	5.38
-Release: 	14%{?dist}
+Release: 	15%{?dist}
 Epoch:		1
 Group:		System Environment/Base
 License:	GPLv2+
@@ -18,7 +18,7 @@ Patch6:     smartmontools-5.38-lowcap.pa
 BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
 Requires:	fileutils mailx chkconfig initscripts
 BuildRequires: readline-devel ncurses-devel /usr/bin/aclocal util-linux groff gettext
-BuildRequires: libselinux-devel
+BuildRequires: libselinux-devel libcap-ng-devel
 
 %description
 The smartmontools package contains two utility programs (smartctl
@@ -38,7 +38,9 @@ failure.
 %patch6 -p1 -b .lowcap
 
 %build
-%configure --with-selinux
+ln -s CHANGELOG ChangeLog
+autoreconf -i
+%configure --with-selinux --with-libcap-ng=yes
 %ifarch sparc64
 make CXXFLAGS="$RPM_OPT_FLAGS -fPIE" LDFLAGS="-pie -Wl,-z,relro,-z,now"
 %else
@@ -77,6 +79,10 @@ fi
 %config(noreplace) %{_sysconfdir}/sysconfig/smartmontools
 
 %changelog
+* Wed Aug 26 2009 Michal Hlavinka <mhlavink at redhat.com> - 1:5.38-15
+- updated patch for lower capabilities (#517728)
+- added buildrequires libcap-ng-devel
+
 * Fri Aug 21 2009 Michal Hlavinka <mhlavink at redhat.com> - 1:5.38-14
 - drop all unnecessary capabilities (#517728)
 




More information about the fedora-extras-commits mailing list