[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    [PyKDE] PyQt and Mandrake
From:       Arno Paehler <paehler () asahi-net ! email ! ne ! jp>
Date:       2004-01-26 11:38:43
Message-ID: 1075117123.15889.7.camel () localhost
[Download RAW message or body]

It seems that several people had problems with compiling PyQt
on Mandrake 9.2. I have compiled sip/PyQt against Qt 3.2.3
on a Mandrake 9.2 system, both 3.9 and 3.10.
I now use the 3.10 version on a Mandrake 10.0 beta1 without
any problems. Have not yet tried compiling it under 10.0,
but would assume that there are no problems, since the compiler
and glibc used previously were from Mandrake Cooker, identical
to the 10.0 versions.
The spec files are attached.
Arno Paehler


["sip.spec" (sip.spec)]

%define	name	sip
%define	version	3.10
%define release	1mdk

%define	py_ver	2.3

%define	major	10
%define	libname	%mklibname %{name} %{major}
%define	libname_devel	%mklibname %{name} %{major} -d

Summary:	Python bindings generator for C++ class libraries.
Name:		%{name}
Version:	%{version}
Release:	%{release}
License:	GPL QPL
Group:		Development/Python
Source:		%{name}-%{version}.tar.gz
URL:		http://www.riverbankcomputing.co.uk/sip
BuildRoot:	%{_tmppath}/%{name}-%{version}-buildroot
BuildRequires:	libpython-devel >= %{py_ver}
BuildRequires:	qt3-devel

%description
Generates Python bindings for C++ class libraries from a set of class
specification files.  Also includes a runtime support library needed by all
generated bindings.

%package	-n %{libname}
Summary:	Python bindings generator for C++ class libraries.
Group:		System/Libraries
Provides:	lib%{name} = %{version}

%description	-n %{libname}
Generates Python bindings for C++ class libraries from a set of class
specification files.  Also includes a runtime support library needed by all
generated bindings.

%package	-n %{libname_devel}
Summary:	Libraries and include files for developing.
Group:		Development/C++
Requires:	%{libname} = %{version}
Provides:	lib%{name}-devel = %{version}
Provides:	sip
Obsoletes:	sip

%description	-n %{libname_devel}
Generates Python bindings for C++ class libraries from a set of class
specification files.  Also includes a runtime support library needed by all
generated bindings.


%prep
%setup -q -n %{name}-%{version}

%build
%{__install} -d $RPM_BUILD_ROOT%{_libdir}/python%{py_ver}/site-packages
%{__python} build.py -q %{_libdir}/qt3 -b $RPM_BUILD_ROOT%{_bindir} \
    -d $RPM_BUILD_ROOT%{_libdir}/python%{py_ver}/site-packages<<EOF
    yes
    EOF
%make 
(cd siplib && %make staticlib)


%install
%{__rm} -rf $RPM_BUILD_ROOT
# Make a link for .so's in /usr/lib (in case python
# folder is not in PATH)
mkdir -p $RPM_BUILD_ROOT%{_libdir}
%make
(cd siplib && %make staticlib)
%makeinstall
%{__install} -m644 siplib/sip.h -D $RPM_BUILD_ROOT%{_includedir}/python%{py_ver}/sip.h
%{__install} -m644 siplib/sipQt.h $RPM_BUILD_ROOT%{_includedir}/python%{py_ver}/sipQt.h

rm -f sipconfig.pyc
perl -pi -e "s+$RPM_BUILD_ROOT++" sipconfig.py
perl -pi -e "s+/usr/local/+/usr/+" sipconfig.py
python -c "import sipconfig"
cp -v sipconfig.py $RPM_BUILD_ROOT%{_libdir}/python%{py_ver}/site-packages/
cp -v sipconfig.pyc $RPM_BUILD_ROOT%{_libdir}/python%{py_ver}/site-packages/

(cd $RPM_BUILD_ROOT%{_libdir}
ln -sf python%{py_ver}/site-packages/libsip.so.%{major} ./libsip.so.%{major}
ln -sf python%{py_ver}/site-packages/libsip.so.%{major}.0.0 ./libsip.so.%{major}.0.0)

%post -n %{libname} -p /sbin/ldconfig
%postun -n %{libname} -p /sbin/ldconfig

%clean
%{__rm} -rf $RPM_BUILD_ROOT

%files -n %{libname_devel}
%defattr(-, root, root, 755)
%doc NEWS README
%{_bindir}/sip
%{_includedir}/python*/sip.h
%{_includedir}/python*/sipQt.h
%{_libdir}/python*/site-packages/libsip.a
%files -n %{libname}
%defattr(-, root, root, 755)
%{_libdir}/python*/site-packages/*.so.*
%{_libdir}/python*/site-packages/libsip.so
%{_libdir}/python*/site-packages/sipconfig.py
%{_libdir}/python*/site-packages/sipconfig.pyc

%changelog
* Mon Sep  8 2003 Götz Waschk <waschk@linux-mandrake.com> 3.8-3mdk
- fix buildrequires

* Sun Sep  7 2003 Götz Waschk <waschk@linux-mandrake.com> 3.8-2mdk
- fix buildrequires
- move libsip.so to the lib package, as it's required by generated bindings
- move sip to the devel package

* Wed Aug 20 2003 Austin Acton <aacton@yorku.ca> 3.8-1mdk
- 3.8

* Sat Aug 9 2003 Austin Acton <aacton@yorku.ca> 3.6-8mdk
- the one true fix (eat your heart out per oyvind :-) )

