rpms/gpm/devel gpm-1.20.6-capability.patch, NONE, 1.1 gpm.spec, 1.76, 1.77
Zdenek Prikryl
zprikryl at fedoraproject.org
Thu Aug 20 08:39:54 UTC 2009
- Previous message: rpms/perl-IO-Socket-SSL/devel .cvsignore, 1.20, 1.21 perl-IO-Socket-SSL.spec, 1.24, 1.25 sources, 1.20, 1.21
- Next message: rpms/mipv6-daemon/F-11 mip6d.conf, NONE, 1.1 mip6d.init, NONE, 1.1 mip6d.sysconfig, NONE, 1.1 mipv6-daemon-header-fix.patch, NONE, 1.1 mipv6-daemon.spec, NONE, 1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: zprikryl
Update of /cvs/extras/rpms/gpm/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv13395
Modified Files:
gpm.spec
Added Files:
gpm-1.20.6-capability.patch
Log Message:
Don't complain if installing with --excludedocs (#515927)
Drop unnecessary capabilities in gpm (#517659)
gpm-1.20.6-capability.patch:
configure.ac | 3 +++
src/Makefile.in | 3 ++-
src/daemon/main.c | 9 +++++++++
3 files changed, 14 insertions(+), 1 deletion(-)
--- NEW FILE gpm-1.20.6-capability.patch ---
diff -urp gpm-1.20.6.orig/configure.ac gpm-1.20.6/configure.ac
--- gpm-1.20.6.orig/configure.ac 2009-08-15 13:39:33.000000000 -0400
+++ gpm-1.20.6/configure.ac 2009-08-15 13:51:14.000000000 -0400
@@ -129,6 +129,9 @@ No|no|N|n) SHARED_LIBS=-lc ;;
LIBS=$SAVELIBS ;;
esac
+# look for capabilities library
+LIBCAP_NG_PATH
+
GPMXTERM=
AC_SUBST(GPMXTERM)
AC_SUBST(abi_lev)
diff -urp gpm-1.20.6.orig/src/daemon/main.c gpm-1.20.6/src/daemon/main.c
--- gpm-1.20.6.orig/src/daemon/main.c 2009-08-15 13:39:33.000000000 -0400
+++ gpm-1.20.6/src/daemon/main.c 2009-08-15 13:47:39.000000000 -0400
@@ -26,9 +26,18 @@
#include "headers/daemon.h"
#include "headers/gpmInt.h"
+#ifdef HAVE_LIBCAP_NG
+#include <cap-ng.h>
+#endif
int main(int argc, char **argv)
{
+#ifdef HAVE_LIBCAP_NG
+ capng_clear(CAPNG_SELECT_BOTH);
+ capng_updatev(CAPNG_ADD, CAPNG_EFFECTIVE|CAPNG_PERMITTED,
+ CAP_SYS_ADMIN, CAP_SYS_TTY_CONFIG, -1);
+ capng_apply(CAPNG_SELECT_BOTH);
+#endif
startup(argc,argv); /* setup configurations */
old_main(); /* LATER: exit(daemon()); */
return 0; /* if we didn't exit before, just give back success */
diff -urp gpm-1.20.6.orig/src/Makefile.in gpm-1.20.6/src/Makefile.in
--- gpm-1.20.6.orig/src/Makefile.in 2009-08-15 13:39:33.000000000 -0400
+++ gpm-1.20.6/src/Makefile.in 2009-08-15 13:49:45.000000000 -0400
@@ -82,7 +82,8 @@ prog/%: prog/%.o
all: gpm lib/libgpm.so. at abi_lev@ lib/libgpm.a $(PROG)
gpm: $(GOBJ)
- $(CC) @LDFLAGS@ $(LDFLAGS) -o $@ $(GOBJ) @LIBS@ $(LIBS) -lm
+ $(CC) @LDFLAGS@ $(LDFLAGS) -o $@ $(GOBJ) @LIBS@ $(LIBS) \
+ -lm $(CAPNG_LDADD)
# construct dependings of sourcefiles and link sourcefiles
$(DEPFILE) dep: prog/gpm-root.c
Index: gpm.spec
===================================================================
RCS file: /cvs/extras/rpms/gpm/devel/gpm.spec,v
retrieving revision 1.76
retrieving revision 1.77
diff -u -p -r1.76 -r1.77
--- gpm.spec 12 Aug 2009 17:10:26 -0000 1.76
+++ gpm.spec 20 Aug 2009 08:39:53 -0000 1.77
@@ -1,7 +1,7 @@
Summary: A mouse server for the Linux console
Name: gpm
Version: 1.20.6
-Release: 5%{?dist}
+Release: 6%{?dist}
License: GPLv2+
Group: System Environment/Daemons
URL: http://unix.schottelius.org/gpm/
@@ -14,6 +14,7 @@ Patch3: gpm-1.20.3-gcc4.3.patch
Patch4: gpm-1.20.5-close-fds.patch
Patch5: gpm-1.20.1-weak-wgetch.patch
Patch6: gpm-1.20.6-libtool.patch
+Patch7: gpm-1.20.6-capability.patch
Requires(post): /sbin/chkconfig /sbin/install-info /sbin/ldconfig
Requires(preun): /sbin/chkconfig /sbin/install-info
Requires(postun): /sbin/ldconfig
@@ -65,6 +66,7 @@ mouse support to text-based Linux applic
%patch4 -p1 -b .close-fds
%patch5 -p1 -b .weak-wgetch
%patch6 -p1 -b .libtool
+%patch7 -p1 -b .capability
iconv -f iso-8859-1 -t utf-8 -o TODO.utf8 TODO
touch -c -r TODO TODO.utf8
@@ -107,21 +109,25 @@ rm -rf %{buildroot}
%ifnarch s390 s390x
/sbin/chkconfig --add gpm
%endif
-/sbin/install-info %{_infodir}/gpm.info.gz %{_infodir}/dir
+if [ -e %{_infodir}/gpm.info.gz ]; then
+ /sbin/install-info %{_infodir}/gpm.info.gz %{_infodir}/dir || :
+fi
/sbin/ldconfig
%preun
%ifnarch s390 s390x
-if [ "$1" = "0" ]; then
+if [ $1 = 0 ]; then
/sbin/service gpm stop >/dev/null 2>&1
/sbin/chkconfig --del gpm
fi
%endif
-/sbin/install-info %{_infodir}/gpm.info.gz --delete %{_infodir}/dir || :
+if [ $1 = 0 -a -e %{_infodir}/gpm.info.gz ]; then
+ /sbin/install-info %{_infodir}/gpm.info.gz --delete %{_infodir}/dir || :
+fi
%postun
%ifnarch s390 s390x
-if [ "$1" -ge "1" ]; then
+if [ $1 -ge 1 ]; then
/sbin/service gpm condrestart >/dev/null 2>&1
fi
%endif
@@ -154,6 +160,10 @@ fi
%{_libdir}/libgpm.a
%changelog
+* Thu Aug 20 2009 Zdenek Prikryl <zprikryl at redhat.com> 1.20.6-6
+- Don't complain if installing with --excludedocs (#515927)
+- Drop unnecessary capabilities in gpm (#517659)
+
* Wed Aug 12 2009 Ville Skyttä <ville.skytta at iki.fi> - 1.20.6-5
- Use lzma compressed upstream tarball.
- Previous message: rpms/perl-IO-Socket-SSL/devel .cvsignore, 1.20, 1.21 perl-IO-Socket-SSL.spec, 1.24, 1.25 sources, 1.20, 1.21
- Next message: rpms/mipv6-daemon/F-11 mip6d.conf, NONE, 1.1 mip6d.init, NONE, 1.1 mip6d.sysconfig, NONE, 1.1 mipv6-daemon-header-fix.patch, NONE, 1.1 mipv6-daemon.spec, NONE, 1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the scm-commits
mailing list