rpms/libselinux/devel libselinux-rhat.patch, 1.186, 1.187 libselinux.spec, 1.363, 1.364
Daniel J Walsh
dwalsh at fedoraproject.org
Fri Mar 27 18:25:16 UTC 2009
- Previous message (by thread): rpms/libopensync-plugin-moto/devel .cvsignore, 1.3, 1.4 libopensync-plugin-moto.spec, 1.6, 1.7 sources, 1.3, 1.4
- Next message (by thread): rpms/libopensync-plugin-opie/devel PACKAGE-LICENSING, NONE, 1.1 libopensync-plugin-opie-curl-setopt.patch, NONE, 1.1 .cvsignore, 1.3, 1.4 libopensync-plugin-opie.spec, 1.5, 1.6 sources, 1.3, 1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: dwalsh
Update of /cvs/extras/rpms/libselinux/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv17418
Modified Files:
libselinux-rhat.patch libselinux.spec
Log Message:
* Thu Mar 12 2009 Dan Walsh <dwalsh at redhat.com> - 2.0.79-2
- Add back in av_decision to python swig
libselinux-rhat.patch:
View full diff with command:
/usr/bin/cvs -f diff -kk -u -N -r 1.186 -r 1.187 libselinux-rhat.patch
Index: libselinux-rhat.patch
===================================================================
RCS file: /cvs/extras/rpms/libselinux/devel/libselinux-rhat.patch,v
retrieving revision 1.186
retrieving revision 1.187
diff -u -r1.186 -r1.187
--- libselinux-rhat.patch 12 Mar 2009 12:57:57 -0000 1.186
+++ libselinux-rhat.patch 27 Mar 2009 18:25:15 -0000 1.187
@@ -1,6 +1,6 @@
-diff --exclude-from=exclude -N -u -r nsalibselinux/include/selinux/selinux.h libselinux-2.0.78/include/selinux/selinux.h
+diff --exclude-from=exclude -N -u -r nsalibselinux/include/selinux/selinux.h libselinux-2.0.79/include/selinux/selinux.h
--- nsalibselinux/include/selinux/selinux.h 2009-03-06 14:41:44.000000000 -0500
-+++ libselinux-2.0.78/include/selinux/selinux.h 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/include/selinux/selinux.h 2009-03-27 11:38:27.000000000 -0400
@@ -457,8 +457,11 @@
extern const char *selinux_file_context_path(void);
extern const char *selinux_file_context_homedir_path(void);
@@ -28,9 +28,9 @@
/* Compare two file contexts, return 0 if equivalent. */
int selinux_file_context_cmp(const security_context_t a,
const security_context_t b);
-diff --exclude-from=exclude -N -u -r nsalibselinux/man/man8/selinuxconlist.8 libselinux-2.0.78/man/man8/selinuxconlist.8
+diff --exclude-from=exclude -N -u -r nsalibselinux/man/man8/selinuxconlist.8 libselinux-2.0.79/man/man8/selinuxconlist.8
--- nsalibselinux/man/man8/selinuxconlist.8 1969-12-31 19:00:00.000000000 -0500
-+++ libselinux-2.0.78/man/man8/selinuxconlist.8 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/man/man8/selinuxconlist.8 2009-03-27 10:09:31.000000000 -0400
@@ -0,0 +1,18 @@
+.TH "selinuxconlist" "1" "7 May 2008" "dwalsh at redhat.com" "SELinux Command Line documentation"
+.SH "NAME"
@@ -50,9 +50,9 @@
+
+.SH "SEE ALSO"
+secon(8), selinuxdefcon(8)
-diff --exclude-from=exclude -N -u -r nsalibselinux/man/man8/selinuxdefcon.8 libselinux-2.0.78/man/man8/selinuxdefcon.8
+diff --exclude-from=exclude -N -u -r nsalibselinux/man/man8/selinuxdefcon.8 libselinux-2.0.79/man/man8/selinuxdefcon.8
--- nsalibselinux/man/man8/selinuxdefcon.8 1969-12-31 19:00:00.000000000 -0500
-+++ libselinux-2.0.78/man/man8/selinuxdefcon.8 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/man/man8/selinuxdefcon.8 2009-03-27 10:09:31.000000000 -0400
@@ -0,0 +1,19 @@
+.TH "selinuxdefcon" "1" "7 May 2008" "dwalsh at redhat.com" "SELinux Command Line documentation"
+.SH "NAME"
@@ -73,9 +73,9 @@
+
+.SH "SEE ALSO"
+secon(8), selinuxconlist(8)
-diff --exclude-from=exclude -N -u -r nsalibselinux/src/callbacks.c libselinux-2.0.78/src/callbacks.c
+diff --exclude-from=exclude -N -u -r nsalibselinux/src/callbacks.c libselinux-2.0.79/src/callbacks.c
--- nsalibselinux/src/callbacks.c 2009-03-06 14:41:45.000000000 -0500
-+++ libselinux-2.0.78/src/callbacks.c 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/src/callbacks.c 2009-03-27 10:09:31.000000000 -0400
@@ -16,6 +16,7 @@
{
int rc;
@@ -84,6921 +84,6648 @@
va_start(ap, fmt);
rc = vfprintf(stderr, fmt, ap);
va_end(ap);
-diff --exclude-from=exclude -N -u -r nsalibselinux/src/file_path_suffixes.h libselinux-2.0.78/src/file_path_suffixes.h
---- nsalibselinux/src/file_path_suffixes.h 2009-03-06 14:41:45.000000000 -0500
-+++ libselinux-2.0.78/src/file_path_suffixes.h 2009-03-10 16:23:01.000000000 -0400
-@@ -20,3 +20,6 @@
- S_(FILE_CONTEXTS_LOCAL, "/contexts/files/file_contexts.local")
- S_(X_CONTEXTS, "/contexts/x_contexts")
- S_(COLORS, "/secolor.conf")
-+ S_(VIRTUAL_DOMAIN, "/contexts/virtual_domain_context")
-+ S_(VIRTUAL_IMAGE, "/contexts/virtual_image_context")
-+ S_(FILE_CONTEXT_SUBS, "/contexts/files/file_contexts.subs")
-diff --exclude-from=exclude -N -u -r nsalibselinux/src/label.c libselinux-2.0.78/src/label.c
---- nsalibselinux/src/label.c 2009-03-06 14:41:45.000000000 -0500
-+++ libselinux-2.0.78/src/label.c 2009-03-10 16:23:01.000000000 -0400
-@@ -5,10 +5,12 @@
- */
-
- #include <sys/types.h>
-+#include <ctype.h>
- #include <errno.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
-+#include <selinux/selinux.h>
- #include "callbacks.h"
- #include "label_internal.h"
-
-@@ -23,6 +25,96 @@
- &selabel_x_init
- };
-
-+typedef struct selabel_sub {
-+ char *src;
-+ int slen;
-+ char *dst;
-+ struct selabel_sub *next;
-+} SELABELSUB;
+diff --exclude-from=exclude -N -u -r nsalibselinux/src/d libselinux-2.0.79/src/d
+--- nsalibselinux/src/d 1969-12-31 19:00:00.000000000 -0500
++++ libselinux-2.0.79/src/d 2009-03-27 11:32:04.000000000 -0400
+@@ -0,0 +1,801 @@
+
-+SELABELSUB *selabelsublist = NULL;
-+
-+static void selabel_subs_fini(void)
-+{
-+ SELABELSUB *ptr = selabelsublist;
-+ SELABELSUB *next = NULL;
-+ while (ptr) {
-+ next = ptr->next;
-+ free(ptr->src);
-+ free(ptr->dst);
-+ free(ptr);
-+ ptr = next;
-+ }
-+ selabelsublist = NULL;
++%exception is_selinux_enabled {
++
++ if (result < 0) {
++ PyErr_SetFromErrno(PyExc_OSError);
++ return NULL;
++ }
+}
+
-+static char *selabel_sub(const char *src)
-+{
-+ char *dst = NULL;
-+ SELABELSUB *ptr = selabelsublist;
-+ while (ptr) {
-+ if (strncmp(src, ptr->src, ptr->slen) == 0 ) {
-+ if (src[ptr->slen] == '/' ||
-+ src[ptr->slen] == 0) {
-+ asprintf(&dst, "%s%s", ptr->dst, &src[ptr->slen]);
-+ return dst;
-+ }
-+ }
-+ ptr = ptr->next;
-+ }
-+ return NULL;
++
++%exception is_selinux_mls_enabled {
++
++ if (result < 0) {
++ PyErr_SetFromErrno(PyExc_OSError);
++ return NULL;
++ }
+}
+
-+static int selabel_subs_init(void)
-+{
-+ char buf[1024];
-+ FILE *cfg = fopen(selinux_file_context_subs_path(), "r");
-+ if (cfg) {
-+ while (fgets_unlocked(buf, sizeof(buf) - 1, cfg)) {
-+ char *ptr = NULL;
-+ char *src = buf;
-+ char *dst = NULL;
+
-+ while (*src && isspace(*src))
-+ src++;
-+ if (src[0] == '#') continue;
-+ ptr = src;
-+ while (*ptr && ! isspace(*ptr))
-+ ptr++;
-+ *ptr++ = 0;
-+ if (! *src) continue;
++%exception getcon {
++
++ if (result < 0) {
++ PyErr_SetFromErrno(PyExc_OSError);
++ return NULL;
++ }
++}
+
-+ dst = ptr;
-+ while (*dst && isspace(*dst))
-+ dst++;
-+ ptr=dst;
-+ while (*ptr && ! isspace(*ptr))
-+ ptr++;
-+ *ptr=0;
-+ if (! *dst) continue;
+
-+ SELABELSUB *sub = (SELABELSUB*) malloc(sizeof(SELABELSUB));
-+ if (! sub) return -1;
-+ sub->src=strdup(src);
-+ if (! sub->src) {
-+ free(sub);
-+ return -1;
-+ }
-+ sub->dst=strdup(dst);
-+ if (! sub->dst) {
-+ free(sub);
-+ free(sub->src);
-+ return -1;
-+ }
-+ sub->slen = strlen(src);
-+ sub->next = selabelsublist;
-+ selabelsublist = sub;
-+ }
-+ fclose(cfg);
-+ }
-+ return 0;
++%exception getcon_raw {
[...15969 lines suppressed...]
static swig_cast_info _swigc__p_security_id[] = { {&_swigt__p_security_id, 0, 0, 0},{0, 0, 0, 0}};
-static swig_cast_info _swigc__p_selinux_callback[] = { {&_swigt__p_selinux_callback, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_selinux_opt[] = { {&_swigt__p_selinux_opt, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_unsigned_int[] = { {&_swigt__p_unsigned_int, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_unsigned_short[] = { {&_swigt__p_unsigned_short, 0, 0, 0},{0, 0, 0, 0}};
-@@ -10486,31 +8513,18 @@
+@@ -10486,23 +9204,12 @@
static swig_cast_info *swig_cast_initial[] = {
_swigc__p_SELboolean,
_swigc__p_av_decision,
@@ -10446,17 +9874,149 @@
_swigc__p_ino_t,
_swigc__p_int,
_swigc__p_p_char,
- _swigc__p_p_p_char,
+@@ -10510,7 +9217,6 @@
_swigc__p_p_security_id,
-- _swigc__p_security_class_mapping,
+ _swigc__p_security_class_mapping,
_swigc__p_security_id,
- _swigc__p_selinux_callback,
_swigc__p_selinux_opt,
_swigc__p_unsigned_int,
_swigc__p_unsigned_short,
-diff --exclude-from=exclude -N -u -r nsalibselinux/src/seusers.c libselinux-2.0.78/src/seusers.c
+@@ -10791,18 +9497,48 @@
+
+ SWIGINTERN PyObject *
+ swig_varlink_repr(swig_varlinkobject *SWIGUNUSEDPARM(v)) {
++#if PY_VERSION_HEX >= 0x03000000
++ return PyUnicode_InternFromString("<Swig global variables>");
++#else
+ return PyString_FromString("<Swig global variables>");
++#endif
+ }
+
+ SWIGINTERN PyObject *
+ swig_varlink_str(swig_varlinkobject *v) {
++#if PY_VERSION_HEX >= 0x03000000
++ PyObject *str = PyUnicode_InternFromString("(");
++ PyObject *tail;
++ PyObject *joined;
++ swig_globalvar *var;
++ for (var = v->vars; var; var=var->next) {
++ tail = PyUnicode_FromString(var->name);
++ joined = PyUnicode_Concat(str, tail);
++ Py_DecRef(str);
++ Py_DecRef(tail);
++ str = joined;
++ if (var->next) {
++ tail = PyUnicode_InternFromString(", ");
++ joined = PyUnicode_Concat(str, tail);
++ Py_DecRef(str);
++ Py_DecRef(tail);
++ str = joined;
++ }
++ }
++ tail = PyUnicode_InternFromString(")");
++ joined = PyUnicode_Concat(str, tail);
++ Py_DecRef(str);
++ Py_DecRef(tail);
++ str = joined;
++#else
+ PyObject *str = PyString_FromString("(");
+- swig_globalvar *var;
++ swig_globalvar *var;
+ for (var = v->vars; var; var=var->next) {
+ PyString_ConcatAndDel(&str,PyString_FromString(var->name));
+ if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", "));
+ }
+ PyString_ConcatAndDel(&str,PyString_FromString(")"));
++#endif
+ return str;
+ }
+
+@@ -10810,7 +9546,7 @@
+ swig_varlink_print(swig_varlinkobject *v, FILE *fp, int SWIGUNUSEDPARM(flags)) {
+ PyObject *str = swig_varlink_str(v);
+ fprintf(fp,"Swig global variables ");
+- fprintf(fp,"%s\n", PyString_AsString(str));
++ fprintf(fp,"%s\n", SWIG_Python_str_AsChar(str));
+ Py_DECREF(str);
+ return 0;
+ }
+@@ -10868,8 +9604,13 @@
+ if (!type_init) {
+ const PyTypeObject tmp
+ = {
++ /* PyObject header changed in Python 3 */
++#if PY_VERSION_HEX >= 0x03000000
++ PyVarObject_HEAD_INIT(&PyType_Type, 0)
++#else
+ PyObject_HEAD_INIT(NULL)
+ 0, /* Number of items in variable part (ob_size) */
++#endif
+ (char *)"swigvarlink", /* Type name (tp_name) */
+ sizeof(swig_varlinkobject), /* Basic size (tp_basicsize) */
+ 0, /* Itemsize (tp_itemsize) */
+@@ -10905,7 +9646,10 @@
+ #endif
+ };
+ varlink_type = tmp;
++ /* for Python 3 we already assigned the ob_type in PyVarObject_HEAD_INIT() */
++#if PY_VERSION_HEX < 0x03000000
+ varlink_type.ob_type = &PyType_Type;
++#endif
+ type_init = 1;
+ }
+ return &varlink_type;
+@@ -11030,13 +9774,35 @@
+ #ifdef __cplusplus
+ extern "C"
+ #endif
+-SWIGEXPORT void SWIG_init(void) {
++
++SWIGEXPORT
++#if PY_VERSION_HEX >= 0x03000000
++PyObject*
++#else
++void
++#endif
++SWIG_init(void) {
+ PyObject *m, *d;
+
+ /* Fix SwigMethods to carry the callback ptrs when needed */
+ SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_type_initial);
++#if PY_VERSION_HEX >= 0x03000000
++ static struct PyModuleDef SWIG_module = {
++ PyModuleDef_HEAD_INIT,
++ (char *) SWIG_name,
++ NULL,
++ -1,
++ SwigMethods,
++ NULL,
++ NULL,
++ NULL,
++ NULL
++ };
+
++ m = PyModule_Create(&SWIG_module);
++#else
+ m = Py_InitModule((char *) SWIG_name, SwigMethods);
++#endif
+ d = PyModule_GetDict(m);
+
+ SWIG_InitializeModule(0);
+@@ -11065,5 +9831,10 @@
+ SWIG_Python_SetConstant(d, "AVC_CALLBACK_AUDITDENY_DISABLE",SWIG_From_int((int)(128)));
+ SWIG_Python_SetConstant(d, "AVC_CACHE_STATS",SWIG_From_int((int)(1)));
+ SWIG_Python_SetConstant(d, "SELINUX_DEFAULTUSER",SWIG_FromCharPtr("user_u"));
++#if PY_VERSION_HEX >= 0x03000000
++ return m;
++#else
++ return;
++#endif
+ }
+
+diff --exclude-from=exclude -N -u -r nsalibselinux/src/seusers.c libselinux-2.0.79/src/seusers.c
--- nsalibselinux/src/seusers.c 2009-03-06 14:41:45.000000000 -0500
-+++ libselinux-2.0.78/src/seusers.c 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/src/seusers.c 2009-03-27 10:09:31.000000000 -0400
@@ -243,3 +243,67 @@
*r_level = NULL;
return 0;
@@ -10525,9 +10085,9 @@
+
+ return (ret ? getseuserbyname(username, r_seuser, r_level) : ret);
+}
-diff --exclude-from=exclude -N -u -r nsalibselinux/utils/getdefaultcon.c libselinux-2.0.78/utils/getdefaultcon.c
+diff --exclude-from=exclude -N -u -r nsalibselinux/utils/getdefaultcon.c libselinux-2.0.79/utils/getdefaultcon.c
--- nsalibselinux/utils/getdefaultcon.c 2009-03-06 14:41:45.000000000 -0500
-+++ libselinux-2.0.78/utils/getdefaultcon.c 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/utils/getdefaultcon.c 2009-03-27 10:09:31.000000000 -0400
@@ -22,8 +22,9 @@
security_context_t usercon = NULL, cur_context = NULL;
char *user = NULL, *level = NULL, *role=NULL, *seuser=NULL, *dlevel=NULL;
@@ -10573,9 +10133,9 @@
- return 0;
+ return ret >= 0;
}
-diff --exclude-from=exclude -N -u -r nsalibselinux/utils/Makefile libselinux-2.0.78/utils/Makefile
+diff --exclude-from=exclude -N -u -r nsalibselinux/utils/Makefile libselinux-2.0.79/utils/Makefile
--- nsalibselinux/utils/Makefile 2009-03-06 14:41:45.000000000 -0500
-+++ libselinux-2.0.78/utils/Makefile 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/utils/Makefile 2009-03-27 10:09:31.000000000 -0400
@@ -2,28 +2,33 @@
PREFIX ?= $(DESTDIR)/usr
LIBDIR ?= $(PREFIX)/lib
@@ -10614,9 +10174,9 @@
indent:
../../scripts/Lindent $(wildcard *.[ch])
-diff --exclude-from=exclude -N -u -r nsalibselinux/utils/matchpathcon.c libselinux-2.0.78/utils/matchpathcon.c
+diff --exclude-from=exclude -N -u -r nsalibselinux/utils/matchpathcon.c libselinux-2.0.79/utils/matchpathcon.c
--- nsalibselinux/utils/matchpathcon.c 2009-03-06 14:41:45.000000000 -0500
-+++ libselinux-2.0.78/utils/matchpathcon.c 2009-03-10 16:23:01.000000000 -0400
++++ libselinux-2.0.79/utils/matchpathcon.c 2009-03-27 10:09:31.000000000 -0400
@@ -22,9 +22,13 @@
char *buf;
int rc = matchpathcon(path, mode, &buf);
Index: libselinux.spec
===================================================================
RCS file: /cvs/extras/rpms/libselinux/devel/libselinux.spec,v
retrieving revision 1.363
retrieving revision 1.364
diff -u -r1.363 -r1.364
--- libselinux.spec 12 Mar 2009 12:57:57 -0000 1.363
+++ libselinux.spec 27 Mar 2009 18:25:16 -0000 1.364
@@ -5,7 +5,7 @@
Summary: SELinux library and simple utilities
Name: libselinux
Version: 2.0.79
-Release: 1%{?dist}
+Release: 2%{?dist}
License: Public Domain
Group: System Environment/Libraries
Source: http://www.nsa.gov/research/selinux/%{name}-%{version}.tgz
@@ -164,6 +164,9 @@
%{ruby_sitearch}/selinux.so
%changelog
+* Thu Mar 12 2009 Dan Walsh <dwalsh at redhat.com> - 2.0.79-2
+- Add back in av_decision to python swig
+
* Thu Mar 12 2009 Dan Walsh <dwalsh at redhat.com> - 2.0.79-1
- Update to upstream
* Netlink socket handoff patch from Adam Jackson.
- Previous message (by thread): rpms/libopensync-plugin-moto/devel .cvsignore, 1.3, 1.4 libopensync-plugin-moto.spec, 1.6, 1.7 sources, 1.3, 1.4
- Next message (by thread): rpms/libopensync-plugin-opie/devel PACKAGE-LICENSING, NONE, 1.1 libopensync-plugin-opie-curl-setopt.patch, NONE, 1.1 .cvsignore, 1.3, 1.4 libopensync-plugin-opie.spec, 1.5, 1.6 sources, 1.3, 1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list