* Fri Aug 08 2003 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 3.6-7mdk
- really rebuild for new python (austin was the sucky one this time;)

* Thu Aug 7 2003 Austin Acton <aacton@yorku.ca> 3.6-6mdk
- python 2.3

* Sat Jul 19 2003 Till Kamppeter <till@mandrakesoft.com> 3.6-5mdk
- Rebuild

* Fri Jun 20 2003 Per Øyvind Karlsen <peroyvind@sintrax.net> 3.6-4mdk
- fix path to qt3 (lib64 issues)
- use %%mklibname macro for -devel package

* Tue May 27 2003 Austin Acton <aacton@yorku.ca> 3.6-3mdk
- rebuild for rpm 4.2

* Tue Apr 29 2003 Per Øyvind Karlsen <peroyvind@sintrax.net> 3.6-2mdk
- added QPL to license

* Tue Apr 29 2003 Per Øyvind Karlsen <peroyvind@sintrax.net> 3.6-1mdk
- 3.6 (lib major 9)
- cleanups
- fix license
- make --short-circuitable
- use %%mklibname macro

* Fri Jan 03 2003 Lenny Cartier <lenny@mandrakesoft.com> 3.5-1mdk
- 3.5

* Sat Aug 17 2002 Christian Belisle <cbelisle@mandrakesoft.com> 3.3.2-2mdk
- fix Provides for libsip9.

* Wed Jul 17 2002 Christian Belisle <cbelisle@mandrakesoft.com> 3.3.2-1mdk
- 3.3.2
- use the new sip's build script

* Sat Jun 29 2002 Olivier Thauvin <thauvin@aerov.jussieu.fr> 3.2.4-1mdk
- 3.2.4

* Tue May 28 2002 Lenny Cartier <lenny@mandrakesoft.com> 3.2.2-2mdk
- rebuild against new libstdc++

* Mon May 13 2002 Lenny Cartier <lenny@mandrakesoft.com> 3.2.2-1mdk
- 3.2.2

* Tue May 07 2002 Lenny Cartier <lenny@mandrakesoft.com> 3.2.1-1mdk
- 3.2.1

* Mon Apr 08 2002 Christian Belisle <cbelisle@mandrakesoft.com> 3.1-1mdk
- version 3.1 (lib major 8).
- update URL.

* Fri Jan 11 2002 Lenny Cartier <lenny@mandrakesoft.com> 3.0-3mdk
- merge with  RA <ralf_ahlbrink@web.de> mods :
	- added BuildRequires: libpython2.2-devel

* Fri Nov 30 2001 Yves Duret <yduret@mandrakesoft.com> 3.0-1mdk
- version 3.0 (lib major 7)

* Fri Nov 30 2001 Yves Duret <yduret@mandrakesoft.com> 2.5-2mdk
- rebuild against libpng3
- %%makeinstall_std
- std %%build step (macros..)
- added %%dir %%{_includedir}/sip in -devel package

* Mon Sep 03 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.5-1mdk
- 2.5

* Mon May 14 2001 Yves BAILLY <ybailly@mandrakesoft.com> 2.4-3mdk
- fixed some errors in spec file (sorry, my first package)

* Mon May 14 2001 Yves BAILLY <ybailly@mandrakesoft.com> 2.4-2mdk
- fixed the Python dependency (>= 2.0 instead of = 2.0)

* Mon May 14 2001 Yves BAILLY <ybailly@mandrakesoft.com> 2.4-1mdk
- upgrade to version 2.4

* Tue Mar 20 2001 David BAUDENS <baudens@mandrakesoft.com> 2.3-2mdk
- Rebuild against Qt 2.3.0

* Wed Feb 21 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.3-1mdk
- updated to 2.3

* Mon Feb 12 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.2-1mdk
- used srpm from Gerard Vermeulen <gvermeul@labs.polycnrs-gre.fr>
        - built on Mandrake-7.2 following Mandrake RPM guidelines



["PyQt.spec" (PyQt.spec)]

%define name 	PyQt
%define version 3.10
%define release 1mdk

# py_ver, because modules have to be recompiled for another Python version
%define py_ver 	2.3
%define py_min  3

