Re: [PATCH python] Add python3 to the automated build and RPM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Dec 11, 2013 at 01:01:03PM -0700, Eric Blake wrote:
> On 12/11/2013 09:31 AM, Daniel P. Berrange wrote:
> > From: "Daniel P. Berrange" <berrange@xxxxxxxxxx>
> > 
> > This updates autobuild.sh to test the python3 build process.
> > The RPM specfile is changed to build a libvirt-python3 RPM
> > on Fedora > 18
> > 
> > Signed-off-by: Daniel P. Berrange <berrange@xxxxxxxxxx>
> > ---
> >  autobuild.sh           |  6 ++++++
> >  libvirt-python.spec.in | 57 +++++++++++++++++++++++++++++++++++++++++++-------
> >  2 files changed, 56 insertions(+), 7 deletions(-)
> > 
> 
> > +++ b/libvirt-python.spec.in
> > @@ -1,5 +1,10 @@
> >  
> > -Summary: The libvirt virtualization API python binding
> > +%global with_python3 0
> > +%if 0%{?fedora} > 18
> > +%global with_python3 1
> > +%endif
> 
> Is %global the right thing to use?  Elsewhere we have just used %define
> when setting up a variable that conditionalizes the rest of the spec file.

Oh I copied this from another Fedora spec, but this won't work on
rhel5, so should stick with %define

> 
> >  %build
> > -CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
> > +CFLAGS="$RPM_OPT_FLAGS" %{__python2} setup.py build
> 
> How far back can we assume that %{__python2} exists?  Is it going to
> bite us on RHEL 6 (where I'm guessing there is just %{__python})?

It bites on RHEL-5, so i'll use plain %{__python}


Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]