Hi Matthias,

Have you tested this with any software dependant on RPM or is this a
mechanical conversion?

I'm particularly concerned as alien, yum and a few other tools use rpm
(and in the case of yum, the python interfaace) and as far as I knew
this conversion would break things.

Anand

On Mon, Jul 10, 2006 at 03:55:51PM +0200, Matthias Klose wrote:
> Package: rpm
> 
> diff -u rpm-4.4.1/debian/changelog rpm-4.4.1/debian/changelog
> --- rpm-4.4.1/debian/changelog
> +++ rpm-4.4.1/debian/changelog
> @@ -1,3 +1,10 @@
> +rpm (4.4.1-9.1) unstable; urgency=low
> +
> +  * NMU.
> +  * Convert to updated Python policy.
> +
> + -- Matthias Klose <[EMAIL PROTECTED]>  Mon, 10 Jul 2006 14:24:07 +0200
> +
>  rpm (4.4.1-9) unstable; urgency=low
>  
>    * Synchronize to Ubuntu
> diff -u rpm-4.4.1/debian/control rpm-4.4.1/debian/control
> --- rpm-4.4.1/debian/control
> +++ rpm-4.4.1/debian/control
> @@ -1,9 +1,10 @@
>  Source: rpm
>  Section: admin
>  Priority: optional
> -Build-Depends: debhelper (>= 5), libtool, autoconf, automake1.9, zlib1g-dev, 
> libbz2-dev, libdb3-dev, dpkg-dev (>= 1.9.0), libpopt-dev (>= 1.6.4), 
> python2.4-dev, libbeecrypt6-dev, libneon25-dev, libxml2-dev, 
> libreadline5-dev, libselinux1-dev, libsepol1-dev, libsqlite3-dev, python-dev
> +Build-Depends: debhelper (>= 5.0.37.1), libtool, autoconf, automake1.9, 
> zlib1g-dev, libbz2-dev, libdb3-dev, dpkg-dev (>= 1.9.0), libpopt-dev (>= 
> 1.6.4), python-all-dev, libbeecrypt6-dev, libneon25-dev, libxml2-dev, 
> libreadline5-dev, libselinux1-dev, libsepol1-dev, libsqlite3-dev, 
> python-central (>= 0.5)
>  Maintainer: Anibal Monsalve Salazar <[EMAIL PROTECTED]>
>  Uploaders: Anand Kumria <[EMAIL PROTECTED]>, Víctor Pérez Pereira <[EMAIL 
> PROTECTED]>
> +XS-Python-Version: all
>  Standards-Version: 3.7.2
>  
>  Package: rpm
> @@ -62,11 +63,15 @@
>   .
>    Homepage: http://rpm.org/
>  
> -Package: python2.4-rpm
> +Package: python-rpm
>  Architecture: any
>  Section: python
>  Priority: extra
>  Depends: ${misc:Depends}, ${shlibs:Depends}, ${python:Depends}
> +Conflicts: python2.3-rpm, python2.4-rpm
> +Replaces: python2.3-rpm, python2.4-rpm
> +Provides: ${python:Provides}
> +XB-Python-Version: ${python:Versions}
>  Description: Python bindings for RPM
>   This library allows programs to make use of a rpm database or rpm packages
>   without going through the rpm program.
> diff -u rpm-4.4.1/debian/rules rpm-4.4.1/debian/rules
> --- rpm-4.4.1/debian/rules
> +++ rpm-4.4.1/debian/rules
> @@ -2,6 +2,9 @@
>  
>  export DH_VERBOSE=1
>  
> +PYDEF        := $(shell pyversions -vd)
> +PYVERS       := $(shell pyversions -vr debian/control)
> +
>  makefiles:
>       cd popt && aclocal && libtoolize --copy --force && automake -c -i && 
> autoconf && ./configure
>       #cd beecrypt && aclocal-1.7 && libtoolize --copy --force && 
> automake-1.7 -i -a -c -f && autoconf
> @@ -9,7 +12,7 @@
>       #libtoolize --copy --force
>       #automake-1.7 -i -a -c -f
>       #autoconf
> -     ./configure --prefix=/usr --mandir=/usr/share/man --enable-shared 
> --with-python=2.4
> +     ./configure --prefix=/usr --mandir=/usr/share/man --enable-shared 
> --with-python=$(PYDEF)
>       touch makefiles
>  
>  build: build-stamp
> @@ -32,6 +35,16 @@
>               ./rpmio/.libs/librpmio.a -L/usr/local/lib -lbeecrypt -lneon \
>               -lssl -lcrypto -lxml2 -lm -lsqlite3 -lz -lbz2 -lpopt -ldb \
>               -lselinux -lsepol -ldl -lpthread --static
> +     set -e; \
> +     for v in $(filter-out $(PYDEF), $(PYVERS)); do \
> +       rm -rf python$$v; \
> +       cp -a python python$$v; \
> +       $(MAKE) -C python$$v clean \
> +         subdir=python$$v WITH_PYTHON_VERSION=$$v; \
> +       $(MAKE) -C python$$v \
> +         subdir=python$$v WITH_PYTHON_VERSION=$$v \
> +         pylibdir=/usr/lib/python$$v pyincdir=/usr/include/python$$v; \
> +     done
>       touch build-stamp
>  
>  clean:
> @@ -39,6 +52,7 @@
>       dh_testroot
>       rm -f build-stamp makefiles
>       -$(MAKE) distclean
> +     rm -rf python?.?
>       # My diff is big enough without this crap, thank you all the same.
>       rm -rf apidocs beecrypt/autom4te.cache popt/autom4te.cache
>       find -name Makefile |grep -v intl |xargs rm -f
> @@ -60,6 +74,12 @@
>       dh_clean -k
>       dh_installdirs
>       $(MAKE) DESTDIR=`pwd`/debian/tmp install
> +     set -e; \
> +     for v in $(filter-out $(PYDEF), $(PYVERS)); do \
> +       $(MAKE) -C python$$v install DESTDIR=`pwd`/debian/tmp \
> +         subdir=python$$v WITH_PYTHON_VERSION=$$v \
> +         pylibdir=/usr/lib/python$$v pyincdir=/usr/include/python$$v; \
> +     done
>       # Kill all the junk this installs.
>       rm -f debian/tmp/usr/lib/rpm/config.guess \
>               debian/tmp/usr/lib/rpm/config.sub \
> @@ -70,15 +90,16 @@
>       # remove popt
>       rm -rf debian/tmp/usr/share/man/man3
>       rm -f debian/tmp/usr/include/popt.h
> -     rm -f debian/tmp/usr/lib/python2.4/site-packages/poptmodule.*
> +     rm -f debian/tmp/usr/lib/python*/site-packages/poptmodule.*
>       find debian/tmp -name popt.mo |xargs rm
>       find debian/tmp/usr/share/locale -empty |xargs --no-run-if-empty rmdir 
> -p --ignore-fail-on-non-empty
>       mv debian/tmp/bin/rpm debian/tmp/usr/bin/
>       rmdir debian/tmp/bin debian/tmp/var/tmp
>       # fixup some perms
>       chmod 644 debian/tmp/usr/lib/rpm/Specfile.pm
> -     chmod -R 644 debian/tmp/usr/lib/python2.4/site-packages/rpmdb/
> -     chmod 644 debian/tmp/usr/lib/python2.4/site-packages/rpm/__init__.py
> +     find debian/tmp/usr/lib/python*/site-packages/rpmdb -type f \
> +       | xargs --no-run-if-empty chmod 644
> +     chmod 644 debian/tmp/usr/lib/python*/site-packages/rpm/__init__.py
>       # Recode the (translated) manpages according to the encoding expected 
> on Debian
>       /bin/sh debian/recode_manpages.sh
>       # rpmdiff.cgi is crap that I don't want installed
> @@ -97,7 +118,8 @@
>       dh_installmenu
>       dh_installcron
>       dh_installchangelogs -k CHANGES
> -     dh_python -V2.4
> +     dh_pycentral
> +     dh_python
>       dh_strip
>       dh_compress
>       # Remember to update after upstream releases. The whole soname is
> reverted:
> --- rpm-4.4.1/debian/python2.4-rpm.install
> +++ rpm-4.4.1.orig/debian/python2.4-rpm.install
> @@ -1 +0,0 @@
> -debian/tmp/usr/lib/python2.4/
> only in patch2:
> unchanged:
> --- rpm-4.4.1.orig/debian/python-rpm.install
> +++ rpm-4.4.1/debian/python-rpm.install
> @@ -0,0 +1 @@
> +debian/tmp/usr/lib/python*/
> 
> 
> 

-- 
 `When any government, or any church for that matter, undertakes to say to
  its subjects, "This you may not read, this you must not see, this you are
  forbidden to know," the end result is tyranny and oppression no matter how
  holy the motives' -- Robert A Heinlein, "If this goes on --"

Attachment: signature.asc
Description: Digital signature

Reply via email to