Summary:	Python bindings for Qt.
Name:		%{name}
Version:	%{version}
Release:	%{release}
License:	GPL QPL
Group:		Development/Python
Source:		%{name}-x11-gpl-%{version}.tar.gz
URL:		http://www.riverbankcomputing.co.uk/pyqt
BuildRoot:	%{_tmppath}/%{name}-buildroot
BuildRequires:	libsip10-devel libqscintilla3-devel sip libpython-devel = %{py_ver}.%{py_min}
Requires:	sip python libqt3
Requires:	libsip10-devel libqt3-devel

%description
Python bindings for the Qt C++ class library.

%package devel
Summary: 	SIP specification files for Qt.
Group: 		Development/Python
Requires:	%name = %version

%description devel
The SIP specification files for the Qt class library.

%prep
%setup -q -n %name-x11-gpl-%version

%build
mkdir -p $RPM_BUILD_ROOT%{_libdir}/python%{py_ver}/site-packages
%{__python} build.py \
    -b $RPM_BUILD_ROOT%{_bindir} \
    -d $RPM_BUILD_ROOT%{_libdir}/python%{py_ver}/site-packages <<EOF
    yes
    EOF
# note that -j2 does not work
make

%install
%makeinstall_std
mkdir -p %buildroot/%_datadir/sip
cp -r sip %buildroot/%_datadir

%clean
rm -rf %{buildroot}

%files
%defattr(-, root, root, 755)
%doc NEWS README ChangeLog LICENSE THANKS
%doc doc examples3
%{_bindir}/*
%{_libdir}/python%{py_ver}/site-packages/libqt*cmodule*.*
%{_libdir}/python%{py_ver}/site-packages/qt*.py*

%files devel
%defattr(-,root,root)
%{_datadir}/sip

%changelog
* Fri Aug 22 2003 Austin Acton <aacton@yorku.ca> 3.8-1mdk
- 3.8
- libqscintilla3
- regenerate patch

* Tue Aug 12 2003 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 3.6-10mdk
- me suckysucky long time, really rebuild against new python
- make sure to use %%py_ver macro in stead of hardcoding version in path

* Fri Aug 08 2003 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 3.6-9mdk
- rebuild for new python

* Sat Jul 19 2003 Till Kamppeter <till@mandrakesoft.com> 3.6-8mdk
- Rebuild
- BuildRequires: sip

* Fri Jun 20 2003 Per Øyvind Karlsen <peroyvind@sintrax.net> 3.6-7mdk
- fix path to qt3 (lib64 issues..)

* Tue May 27 2003 Austin Acton <aacton@yorku.ca> 3.6-6mdk
- rebuild agains libqscintilla2

* Thu May 1 2003 Austin Acton <aacton@yorku.ca> 3.6-5mdk
- rebuild for qt 3.1.2

* Thu May 1 2003 Austin Acton <aacton@yorku.ca> 3.6-4mdk
- new patch didn't work; go to original patch and require libqt3-devel
- add devel package full of sip files (needed for pykde)

* Wed Apr 29 2003 Austin Acton <aacton@yorku.ca> 3.6-3mdk
- fix patch to exclude qassistant from build
- add qscintilla support

* Tue Apr 29 2003 Austin Acton <aacton@yorku.ca> 3.6-2mdk
- add patch to remove references to QT styles we don't have
  (otherwise python won't import this)
- requires libsip-devel to run (stupid call to libsip.so)

* Tue Apr 29 2003 Austin Acton <aacton@yorku.ca> 3.6-1mdk
- 3.6
- cleanup spec and requires
- fix license
- add some missing files, remove qt2 files
- answer yes during setup using Per Oyvind's trick

* Fri Jan 03 2003 Lenny Cartier <lenny@mandrakesoft.com> 3.5-1mdk
- 3.5

* Mon Apr 08 2002 Christian Belisle <cbelisle@mandrakesoft.com> 3.1-1mdk
- version 3.1.
- Update URL.
- Update python version.
- Macroize.
- Quiet the setup

* Tue Sep 04 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.5-1mdk
- fix build 
- updated by RA <Ralf_Ahlbrink@web.de> :
	- upgrade to 2.5

* Fri Jun 01 2001 Yves Bailly <ybailly@mandrakesoft.com> 2.4-1mdk
- upgrade to 2.4

* Thu Feb 22 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.3-1mdk
- used sprm from  Gerard Vermeulen <gvermeul@labs.polycnrs-gre.fr>

* Sun Feb 04 2001 Gerard Vermeulen <gvermeul@labs.polycnrs-gre.fr> 2.3-2mgv
- tweak %%files

* Tue Oct 10 2000 Gerard Vermeulen <gvermeul@labs.polycnrs-gre.fr> 2.2-1mgv
- mandrakization for 7.2


_______________________________________________
PyKDE mailing list    PyKDE@mats.imk.fraunhofer.de
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic