RPM Package Manager, CVS Repository
http://rpm5.org/cvs/
____________________________________________________________________________
Server: rpm5.org Name: Jeff Johnson
Root: /v/rpm/cvs Email: [EMAIL PROTECTED]
Module: rpm Date: 02-Aug-2007 14:45:44
Branch: HEAD Handle: 2007080213454300
Modified files:
rpm CHANGES
rpm/python rpmds-py.c
Log:
- python ds.Uname getter for uname(...) dependencies.
Summary:
Revision Changes Path
1.1541 +1 -0 rpm/CHANGES
1.35 +15 -0 rpm/python/rpmds-py.c
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: rpm/CHANGES
============================================================================
$ cvs diff -u -r1.1540 -r1.1541 CHANGES
--- rpm/CHANGES 1 Aug 2007 19:35:04 -0000 1.1540
+++ rpm/CHANGES 2 Aug 2007 12:45:43 -0000 1.1541
@@ -1,4 +1,5 @@
4.5 -> 5.0:
+ - jbj: python ds.Uname getter for uname(...) dependencies.
- jbj: use rpmmg magic wrapper.
- jbj: add rpmmg magic wrapper.
- jbj: unsnarl __FUNCTION__ from system.h AutoFu.
@@ .
patch -p0 <<'@@ .'
Index: rpm/python/rpmds-py.c
============================================================================
$ cvs diff -u -r1.34 -r1.35 rpmds-py.c
--- rpm/python/rpmds-py.c 1 Aug 2007 17:58:36 -0000 1.34
+++ rpm/python/rpmds-py.c 2 Aug 2007 12:45:43 -0000 1.35
@@ -468,6 +468,19 @@
return (PyObject *) rpmds_Wrap( P );
}
+static PyObject *
+rpmds_Uname(rpmdsObject * s)
+ /[EMAIL PROTECTED]/
+{
+ rpmds ds = NULL;
+ int xx;
+
+ /* XXX check return code, permit arg (NULL uses system default). */
+ xx = rpmdsUname(&ds, NULL);
+
+ return (PyObject *) rpmds_Wrap( ds );
+}
+
#ifdef NOTYET
static PyObject *
rpmds_Compare(rpmdsObject * s, PyObject * args, PyObject * kwds)
@@ -557,6 +570,8 @@
"ds.Getconf -> nds - Return getconf(1) dependency set.\n"},
{"Ldconfig", (PyCFunction)rpmds_Ldconfig, METH_NOARGS|METH_STATIC,
"ds.Ldconfig -> nds - Return /etc/ld.so.cache dependency set.\n"},
+ {"Uname", (PyCFunction)rpmds_Uname, METH_NOARGS|METH_STATIC,
+ "ds.Uname -> nds - Return uname(2) dependency set.\n"},
#ifdef NOTYET
{"Compare", (PyCFunction)rpmds_Compare, METH_VARARGS|METH_KEYWORDS,
NULL},
@@ .
______________________________________________________________________
RPM Package Manager http://rpm5.org
CVS Sources Repository [email protected]