Need help/advice making rpm for opensuse 10.3

That got me past that just fine, thanks. Now there's this problem:

···

On Thu 13 March 08, Robin Dunn wrote:

John B wrote:
> Hi list,
>
> I downloaded the src.rpm (2.8.7.1).
>
> On the command line I did rpmbuild --rebuild <src.rpm>
>
> After a bit of waiting as it 'did its thing', I got this:
>
> -------
> 'WX_CONFIG=/usr/src/packages/BUILD/wxPython-src-2.8.7.1/bld/wx-config
> --no_rpath' build_ext --rpath=/usr/lib/wxPython-2.8.7.1-gtk2-unicode/lib
> build /var/tmp/rpm-tmp.15300: line 59: /usr/bin/python2.4: No such file
> or directory error: Bad exit status from /var/tmp/rpm-tmp.15300 (%build)
> -------
>
> I checked my python and I have 2.5, not 2.4. Does that mean I can't
> build wxPython rpms?

You can change the version of python used by default by passing these
command line args to rpmbuild:

  --define 'pyver 2.5''

-------
Writing /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxaddons-2.8.7.1-py2.5.egg-info
running build_ext
running install
running build
running build_py
running install_lib
copying
build-gtk2.unicode/lib/wxversion.py -> /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages
byte-compiling /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxversion.py
to wxversion.pyc
running install_data
copying
src/wx.pth -> /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/
running install_egg_info
Writing /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxPython_common-2.8.7.1-py2.5.egg-info
+
rm /var/tmp/wxPython-buildroot/usr/lib/wxPython-2.8.7.1-gtk2-unicode/bin/wx-config
+
strip '/var/tmp/wxPython-buildroot/usr/lib*/python2.5/site-packages/wx-2.8*-gtk2-unicode/wx/*.so'
strip: '/var/tmp/wxPython-buildroot/usr/lib*/python2.5/site-packages/wx-2.8*-gtk2-unicode/wx/*.so':
No such file
error: Bad exit status from /var/tmp/rpm-tmp.32437 (%install)
-------

  For the life of me, I can't figure out what the heck I'm doing wrong, and I
don't know what to look for with this error. Any suggestions?

John B wrote:

···

On Thu 13 March 08, Robin Dunn wrote:

John B wrote:

  Hi list,

  I downloaded the src.rpm (2.8.7.1).

  On the command line I did rpmbuild --rebuild <src.rpm>

  After a bit of waiting as it 'did its thing', I got this:

-------
'WX_CONFIG=/usr/src/packages/BUILD/wxPython-src-2.8.7.1/bld/wx-config
--no_rpath' build_ext --rpath=/usr/lib/wxPython-2.8.7.1-gtk2-unicode/lib
build /var/tmp/rpm-tmp.15300: line 59: /usr/bin/python2.4: No such file
or directory error: Bad exit status from /var/tmp/rpm-tmp.15300 (%build)
-------

  I checked my python and I have 2.5, not 2.4. Does that mean I can't
build wxPython rpms?

You can change the version of python used by default by passing these
command line args to rpmbuild:

  --define 'pyver 2.5''

  That got me past that just fine, thanks. Now there's this problem:

-------
Writing /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxaddons-2.8.7.1-py2.5.egg-info
running build_ext
running install
running build
running build_py
running install_lib
copying build-gtk2.unicode/lib/wxversion.py -> /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages
byte-compiling /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxversion.py to wxversion.pyc
running install_data
copying src/wx.pth -> /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/
running install_egg_info
Writing /var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxPython_common-2.8.7.1-py2.5.egg-info
+ rm /var/tmp/wxPython-buildroot/usr/lib/wxPython-2.8.7.1-gtk2-unicode/bin/wx-config
+ strip '/var/tmp/wxPython-buildroot/usr/lib*/python2.5/site-packages/wx-2.8*-gtk2-unicode/wx/*.so'
strip: '/var/tmp/wxPython-buildroot/usr/lib*/python2.5/site-packages/wx-2.8*-gtk2-unicode/wx/*.so': No such file
error: Bad exit status from /var/tmp/rpm-tmp.32437 (%install)
-------

  For the life of me, I can't figure out what the heck I'm doing wrong, and I don't know what to look for with this error. Any suggestions?

It looks like your python is installed with a prefix of /usr/local, but the RPM spec file for wxPython is expecting it to be /usr. You'll either need to tweak the spec file, rebuild/reinstall Python to use a prefix of /usr, or build wxPython by hand instead of building the RPM.

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

John B wrote:

···

On Fri 14 March 08, Robin Dunn wrote:

John B wrote:

  That got me past that just fine, thanks. Now there's this problem:

-------
Writing
/var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxaddon
s-2.8.7.1-py2.5.egg-info running build_ext
running install
running build
running build_py
running install_lib
copying
build-gtk2.unicode/lib/wxversion.py ->
/var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages
byte-compiling
/var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxversi
on.py to wxversion.pyc
running install_data
copying
src/wx.pth ->
/var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/
running install_egg_info
Writing
/var/tmp/wxPython-buildroot/usr/local/lib/python2.5/site-packages/wxPytho
n_common-2.8.7.1-py2.5.egg-info +
rm
/var/tmp/wxPython-buildroot/usr/lib/wxPython-2.8.7.1-gtk2-unicode/bin/wx-
config +
strip
'/var/tmp/wxPython-buildroot/usr/lib*/python2.5/site-packages/wx-2.8*-gtk
2-unicode/wx/*.so' strip:
'/var/tmp/wxPython-buildroot/usr/lib*/python2.5/site-packages/wx-2.8*-gtk
2-unicode/wx/*.so': No such file
error: Bad exit status from /var/tmp/rpm-tmp.32437 (%install)
-------

  For the life of me, I can't figure out what the heck I'm doing wrong,
and I don't know what to look for with this error. Any suggestions?

It looks like your python is installed with a prefix of /usr/local, but
the RPM spec file for wxPython is expecting it to be /usr. You'll
either need to tweak the spec file, rebuild/reinstall Python to use a
prefix of /usr, or build wxPython by hand instead of building the RPM.

  Uummmm....okay. Wha'ts mean in english, heh. Any suggestions for tweaking the spec file? I'm on dial-up, so downloading again would be a real pita.

The source RPM contains the tarball and the spec file. You can extract them from the source RPM, edit the spec file, and then use rpmbuild with different options (see the man page) to build from the tarball and spec file instead of using the source RPM.

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!