[CVS] RPM: rpm/ devtool.conf
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Anders F. Björklund Root: /v/rpm/cvs Email: [EMAIL PROTECTED] Module: rpm Date: 03-Nov-2007 11:34:05 Branch: HEAD Handle: 2007110310340500 Modified files: rpm devtool.conf Log: fix cross SDK builds of XAR (and move unfortunate comment) Summary: RevisionChanges Path 2.111 +3 -2 rpm/devtool.conf patch -p0 '@@ .' Index: rpm/devtool.conf $ cvs diff -u -r2.110 -r2.111 devtool.conf --- rpm/devtool.conf 28 Oct 2007 23:41:11 - 2.110 +++ rpm/devtool.conf 3 Nov 2007 10:34:05 - 2.111 @@ -1689,11 +1689,12 @@ # XAR (uninstalled internal library) if [ -d ${DEVTOOL_SRCDIR}/xar ]; then ( mkdir -p xar; cd xar -( CC=$UNIVERSAL_CC \ +( echo === configuring in xar (`pwd`) +CPP=$UNIVERSAL_CC -E -isysroot ${UNIVERSAL_SDK} \ +CC=$UNIVERSAL_CC \ CPPFLAGS=$UNIVERSAL_CPPFLAGS \ CFLAGS=-O2 -g $UNIVERSAL_CFLAGS \ LDFLAGS=$UNIVERSAL_LDFLAGS \ -echo === configuring in xar (`pwd`) ${DEVTOOL_SRCDIR}/xar/configure $UNIVERSAL_TARGET \ --prefix=/usr/local \ --disable-shared @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ devtool.conf
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Anders F. Björklund Root: /v/rpm/cvs Email: [EMAIL PROTECTED] Module: rpm Date: 03-Nov-2007 12:14:14 Branch: HEAD Handle: 2007110311141400 Modified files: rpm devtool.conf Log: move CPP to variable to not break non-SDK build Summary: RevisionChanges Path 2.112 +10 -4 rpm/devtool.conf patch -p0 '@@ .' Index: rpm/devtool.conf $ cvs diff -u -r2.111 -r2.112 devtool.conf --- rpm/devtool.conf 3 Nov 2007 10:34:05 - 2.111 +++ rpm/devtool.conf 3 Nov 2007 11:14:14 - 2.112 @@ -1262,8 +1262,9 @@ %panther MACOSX_DEPLOYMENT_TARGET=10.3 export MACOSX_DEPLOYMENT_TARGET -UNIVERSAL_CC=gcc-3.3; export PATH=$PATH:/usr/libexec/gcc/darwin/ppc/3.3 # horrible Intel workaround UNIVERSAL_SDK=/Developer/SDKs/MacOSX10.3.9.sdk +UNIVERSAL_CPP=gcc-3.3 -E +UNIVERSAL_CC=gcc-3.3; export PATH=$PATH:/usr/libexec/gcc/darwin/ppc/3.3 # horrible Intel workaround UNIVERSAL_CPPFLAGS=-I${UNIVERSAL_SDK}/usr/include UNIVERSAL_CFLAGS=-isystem ${UNIVERSAL_SDK}/usr/include -isystem ${UNIVERSAL_SDK}/usr/include/gcc/darwin/3.3 -arch ppc UNIVERSAL_LDFLAGS=-Wl,-syslibroot,${UNIVERSAL_SDK} -arch ppc @@ -1273,8 +1274,9 @@ %tiger MACOSX_DEPLOYMENT_TARGET=10.4 export MACOSX_DEPLOYMENT_TARGET -UNIVERSAL_CC=gcc-4.0 UNIVERSAL_SDK=/Developer/SDKs/MacOSX10.4u.sdk +UNIVERSAL_CPP=gcc-4.0 -E -isysroot ${UNIVERSAL_SDK} +UNIVERSAL_CC=gcc-4.0 UNIVERSAL_CPPFLAGS= UNIVERSAL_CFLAGS=-isysroot ${UNIVERSAL_SDK} -arch ppc -arch i386 UNIVERSAL_LDFLAGS=-arch ppc -arch i386 @@ -1284,8 +1286,9 @@ %leopard MACOSX_DEPLOYMENT_TARGET=10.5 export MACOSX_DEPLOYMENT_TARGET -UNIVERSAL_CC=gcc-4.0 UNIVERSAL_SDK=/Developer/SDKs/MacOSX10.5.sdk +UNIVERSAL_CPP=gcc-4.0 -E -isysroot ${UNIVERSAL_SDK} +UNIVERSAL_CC=gcc-4.0 UNIVERSAL_CPPFLAGS= UNIVERSAL_CFLAGS=-isysroot ${UNIVERSAL_SDK} -arch ppc -arch i386 UNIVERSAL_LDFLAGS=-arch ppc -arch i386 @@ -1328,6 +1331,7 @@ #determine some local tools SHTOOL=`cd ${DEVTOOL_SRCDIR} pwd`/devtool.shtool +test .$UNIVERSAL_CPP == . UNIVERSAL_CPP=gcc -E test .$UNIVERSAL_CC == . UNIVERSAL_CC=gcc # third-party base directory @@ -1646,6 +1650,7 @@ echo ++ configuring build environment basemac=`cd $basemac pwd` +CPP=$UNIVERSAL_CPP CC=$UNIVERSAL_CC CPPFLAGS=$UNIVERSAL_CPPFLAGS CFLAGS=-O2 -g $UNIVERSAL_CFLAGS @@ -1653,6 +1658,7 @@ LIBS=$LIBS -lssl -lcrypto # shameless workaround for Neon CPPFLAGS=$CPPFLAGS -I/tmp/xar-root/usr/local/include LDFLAGS=$LDFLAGS -L/tmp/xar-root/usr/local/lib +export CPP export CC export CPPFLAGS export CFLAGS @@ -1690,7 +1696,7 @@ if [ -d ${DEVTOOL_SRCDIR}/xar ]; then ( mkdir -p xar; cd xar ( echo === configuring in xar (`pwd`) -CPP=$UNIVERSAL_CC -E -isysroot ${UNIVERSAL_SDK} \ +CPP=$UNIVERSAL_CPP \ CC=$UNIVERSAL_CC \ CPPFLAGS=$UNIVERSAL_CPPFLAGS \ CFLAGS=-O2 -g $UNIVERSAL_CFLAGS \ @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ devtool.conf
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Anders F. Björklund Root: /v/rpm/cvs Email: [EMAIL PROTECTED] Module: rpm Date: 03-Nov-2007 12:22:19 Branch: HEAD Handle: 2007110311221900 Modified files: rpm devtool.conf Log: make python_version hack cope with binary config.log files Summary: RevisionChanges Path 2.114 +1 -1 rpm/devtool.conf patch -p0 '@@ .' Index: rpm/devtool.conf $ cvs diff -u -r2.113 -r2.114 devtool.conf --- rpm/devtool.conf 3 Nov 2007 11:20:36 - 2.113 +++ rpm/devtool.conf 3 Nov 2007 11:22:19 - 2.114 @@ -1751,7 +1751,7 @@ rm /tmp/rpm-root/Library/Perl/*/darwin-thread-multi-2level/auto/RPM/.packlist # move perl/python modules to canonical /Library locations -python_version=`( grep ^WITH_PYTHON_VERSION config.log; echo 'echo $WITH_PYTHON_VERSION' ) | sh` +python_version=`( grep -a ^WITH_PYTHON_VERSION config.log; echo 'echo $WITH_PYTHON_VERSION' ) | sh` mkdir -p /tmp/rpm-root/Library/Python/$python_version mv /tmp/rpm-root/Library/Frameworks/Python.framework/Versions/* \ /tmp/rpm-root/Library/Python/ @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ devtool.conf
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Anders F. Björklund Root: /v/rpm/cvs Email: [EMAIL PROTECTED] Module: rpm Date: 03-Nov-2007 12:29:14 Branch: HEAD Handle: 2007110311291400 Modified files: rpm devtool.conf Log: remove old versions numbers from %macosx comments Summary: RevisionChanges Path 2.115 +4 -4 rpm/devtool.conf patch -p0 '@@ .' Index: rpm/devtool.conf $ cvs diff -u -r2.114 -r2.115 devtool.conf --- rpm/devtool.conf 3 Nov 2007 11:22:19 - 2.114 +++ rpm/devtool.conf 3 Nov 2007 11:29:14 - 2.115 @@ -1297,7 +1297,7 @@ %macosx ## -## Builds a Universal Binary (ppc/i386), on the Mac OS X 10.4 platform. +## Builds a Universal Binary (ppc/i386), on the Mac OS X 10.x platforms. ## (this target is heavilly inspired by the OpenPKG standalone target) ## ## Written by Anders F Bjorklund in memoriam of the rpm4darwin project @@ -1311,7 +1311,7 @@ ## name conflict with the system linker which is also called libtool(1) ## ## Shipped programs/libraries are built as Universal Binaries (i.e. fat) -## with: -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch i386 +## with: -isysroot /Developer/SDKs/MacOSX10.x.sdk -arch ppc -arch i386 ## This also requires --disable-dependency-tracking, since it doesn't ## work with multiple -arch flags (see Apple's Technical Note TN2137) ## @@ -1322,8 +1322,8 @@ ## ## The package is configured to install in /usr/local and /var/local, ## with the RPM configuration files in /etc. RPM libraries are dynamic. -## The Perl module for RPM is included, built in /Library/Perl/5.8.6/ -## The Python module for RPM is included, built in /Library/Python/2.3/ +## The Perl module for RPM is included, built in /Library/Perl/ +## The Python module for RPM is included, built in /Library/Python/ ## @source %standalone-modules @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ devtool.conf
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Anders F. Björklund Root: /v/rpm/cvs Email: [EMAIL PROTECTED] Module: rpm Date: 03-Nov-2007 12:53:03 Branch: HEAD Handle: 2007110311530300 Modified files: rpm devtool.conf Log: don't leak UNIVERSAL_CPP to the rpm macros Summary: RevisionChanges Path 2.116 +1 -0 rpm/devtool.conf patch -p0 '@@ .' Index: rpm/devtool.conf $ cvs diff -u -r2.115 -r2.116 devtool.conf --- rpm/devtool.conf 3 Nov 2007 11:29:14 - 2.115 +++ rpm/devtool.conf 3 Nov 2007 11:53:03 - 2.116 @@ -1771,6 +1771,7 @@ chmod 1775 /tmp/rpm-root/Library # setup default (undetected) configuration, for Mac OS X +sed -i -e s,${UNIVERSAL_CPP},gcc -E, /tmp/rpm-root/usr/local/lib/rpm/macros sed -i -e s,${UNIVERSAL_CC},gcc, /tmp/rpm-root/usr/local/lib/rpm/macros sed -i -e 's,-gnu$,%{nil},' /tmp/rpm-root/usr/local/lib/rpm/macros sed -i -e 's,libtoolize$,glibtoolize,' /tmp/rpm-root/usr/local/lib/rpm/macros @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ CHANGES rpm/lib/ rpmrc.c rpm/rpmdb/ rpmdb.c rpm/rpmio/...
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: 03-Nov-2007 14:19:24 Branch: HEAD Handle: 2007110313192201 Modified files: rpm CHANGES rpm/lib rpmrc.c rpm/rpmdb rpmdb.c rpm/rpmio macro.c rpmmacro.h Log: - jbj: add a getter to retrieve macros with used and/or pattern filtering. - jbj: macro macro table/element internals opaque. Summary: RevisionChanges Path 1.1763 +2 -0 rpm/CHANGES 2.213 +1 -3 rpm/lib/rpmrc.c 1.197 +1 -1 rpm/rpmdb/rpmdb.c 2.148 +62 -1 rpm/rpmio/macro.c 2.41+24 -4 rpm/rpmio/rpmmacro.h patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.1762 -r1.1763 CHANGES --- rpm/CHANGES 2 Nov 2007 03:07:46 - 1.1762 +++ rpm/CHANGES 3 Nov 2007 13:19:22 - 1.1763 @@ -1,4 +1,6 @@ 4.5 - 5.0: +- jbj: add a getter to retrieve macros with used and/or pattern filtering. +- jbj: macro macro table/element internals opaque. - jbj: fix --rebuilddb --root /path. - rse: fix linking of RPM against PCRE's POSIX API under --with-pcre - jbj: upgrade to F8 fix rpm-python. i18n tags w hdr_subscript are b0rked. @@ . patch -p0 '@@ .' Index: rpm/lib/rpmrc.c $ cvs diff -u -r2.212 -r2.213 rpmrc.c --- rpm/lib/rpmrc.c 6 Oct 2007 21:33:48 - 2.212 +++ rpm/lib/rpmrc.c 3 Nov 2007 13:19:23 - 2.213 @@ -8,15 +8,13 @@ #define __power_pc() 0 #endif +#define _MIRE_INTERNAL #include rpmio_internal.h /* for rpmioSlurp() */ #include rpmcli.h #include rpmmacro.h #include rpmlua.h #include rpmds.h -#define _MIRE_INTERNAL -#include mire.h - #include misc.h #include debug.h @@ . patch -p0 '@@ .' Index: rpm/rpmdb/rpmdb.c $ cvs diff -u -r1.196 -r1.197 rpmdb.c --- rpm/rpmdb/rpmdb.c 2 Nov 2007 03:07:46 - 1.196 +++ rpm/rpmdb/rpmdb.c 3 Nov 2007 13:19:23 - 1.197 @@ -11,6 +11,7 @@ #include rpmio.h #include rpmpgp.h #include rpmurl.h +#define _MIRE_INTERNAL #include rpmmacro.h #include rpmsq.h #include rpmtag.h @@ -27,7 +28,6 @@ #endif #define _RPMDB_INTERNAL -#define _MIRE_INTERNAL #include rpmdb.h #include pkgio.h #include fprint.h @@ . patch -p0 '@@ .' Index: rpm/rpmio/macro.c $ cvs diff -u -r2.147 -r2.148 macro.c --- rpm/rpmio/macro.c 11 Oct 2007 13:04:28 - 2.147 +++ rpm/rpmio/macro.c 3 Nov 2007 13:19:23 - 2.148 @@ -68,6 +68,7 @@ #endif +#define _MACRO_INTERNAL #include rpmmacro.h #include debug.h @@ -201,7 +202,7 @@ if (mc == NULL || mc-macroTable == NULL) return; -qsort(mc-macroTable, mc-firstFree, sizeof(*(mc-macroTable)), +qsort(mc-macroTable, mc-firstFree, sizeof(mc-macroTable[0]), compareMacroName); /* Empty pointers are now at end of table. Reset first free index. */ @@ -213,6 +214,31 @@ } } +static char * dupMacroEntry(MacroEntry me) +{ +char * t, * te; +size_t nb; + +assert(me != NULL); +nb = strlen(me-name) + sizeof(%) - 1; +if (me-opts) + nb += strlen(me-opts) + sizeof(()) - 1; +if (me-body) + nb += strlen(me-body) + sizeof(\t) - 1; +nb++; + +te = t = xmalloc(nb); +*te = '\0'; +te = stpcpy( stpcpy(te, %), me-name); +if (me-opts) + te = stpcpy( stpcpy( stpcpy(te, (), me-opts), )); +if (me-body) + te = stpcpy( stpcpy(te, \t), me-body); +*te = '\0'; + +return t; +} + void rpmDumpMacroTable(MacroContext mc, FILE * fp) { @@ -246,6 +272,41 @@ nactive, nempty); } +int +rpmGetMacroEntries(MacroContext mc, miRE mire, int used, + const char *** avp) +{ +const char ** av; +int ac; +int i; + +if (mc == NULL) + mc = rpmGlobalMacroContext; + +if (avp == NULL) + return mc-firstFree; + +av = xcalloc( (mc-firstFree+1), sizeof(mc-macroTable[0])); +if (mc-macroTable != NULL) +for (i = 0; i mc-firstFree; i++) { + MacroEntry me; + me = mc-macroTable[i];
[CVS] RPM: rpm/rpmio/ librpmio.vers
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: 03-Nov-2007 14:21:43 Branch: HEAD Handle: 2007110313214300 Modified files: rpm/rpmio librpmio.vers Log: update loader map too. Summary: RevisionChanges Path 2.14+1 -0 rpm/rpmio/librpmio.vers patch -p0 '@@ .' Index: rpm/rpmio/librpmio.vers $ cvs diff -u -r2.13 -r2.14 librpmio.vers --- rpm/rpmio/librpmio.vers 24 Sep 2007 02:38:57 - 2.13 +++ rpm/rpmio/librpmio.vers 3 Nov 2007 13:21:43 - 2.14 @@ -212,6 +212,7 @@ rpmExpandNumeric; rpmFreeMacros; rpmGenPath; +rpmGetMacroEntries; rpmGetPath; rpmGlob; rpmGlobalMacroContext; @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ CHANGES rpm/python/ rpmmodule.c rpmrc-py.c rpmrc-py.h ...
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: 03-Nov-2007 16:38:18 Branch: HEAD Handle: 2007110315381800 Modified files: rpm CHANGES rpm/python rpmmodule.c rpmrc-py.c rpmrc-py.h rpm/rpmio rpmlua.c Log: - jbj: add lua/python getMacros bindings (mostly from [EMAIL PROTECTED]). Summary: RevisionChanges Path 1.1764 +1 -0 rpm/CHANGES 1.155 +4 -0 rpm/python/rpmmodule.c 1.20+103 -0 rpm/python/rpmrc-py.c 1.11+14 -0 rpm/python/rpmrc-py.h 2.24+47 -0 rpm/rpmio/rpmlua.c patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.1763 -r1.1764 CHANGES --- rpm/CHANGES 3 Nov 2007 13:19:22 - 1.1763 +++ rpm/CHANGES 3 Nov 2007 15:38:18 - 1.1764 @@ -1,4 +1,5 @@ 4.5 - 5.0: +- jbj: add lua/python getMacros bindings (mostly from [EMAIL PROTECTED]). - jbj: add a getter to retrieve macros with used and/or pattern filtering. - jbj: macro macro table/element internals opaque. - jbj: fix --rebuilddb --root /path. @@ . patch -p0 '@@ .' Index: rpm/python/rpmmodule.c $ cvs diff -u -r1.154 -r1.155 rpmmodule.c --- rpm/python/rpmmodule.c8 Sep 2007 23:44:00 - 1.154 +++ rpm/python/rpmmodule.c3 Nov 2007 15:38:18 - 1.155 @@ -177,6 +177,10 @@ NULL }, { delMacro, (PyCFunction) rpmrc_DelMacro, METH_VARARGS|METH_KEYWORDS, NULL }, +{ expandMacro, (PyCFunction)rpmrc_ExpandMacro, METH_VARARGS|METH_KEYWORDS, + NULL }, +{ getMacros, (PyCFunction) rpmrc_GetMacros, METH_VARARGS|METH_KEYWORDS, + NULL }, { signalsCaught, (PyCFunction) signalsCaught, METH_O, NULL }, @@ . patch -p0 '@@ .' Index: rpm/python/rpmrc-py.c $ cvs diff -u -r1.19 -r1.20 rpmrc-py.c --- rpm/python/rpmrc-py.c 20 Jul 2007 22:47:34 - 1.19 +++ rpm/python/rpmrc-py.c 3 Nov 2007 15:38:18 - 1.20 @@ -63,6 +63,109 @@ return Py_None; } +/** + */ +PyObject * +rpmrc_ExpandMacro(/[EMAIL PROTECTED]@*/PyObject * self, PyObject * args, PyObject * kwds) +{ +char * macro; +char * kwlist[] = {macro, NULL}; + +if (!PyArg_ParseTupleAndKeywords(args, kwds, s:ExpandMacro, kwlist, macro)) + return NULL; + +return Py_BuildValue(s, rpmExpand(macro, NULL)); +} + +/** + */ +PyObject * +rpmrc_GetMacros(/[EMAIL PROTECTED]@*/ PyObject * self, PyObject * args, PyObject * kwds) +{ +char * kwlist[] = { NULL }; +PyObject * mdict; +PyObject *oo, *bo; +const char ** av = NULL; +int ac = 0; +int i; + +if (!PyArg_ParseTupleAndKeywords(args, kwds, :GetMacros, kwlist)) + return NULL; + +mdict = PyDict_New(); +ac = rpmGetMacroEntries(NULL, NULL, -1, av); +if (mdict == NULL || ac 0 || av == NULL) { + PyErr_SetString(pyrpmError, out of memory); + return NULL; +} + +if (ac == 0) { + av = argvFree(av); + return mdict; +} + +oo = PyString_FromString(opts); +bo = PyString_FromString(body); + +if (oo != NULL bo != NULL) +for (i = 0; i ac; i++) { + char *n, *o, *b; + PyObject *ndo, *no, *vo; + int failed = 0; + + /* Parse out %name(opts)\tbody into n/o/b strings. */ + n = (char *) av[i]; + b = strchr(n, '\t'); +assert(b != NULL); + o = ((b n b[-1] == ')') ? strchr(n, '(') : NULL); + if (*n == '%') n++; + if (o != NULL *o == '(') { + b[-1] = '\0'; + o++; + } + b++; + + /* Create a name dictionary, add opts and body items. */ + no = PyString_FromString(n); + if (no == NULL) + break; + + ndo = PyDict_New(); + if (ndo == NULL) { + Py_DECREF(no); + break; + } + PyDict_SetItem(mdict, no, ndo); + Py_DECREF(ndo); + + if (o) { + if ((vo = PyString_FromString(o)) != NULL) + PyDict_SetItem(ndo, oo, vo); + else + failed = 1; + Py_XDECREF(vo); + } + + if (b) { + if ((vo = PyString_FromString(b)) != NULL) + PyDict_SetItem(ndo, bo, vo); + else +
[CVS] RPM: rpm/ CHANGES rpm/rpmio/ rpmlua.c
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: 03-Nov-2007 17:01:26 Branch: HEAD Handle: 2007110316012600 Modified files: rpm CHANGES rpm/rpmio rpmlua.c Log: - rpm.org: fix segfault in %{lua: ...}'s rpm_print, no newline. Summary: RevisionChanges Path 1.1765 +1 -0 rpm/CHANGES 2.25+2 -3 rpm/rpmio/rpmlua.c patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.1764 -r1.1765 CHANGES --- rpm/CHANGES 3 Nov 2007 15:38:18 - 1.1764 +++ rpm/CHANGES 3 Nov 2007 16:01:26 - 1.1765 @@ -1,4 +1,5 @@ 4.5 - 5.0: +- rpm.org: fix segfault in %{lua: ...}'s rpm_print, no newline. - jbj: add lua/python getMacros bindings (mostly from [EMAIL PROTECTED]). - jbj: add a getter to retrieve macros with used and/or pattern filtering. - jbj: macro macro table/element internals opaque. @@ . patch -p0 '@@ .' Index: rpm/rpmio/rpmlua.c $ cvs diff -u -r2.24 -r2.25 rpmlua.c --- rpm/rpmio/rpmlua.c3 Nov 2007 15:38:18 - 2.24 +++ rpm/rpmio/rpmlua.c3 Nov 2007 16:01:26 - 2.25 @@ -172,6 +172,7 @@ lua-storeprint = flag; lua-printbuf = _free(lua-printbuf); lua-printbufsize = 0; +lua-printbufused = 0; } const char *rpmluaGetPrintBuffer(rpmlua _lua) @@ -878,15 +879,13 @@ } lua_pop(L, 1); /* pop result */ } -lua_pop(L, 1); if (!lua-storeprint) { (void) fputs(\n, stdout); } else { - if (lua-printbufused+1 = lua-printbufsize) { + if (lua-printbufused+1 lua-printbufsize) { lua-printbufsize += 512; lua-printbuf = xrealloc(lua-printbuf, lua-printbufsize); } - lua-printbuf[lua-printbufused++] = '\n'; lua-printbuf[lua-printbufused] = '\0'; } return 0; @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: popt/ configure.ac popthelp.c
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Bernhard Rosenkraenzer Root: /v/rpm/cvs Email: [EMAIL PROTECTED] Module: popt Date: 03-Nov-2007 23:18:40 Branch: HEAD Handle: 2007110322184000 Modified files: poptconfigure.ac popthelp.c Log: Make it compile for libc implementations that need alloca.h for alloca() Submitted by: bero Summary: RevisionChanges Path 1.29+1 -1 popt/configure.ac 1.65+5 -0 popt/popthelp.c patch -p0 '@@ .' Index: popt/configure.ac $ cvs diff -u -r1.28 -r1.29 configure.ac --- popt/configure.ac 24 Aug 2007 13:14:41 - 1.28 +++ popt/configure.ac 3 Nov 2007 22:18:40 - 1.29 @@ -68,7 +68,7 @@ fi AC_SUBST(MARK64) -AC_CHECK_HEADERS(float.h libintl.h mcheck.h unistd.h langinfo.h) +AC_CHECK_HEADERS(float.h libintl.h mcheck.h unistd.h langinfo.h alloca.h) # For some systems we know that we have ld_version scripts. # Use it then as default. @@ . patch -p0 '@@ .' Index: popt/popthelp.c $ cvs diff -u -r1.64 -r1.65 popthelp.c --- popt/popthelp.c 25 Aug 2007 00:54:57 - 1.64 +++ popt/popthelp.c 3 Nov 2007 22:18:40 - 1.65 @@ -20,6 +20,11 @@ #include wchar.h /* for mbsrtowcs */ /[EMAIL PROTECTED] mbstate_t @*/ #endif + +#ifdef HAVE_ALLOCA_H +#include alloca.h +#endif + #include poptint.h /[EMAIL PROTECTED] [EMAIL PROTECTED]/ @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: popt/ CHANGES poptconfig.c popthelp.c poptparse.c system.h
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Jeff Johnson Root: /v/rpm/cvs Email: [EMAIL PROTECTED] Module: popt Date: 03-Nov-2007 23:50:34 Branch: HEAD Handle: 2007110322503300 Modified files: poptCHANGES poptconfig.c popthelp.c poptparse.c system.h Log: - jbj: handle Solaris signed character isspace(3) issues consistently. Summary: RevisionChanges Path 1.26+2 -0 popt/CHANGES 1.32+7 -7 popt/poptconfig.c 1.66+0 -3 popt/popthelp.c 1.26+7 -7 popt/poptparse.c 1.11+3 -0 popt/system.h patch -p0 '@@ .' Index: popt/CHANGES $ cvs diff -u -r1.25 -r1.26 CHANGES --- popt/CHANGES 6 Oct 2007 02:14:42 - 1.25 +++ popt/CHANGES 3 Nov 2007 22:50:33 - 1.26 @@ -1,4 +1,6 @@ 1.12 - 1.13: +- jbj: handle Solaris signed character isspace(3) issues consistently. +- bero: include alloca.h where necessary. - bero: read /etc/popt.d/* files. - jbj: don't read /etc/popt twice (#290531). - jbj: isspace(3) has i18n encoding signednesss issues on Solaris (#172393). @@ . patch -p0 '@@ .' Index: popt/poptconfig.c $ cvs diff -u -r1.31 -r1.32 poptconfig.c --- popt/poptconfig.c 6 Oct 2007 02:14:42 - 1.31 +++ popt/poptconfig.c 3 Nov 2007 22:50:33 - 1.32 @@ -33,20 +33,20 @@ if (strncmp(line, con-appName, nameLength)) return; line += nameLength; -if (*line == '\0' || !isspace(*line)) return; +if (*line == '\0' || !_isspaceptr(line)) return; -while (*line != '\0' isspace(*line)) line++; +while (*line != '\0' _isspaceptr(line)) line++; entryType = line; -while (*line == '\0' || !isspace(*line)) line++; +while (*line == '\0' || !_isspaceptr(line)) line++; *line++ = '\0'; -while (*line != '\0' isspace(*line)) line++; +while (*line != '\0' _isspaceptr(line)) line++; if (*line == '\0') return; opt = line; -while (*line == '\0' || !isspace(*line)) line++; +while (*line == '\0' || !_isspaceptr(line)) line++; *line++ = '\0'; -while (*line != '\0' isspace(*line)) line++; +while (*line != '\0' _isspaceptr(line)) line++; if (*line == '\0') return; /[EMAIL PROTECTED]@*/ /* FIX: line alias is saved */ @@ -139,7 +139,7 @@ case '\n': *dst = '\0'; dst = buf; - while (*dst isspace(*dst)) dst++; + while (*dst _isspaceptr(dst)) dst++; if (*dst *dst != '#') configLine(con, dst); chptr++; @@ . patch -p0 '@@ .' Index: popt/popthelp.c $ cvs diff -u -r1.65 -r1.66 popthelp.c --- popt/popthelp.c 3 Nov 2007 22:18:40 - 1.65 +++ popt/popthelp.c 3 Nov 2007 22:50:33 - 1.66 @@ -29,9 +29,6 @@ /[EMAIL PROTECTED] [EMAIL PROTECTED]/ -/* XXX isspace(3) has i18n encoding signednesss issues on Solaris. */ -#define _isspaceptr(_chp) isspace((int)(*(unsigned char *)(_chp))) - /** * Display arguments. * @param concontext @@ . patch -p0 '@@ .' Index: popt/poptparse.c $ cvs diff -u -r1.25 -r1.26 poptparse.c --- popt/poptparse.c 13 Jul 2007 12:24:00 - 1.25 +++ popt/poptparse.c 3 Nov 2007 22:50:33 - 1.26 @@ -86,7 +86,7 @@ if (*src != quote) *buf++ = '\\'; } *buf++ = *src; - } else if (isspace(*src)) { + } else if (_isspaceptr(src)) { if (*argv[argc] != '\0') { buf++, argc++; if (argc == argvAlloced) { @@ -161,7 +161,7 @@ p = line; /* loop until first non-space char or EOL */ - while( *p != '\0' isspace(*p) ) + while( *p != '\0' _isspaceptr(p) ) p++; linelen = strlen(p); @@ -175,13 +175,13 @@ q = p; - while (*q != '\0' (!isspace(*q)) *q != '=') + while (*q != '\0' (!_isspaceptr(q)) *q != '=') q++; - if (isspace(*q)) { + if (_isspaceptr(q)) { /* a space after the name, find next non space */ *q++='\0'; - while( *q != '\0' isspace((int)*q) ) q++; + while( *q != '\0'
[CVS] RPM: rpm/ CHANGES rpm/rpmio/ rpmhash.c rpmhash.h
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: 04-Nov-2007 02:14:29 Branch: HEAD Handle: 2007110401142801 Modified files: rpm CHANGES rpm/rpmio rpmhash.c rpmhash.h Log: - rpm.org: rpmhash.c: use size_t for keySize. Summary: RevisionChanges Path 1.1769 +1 -0 rpm/CHANGES 1.5 +2 -2 rpm/rpmio/rpmhash.c 1.4 +1 -1 rpm/rpmio/rpmhash.h patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.1768 -r1.1769 CHANGES --- rpm/CHANGES 4 Nov 2007 01:05:12 - 1.1768 +++ rpm/CHANGES 4 Nov 2007 01:14:28 - 1.1769 @@ -1,4 +1,5 @@ 4.5 - 5.0: +- rpm.org: rpmhash.c: use size_t for keySize. - rpm.org: remove unnecessary rpmShowProgress() prototype. - jbj: add all-mode --macrosused option, debug rpmGetMacroEntries(). - jbj: access all tag data integers as unsigned, using stdint.h types. @@ . patch -p0 '@@ .' Index: rpm/rpmio/rpmhash.c $ cvs diff -u -r1.4 -r1.5 rpmhash.c --- rpm/rpmio/rpmhash.c 6 Oct 2007 19:40:23 - 1.4 +++ rpm/rpmio/rpmhash.c 4 Nov 2007 01:14:29 - 1.5 @@ -24,7 +24,7 @@ */ struct hashTable_s { int numBuckets; /*! number of hash buckets */ -int keySize; /*! size of key (0 if unknown) */ +size_t keySize; /*! size of key (0 if unknown) */ int freeData;/*! should data be freed when table is destroyed? */ hashBucket * buckets;/*! hash bucket array */ hashFunctionType fn; /*! generate hash value for key */ @@ -108,7 +108,7 @@ return strcmp(k1, k2); } -hashTable htCreate(int numBuckets, int keySize, int freeData, +hashTable htCreate(int numBuckets, size_t keySize, int freeData, hashFunctionType fn, hashEqualityType eq) { hashTable ht; @@ . patch -p0 '@@ .' Index: rpm/rpmio/rpmhash.h $ cvs diff -u -r1.3 -r1.4 rpmhash.h --- rpm/rpmio/rpmhash.h 10 Jul 2007 17:18:13 - 1.3 +++ rpm/rpmio/rpmhash.h 4 Nov 2007 01:14:29 - 1.4 @@ -44,7 +44,7 @@ * @param eqfunction to compare keys for equality (NULL for default) * @return pointer to initialized hash table */ -hashTable htCreate(int numBuckets, int keySize, int freeData, +hashTable htCreate(int numBuckets, size_t keySize, int freeData, /[EMAIL PROTECTED]@*/ hashFunctionType fn, /[EMAIL PROTECTED]@*/ hashEqualityType eq) /[EMAIL PROTECTED]/; @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/build/ files.c names.c pack.c parseChangelog.c rpmbuild...
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: 04-Nov-2007 02:29:24 Branch: HEAD Handle: 2007110401292300 Modified files: rpm/build files.c names.c pack.c parseChangelog.c rpmbuild.h Log: - more int_32 conversion to stdint.h types. Summary: RevisionChanges Path 1.281 +16 -16 rpm/build/files.c 1.34+3 -3 rpm/build/names.c 2.243 +3 -2 rpm/build/pack.c 2.33+1 -1 rpm/build/parseChangelog.c 2.73+1 -1 rpm/build/rpmbuild.h patch -p0 '@@ .' Index: rpm/build/files.c $ cvs diff -u -r1.280 -r1.281 files.c --- rpm/build/files.c 3 Nov 2007 23:43:59 - 1.280 +++ rpm/build/files.c 4 Nov 2007 01:29:23 - 1.281 @@ -1386,8 +1386,8 @@ (flp-fileURL), 1); /[EMAIL PROTECTED]@*/ - if (sizeof(flp-fl_size) != sizeof(uint_32)) { - uint_32 psize = (uint_32)flp-fl_size; + if (sizeof(flp-fl_size) != sizeof(uint32_t)) { + uint32_t psize = (uint32_t)flp-fl_size; (void) headerAddOrAppendEntry(h, RPMTAG_FILESIZES, RPM_INT32_TYPE, (psize), 1); } else { @@ -1398,40 +1398,40 @@ (flp-uname), 1); (void) headerAddOrAppendEntry(h, RPMTAG_FILEGROUPNAME, RPM_STRING_ARRAY_TYPE, (flp-gname), 1); - if (sizeof(flp-fl_mtime) != sizeof(uint_32)) { - uint_32 mtime = (uint_32)flp-fl_mtime; + if (sizeof(flp-fl_mtime) != sizeof(uint32_t)) { + uint32_t mtime = (uint32_t)flp-fl_mtime; (void) headerAddOrAppendEntry(h, RPMTAG_FILEMTIMES, RPM_INT32_TYPE, (mtime), 1); } else { (void) headerAddOrAppendEntry(h, RPMTAG_FILEMTIMES, RPM_INT32_TYPE, (flp-fl_mtime), 1); } - if (sizeof(flp-fl_mode) != sizeof(uint_16)) { - uint_16 pmode = (uint_16)flp-fl_mode; + if (sizeof(flp-fl_mode) != sizeof(uint16_t)) { + uint16_t pmode = (uint16_t)flp-fl_mode; (void) headerAddOrAppendEntry(h, RPMTAG_FILEMODES, RPM_INT16_TYPE, (pmode), 1); } else { (void) headerAddOrAppendEntry(h, RPMTAG_FILEMODES, RPM_INT16_TYPE, (flp-fl_mode), 1); } - if (sizeof(flp-fl_rdev) != sizeof(uint_16)) { - uint_16 prdev = (uint_16)flp-fl_rdev; + if (sizeof(flp-fl_rdev) != sizeof(uint16_t)) { + uint16_t prdev = (uint16_t)flp-fl_rdev; (void) headerAddOrAppendEntry(h, RPMTAG_FILERDEVS, RPM_INT16_TYPE, (prdev), 1); } else { (void) headerAddOrAppendEntry(h, RPMTAG_FILERDEVS, RPM_INT16_TYPE, (flp-fl_rdev), 1); } - if (sizeof(flp-fl_dev) != sizeof(uint_32)) { - uint_32 pdevice = (uint_32)flp-fl_dev; + if (sizeof(flp-fl_dev) != sizeof(uint32_t)) { + uint32_t pdevice = (uint32_t)flp-fl_dev; (void) headerAddOrAppendEntry(h, RPMTAG_FILEDEVICES, RPM_INT32_TYPE, (pdevice), 1); } else { (void) headerAddOrAppendEntry(h, RPMTAG_FILEDEVICES, RPM_INT32_TYPE, (flp-fl_dev), 1); } - if (sizeof(flp-fl_ino) != sizeof(uint_32)) { - uint_32 ino = (uint_32)flp-fl_ino; + if (sizeof(flp-fl_ino) != sizeof(uint32_t)) { + uint32_t ino = (uint32_t)flp-fl_ino; (void) headerAddOrAppendEntry(h, RPMTAG_FILEINODES, RPM_INT32_TYPE, (ino), 1); } else { @@ -1443,10 +1443,10 @@ (void) headerAddOrAppendEntry(h, RPMTAG_FILELANGS, RPM_STRING_ARRAY_TYPE, (flp-langs), 1); - { static uint_32 source_file_dalgo = 0; - static uint_32 binary_file_dalgo = 0; + { static uint32_t source_file_dalgo = 0; + static uint32_t binary_file_dalgo = 0; static int oneshot = 0; - uint_32 dalgo = 0; + uint32_t dalgo = 0; if (!oneshot) { source_file_dalgo = @@ -1531,7 +1531,7 @@ { mode_t fmode; static char *nocon = ; - fmode = (uint_16)flp-fl_mode; + fmode = (uint16_t)flp-fl_mode; if (matchpathcon(flp-fileURL, fmode, scon) || scon == NULL) scon = nocon; (void) headerAddOrAppendEntry(h, RPMTAG_FILECONTEXTS,