Problems building 2.9.3.1 on RHEL6

I've tried to install 2.9.3.1 using two different approaches on RHEL6:
build script and source RPM. I'll start with the issue that I ran
into with the build script.

------------------------------------------------BUILD SCRIPT
ISSUES--------------------------------------------------------------
Using the following command:
/disk01/data/davidsj2/wxPython-src-2.9.3.1/wxPython > ./build-
wxpython.py --build_dir=../bld

I'm able to build locally without issue. Now, if I try to install
using: ./build-wxpython.py --build_dir=../bld --install

As expected, the build fails because I'm not root and can't modify my
system python distribution. So, if I try to run as root: sudo ./build-
wxpython.py --build_dir=.. --install

The build fails on the very first source file compilation:
building '_core_' extension
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-
D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-
size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g
-pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --
param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -
fwrapv -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -
DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -
D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -Iinclude -Isrc -I/usr/
local/lib/wx/include/gtk2-unicode-2.9 -I/usr/local/include/wx-2.9 -I/
usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/
atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/
glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/
include/freetype2 -I/usr/include/libpng12 -I/usr/include/python2.6 -c
src/helpers.cpp -o build/temp.linux-x86_64-2.6/src/helpers.o -pthread -
O3
In file included from src/helpers.cpp:17:
include/wx/wxPython/wxPython_int.h:35:19: error: wx/wx.h: No such file
or directory

You can see that it's not adding -I../include to the include path like
it should be (wx/wx.h is in ../include). *IF* I set my CPATH variable
to hard code that path I *can* get the build to work, but I'm not sure
why that's required.

building '_core_' extension
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-
D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-
size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g
-pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --
param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -
fwrapv -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -
DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -
D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -Iinclude -Isrc -I/usr/
local/lib/wx/include/gtk2-unicode-2.9 -I/usr/local/include/wx-2.9 -I/
usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/
atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/
glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/
include/freetype2 -I/usr/include/libpng12 -I/usr/include/python2.6 -c
src/helpers.cpp -o build/temp.linux-x86_64-2.6/src/helpers.o -pthread -
O3
In file included from /disk01/data/davidsj2/wxPython-src-2.9.3.1/
include/wx/defs.h:28,
                 from /disk01/data/davidsj2/wxPython-src-2.9.3.1/
include/wx/wx.h:15,
                 from include/wx/wxPython/wxPython_int.h:35,
                 from src/helpers.cpp:17:
/disk01/data/davidsj2/wxPython-src-2.9.3.1/include/wx/platform.h:
181:22: error: wx/setup.h: No such file or directory

------------------------------------------------RPM
ISSUES--------------------------------------------------------------
So, if I try to build from the source RPM using the following:
/disk01/data/davidsj2/rpmbuild > rpmbuild --rebuild --define "_topdir /
disk01/data/davidsj2/rpmbuild" wxPython2.9-2.9.3.1-1.src.rpm

The build spins right along until we get to:
g++ -o wxrc wxrc_wxrc.o -L/disk01/data/davidsj2/rpmbuild/BUILD/
wxPython-src-2.9.3.1/bld/lib -pthread -lwx_baseu_xml-2.9 -
lwx_baseu-2.9 -lwxregexu-2.9 -lwxexpat-2.9 -pthread -Wl,--
version-script,/disk01/data/davidsj2/rpmbuild/BUILD/wxPython-
src-2.9.3.1/bld/version-script -lz -ldl -lm -lz -ldl -lm
make[1]: Leaving directory `/disk01/data/davidsj2/rpmbuild/BUILD/
wxPython-src-2.9.3.1/bld/utils/wxrc'
+ make -C contrib/src/gizmos
make: *** contrib/src/gizmos: No such file or directory. Stop.
error: Bad exit status from /var/tmp/rpm-tmp.o9e6ua (%build)

RPM build errors:
    user robind does not exist - using root
    group robind does not exist - using root
    user robind does not exist - using root
    group robind does not exist - using root
    Bad exit status from /var/tmp/rpm-tmp.o9e6ua (%build)

When I search the top directory for gizmos, I see:
[davidsj2@scts01] /disk01/data/davidsj2/rpmbuild > find . -name gizmos
./BUILD/wxPython-src-2.9.3.1/wxPython/contrib/gizmos
./BUILD/wxPython-src-2.9.3.1/wxPython/contrib/gizmos/wxCode/src/gizmos
./BUILD/wxPython-src-2.9.3.1/wxPython/contrib/gizmos/wxCode/include/wx/
gizmos

So there is a contrib/gizmos, but no contrib/src/gizmos.

The next step in the spec file is: make -C contrib/src/stc
I think that may also run into issues:
[davidsj2@scts01] /disk01/data/davidsj2/rpmbuild > find . -name stc
./BUILD/wxPython-src-2.9.3.1/src/stc
./BUILD/wxPython-src-2.9.3.1/include/wx/stc
./BUILD/wxPython-src-2.9.3.1/interface/wx/stc
./BUILD/wxPython-src-2.9.3.1/bld/samples/stc
./BUILD/wxPython-src-2.9.3.1/samples/stc

Ok, I lied. I could not get the build script to work with sudo. It
appeared to finish after setting the CPATH multiple times, but it
didn't actually work. I then decided to try and "install" as myself
in a temp directory:
python build-wxpython.py --build_dir=../bld --install --installdir=/
disk01/data/davidsj2/temp --install

This is what happens:

**** /usr/bin/python -u ./setup.py install UNICODE=1 BUILD_BASE=build
WX_CONFIG="/disk01/data/davidsj2/temp/usr/local/bin/wx-config --
prefix=/disk01/data/davidsj2/temp/usr/local" --record
installed_files.txt
WARNING: WXWIN not set in environment. Assuming '..'
Preparing CORE...
Preparing STC...
Preparing GLCANVAS...
Preparing GIZMOS...
running install
running build
running build_py
running install_lib
running install_data
copying src/wx.pth -> /usr/lib/python2.6/site-packages/
error: could not delete '/usr/lib/python2.6/site-packages/wx.pth':
Permission denied
ERROR: failed installing wxPython.

So even though I specified installdir, it tried to update site-
packages.

I've tried to install 2.9.3.1 using two different approaches on RHEL6:
build script and source RPM. I'll start with the issue that I ran
into with the build script.

------------------------------------------------BUILD SCRIPT
ISSUES--------------------------------------------------------------
Using the following command:
/disk01/data/davidsj2/wxPython-src-2.9.3.1/wxPython> ./build-
wxpython.py --build_dir=../bld

I'm able to build locally without issue. Now, if I try to install
using: ./build-wxpython.py --build_dir=../bld --install

As expected, the build fails because I'm not root and can't modify my
system python distribution. So, if I try to run as root: sudo ./build-
wxpython.py --build_dir=.. --install

Is this a typo or did you not use ../bld this time?

The build fails on the very first source file compilation:
building '_core_' extension
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-
D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-
size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g
-pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --
param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -
fwrapv -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -
DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -
D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -Iinclude -Isrc -I/usr/
local/lib/wx/include/gtk2-unicode-2.9 -I/usr/local/include/wx-2.9 -I/
usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/
atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/
glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/
include/freetype2 -I/usr/include/libpng12 -I/usr/include/python2.6 -c
src/helpers.cpp -o build/temp.linux-x86_64-2.6/src/helpers.o -pthread -
O3
In file included from src/helpers.cpp:17:
include/wx/wxPython/wxPython_int.h:35:19: error: wx/wx.h: No such file
or directory

You can see that it's not adding -I../include to the include path like
it should be (wx/wx.h is in ../include). *IF* I set my CPATH variable
to hard code that path I *can* get the build to work, but I'm not sure
why that's required.

Were there any messages about not being able to find wx-config? Or indications of which wx-config was being used?

building '_core_' extension
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-
D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-
size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g
-pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --
param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -
fwrapv -fPIC -DSWIG_TYPE_TABLE=_wxPython_table -
DSWIG_PYTHON_OUTPUT_TUPLE -DWXP_USE_THREAD=1 -UNDEBUG -
D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -Iinclude -Isrc -I/usr/
local/lib/wx/include/gtk2-unicode-2.9 -I/usr/local/include/wx-2.9 -I/
usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/
atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/
glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/
include/freetype2 -I/usr/include/libpng12 -I/usr/include/python2.6 -c
src/helpers.cpp -o build/temp.linux-x86_64-2.6/src/helpers.o -pthread -
O3
In file included from /disk01/data/davidsj2/wxPython-src-2.9.3.1/
include/wx/defs.h:28,
                  from /disk01/data/davidsj2/wxPython-src-2.9.3.1/
include/wx/wx.h:15,
                  from include/wx/wxPython/wxPython_int.h:35,
                  from src/helpers.cpp:17:
/disk01/data/davidsj2/wxPython-src-2.9.3.1/include/wx/platform.h:
181:22: error: wx/setup.h: No such file or directory

------------------------------------------------RPM
ISSUES--------------------------------------------------------------
So, if I try to build from the source RPM using the following:
/disk01/data/davidsj2/rpmbuild> rpmbuild --rebuild --define "_topdir /
disk01/data/davidsj2/rpmbuild" wxPython2.9-2.9.3.1-1.src.rpm

The build spins right along until we get to:
g++ -o wxrc wxrc_wxrc.o -L/disk01/data/davidsj2/rpmbuild/BUILD/
wxPython-src-2.9.3.1/bld/lib -pthread -lwx_baseu_xml-2.9 -
lwx_baseu-2.9 -lwxregexu-2.9 -lwxexpat-2.9 -pthread -Wl,--
version-script,/disk01/data/davidsj2/rpmbuild/BUILD/wxPython-
src-2.9.3.1/bld/version-script -lz -ldl -lm -lz -ldl -lm
make[1]: Leaving directory `/disk01/data/davidsj2/rpmbuild/BUILD/
wxPython-src-2.9.3.1/bld/utils/wxrc'
+ make -C contrib/src/gizmos
make: *** contrib/src/gizmos: No such file or directory. Stop.
error: Bad exit status from /var/tmp/rpm-tmp.o9e6ua (%build)

I'm not too surprised, that .spec file hasn't been tested in a long time. Based on the above it probably hasn't been updated since 2.8. If you get it working then feel free to send me patches, but you may have more luck getting the other build working since it has at least been used with 2.9 before.

···

On 4/10/12 9:31 AM, Mears wrote:

--
Robin Dunn
Software Craftsman

Did you try with --wxpy_installdir? You may need both, or perhaps just --prefix and --wxpy_installdir. For example, here is what we do in the script used to build the OSX installer:

     $PYTHON -u ./build-wxpython.py \
  $PYUNICODEOPT \
  --mac_universal_binary $COCOA \
  --build_dir=$BUILDROOT \
  --install \
  --prefix=$PREFIX \
  --installdir=$INSTALLROOT \
         --wxpy_installdir=$INSTALLROOT$PREFIX

The $INSTALLROOT value is where we build the temporary tree used to build the installer, and the files will be installed to $PREFIX on the target system. Since you're wanting to do a final install to a non-standard location then using --prefix and --wx-py_installdir set to some PREFIX value will probably take care of it.

···

On 4/10/12 1:47 PM, Mears wrote:

Ok, I lied. I could not get the build script to work with sudo. It
appeared to finish after setting the CPATH multiple times, but it
didn't actually work. I then decided to try and "install" as myself
in a temp directory:
python build-wxpython.py --build_dir=../bld --install --installdir=/
disk01/data/davidsj2/temp --install

This is what happens:

**** /usr/bin/python -u ./setup.py install UNICODE=1 BUILD_BASE=build
WX_CONFIG="/disk01/data/davidsj2/temp/usr/local/bin/wx-config --
prefix=/disk01/data/davidsj2/temp/usr/local" --record
installed_files.txt
WARNING: WXWIN not set in environment. Assuming '..'
Preparing CORE...
Preparing STC...
Preparing GLCANVAS...
Preparing GIZMOS...
running install
running build
running build_py
running install_lib
running install_data
copying src/wx.pth -> /usr/lib/python2.6/site-packages/
error: could not delete '/usr/lib/python2.6/site-packages/wx.pth':
Permission denied
ERROR: failed installing wxPython.

So even though I specified installdir, it tried to update site-
packages.

--
Robin Dunn
Software Craftsman

Ok, need to resurrect this. I hopped over to Windows for a bit, but
need to get this working now. I'm not trying to install to a non-
standard location (at least not yet). I did manage to get a bit
closer, using:
sudo ./build-wxpython.py --build_dir=../bld --install --prefix=/usr

It completely builds and more or less installs, except for creating
the pth file:

running install_data
running install_egg_info
Removing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
wxPython-2.9.3.1-py2.6.egg-info
Writing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
wxPython-2.9.3.1-py2.6.egg-info
warning: wx_install: path file '/usr/lib64/python2.6/site-packages/
wx-2.9.3-gtk2.pth' not created
package init file 'wx/lib/pubsub/pubsub2/__init__.py' not found (or
not a regular file)
package init file 'wx/tools/XRCed/plugins/__init__.py' not found (or
not a regular file)
writing list of installed files to 'installed_files.txt'
**** /usr/bin/python -u /disk01/data/davidsj2/wxPython-src-2.9.3.1/
wxPython/distrib/makemo.py
------------ BUILD FINISHED ------------

Any idea why that's failing?

···

On Apr 10, 4:49 pm, Robin Dunn <ro...@alldunn.com> wrote:

On 4/10/12 1:47 PM, Mears wrote:

> Ok, I lied. I could not get the build script to work with sudo. It
> appeared to finish after setting the CPATH multiple times, but it
> didn't actually work. I then decided to try and "install" as myself
> in a temp directory:
> python build-wxpython.py --build_dir=../bld --install --installdir=/
> disk01/data/davidsj2/temp --install

> This is what happens:

> **** /usr/bin/python -u ./setup.py install UNICODE=1 BUILD_BASE=build
> WX_CONFIG="/disk01/data/davidsj2/temp/usr/local/bin/wx-config --
> prefix=/disk01/data/davidsj2/temp/usr/local" --record
> installed_files.txt
> WARNING: WXWIN not set in environment. Assuming '..'
> Preparing CORE...
> Preparing STC...
> Preparing GLCANVAS...
> Preparing GIZMOS...
> running install
> running build
> running build_py
> running install_lib
> running install_data
> copying src/wx.pth -> /usr/lib/python2.6/site-packages/
> error: could not delete '/usr/lib/python2.6/site-packages/wx.pth':
> Permission denied
> ERROR: failed installing wxPython.

> So even though I specified installdir, it tried to update site-
> packages.

Did you try with --wxpy_installdir? You may need both, or perhaps just
--prefix and --wxpy_installdir. For example, here is what we do in the
script used to build the OSX installer:

 $PYTHON \-u \./build\-wxpython\.py \\
    $PYUNICODEOPT \\
    \-\-mac\_universal\_binary $COCOA \\
    \-\-build\_dir=$BUILDROOT \\
    \-\-install \\
    \-\-prefix=$PREFIX \\
    \-\-installdir=$INSTALLROOT \\
     \-\-wxpy\_installdir=$INSTALLROOT$PREFIX

The $INSTALLROOT value is where we build the temporary tree used to
build the installer, and the files will be installed to $PREFIX on the
target system. Since you're wanting to do a final install to a
non-standard location then using --prefix and --wx-py_installdir set to
some PREFIX value will probably take care of it.

--
Robin Dunn
Software Craftsmanhttp://wxPython.org

It isn't. The wx_install class replaces the default distutils install, and does nothing except turn off the flag that controls whether a .pth file will be created. What you are seeing is the results of distutils checking that flag and reporting that it isn't going to create the file. (wxPython makes its own.) See wx_install in config.py

···

On 5/31/12 4:09 PM, Mears wrote:

Ok, need to resurrect this. I hopped over to Windows for a bit, but
need to get this working now. I'm not trying to install to a non-
standard location (at least not yet). I did manage to get a bit
closer, using:
sudo ./build-wxpython.py --build_dir=../bld --install --prefix=/usr

It completely builds and more or less installs, except for creating
the pth file:

running install_data
running install_egg_info
Removing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
wxPython-2.9.3.1-py2.6.egg-info
Writing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
wxPython-2.9.3.1-py2.6.egg-info
warning: wx_install: path file '/usr/lib64/python2.6/site-packages/
wx-2.9.3-gtk2.pth' not created
package init file 'wx/lib/pubsub/pubsub2/__init__.py' not found (or
not a regular file)
package init file 'wx/tools/XRCed/plugins/__init__.py' not found (or
not a regular file)
writing list of installed files to 'installed_files.txt'
**** /usr/bin/python -u /disk01/data/davidsj2/wxPython-src-2.9.3.1/
wxPython/distrib/makemo.py
------------ BUILD FINISHED ------------

Any idea why that's failing?

--
Robin Dunn
Software Craftsman

Except no .pth file was added to site-packages. Under /usr/lib64/
python2.6/site-packages, only wx-2.9.3-gtk2 was added. To get the pth
so I can just "import wx", do I have to set INSTALL_MULTIVERSION?

···

On May 31, 5:39 pm, Robin Dunn <ro...@alldunn.com> wrote:

On 5/31/12 4:09 PM, Mears wrote:

> Ok, need to resurrect this. I hopped over to Windows for a bit, but
> need to get this working now. I'm not trying to install to a non-
> standard location (at least not yet). I did manage to get a bit
> closer, using:
> sudo ./build-wxpython.py --build_dir=../bld --install --prefix=/usr

> It completely builds and more or less installs, except for creating
> the pth file:

> running install_data
> running install_egg_info
> Removing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
> wxPython-2.9.3.1-py2.6.egg-info
> Writing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
> wxPython-2.9.3.1-py2.6.egg-info
> warning: wx_install: path file '/usr/lib64/python2.6/site-packages/
> wx-2.9.3-gtk2.pth' not created
> package init file 'wx/lib/pubsub/pubsub2/__init__.py' not found (or
> not a regular file)
> package init file 'wx/tools/XRCed/plugins/__init__.py' not found (or
> not a regular file)
> writing list of installed files to 'installed_files.txt'
> **** /usr/bin/python -u /disk01/data/davidsj2/wxPython-src-2.9.3.1/
> wxPython/distrib/makemo.py
> ------------ BUILD FINISHED ------------

> Any idea why that's failing?

It isn't. The wx_install class replaces the default distutils install,
and does nothing except turn off the flag that controls whether a .pth
file will be created. What you are seeing is the results of distutils
checking that flag and reporting that it isn't going to create the file.
(wxPython makes its own.) See wx_install in config.py

--
Robin Dunn
Software Craftsmanhttp://wxPython.org

Aha! It is creating the file, but it's getting copied to /usr/lib/
python2.6 whereas wx-2.9.3-gtk2 is installed to /usr/lib64/python2.6.
[davidsj2@scts01] ~ > ls /usr/lib64/python2.6/site-packages | grep -i
wx
wx-2.9.3-gtk2
[davidsj2@scts01] ~ > ls /usr/lib/python2.6/site-packages | grep -i wx
wx.pth
wxPython_common-2.9.3.1-py2.6.egg-info
wxversion.py
wxversion.pyc
[davidsj2@scts01] ~ > cat /usr/lib/python2.6/site-packages/wx.pth
wx-2.9.3-gtk2

Any ideas? Obviously, I could hack it, but I want to get the build
script working.

···

On May 31, 6:25 pm, Mears <joshuadavid...@gmail.com> wrote:

Except no .pth file was added to site-packages. Under /usr/lib64/
python2.6/site-packages, only wx-2.9.3-gtk2 was added. To get the pth
so I can just "import wx", do I have to set INSTALL_MULTIVERSION?

On May 31, 5:39 pm, Robin Dunn <ro...@alldunn.com> wrote:

> On 5/31/12 4:09 PM, Mears wrote:

> > Ok, need to resurrect this. I hopped over to Windows for a bit, but
> > need to get this working now. I'm not trying to install to a non-
> > standard location (at least not yet). I did manage to get a bit
> > closer, using:
> > sudo ./build-wxpython.py --build_dir=../bld --install --prefix=/usr

> > It completely builds and more or less installs, except for creating
> > the pth file:

> > running install_data
> > running install_egg_info
> > Removing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
> > wxPython-2.9.3.1-py2.6.egg-info
> > Writing /usr/lib64/python2.6/site-packages/wx-2.9.3-gtk2/
> > wxPython-2.9.3.1-py2.6.egg-info
> > warning: wx_install: path file '/usr/lib64/python2.6/site-packages/
> > wx-2.9.3-gtk2.pth' not created
> > package init file 'wx/lib/pubsub/pubsub2/__init__.py' not found (or
> > not a regular file)
> > package init file 'wx/tools/XRCed/plugins/__init__.py' not found (or
> > not a regular file)
> > writing list of installed files to 'installed_files.txt'
> > **** /usr/bin/python -u /disk01/data/davidsj2/wxPython-src-2.9.3.1/
> > wxPython/distrib/makemo.py
> > ------------ BUILD FINISHED ------------

> > Any idea why that's failing?

> It isn't. The wx_install class replaces the default distutils install,
> and does nothing except turn off the flag that controls whether a .pth
> file will be created. What you are seeing is the results of distutils
> checking that flag and reporting that it isn't going to create the file.
> (wxPython makes its own.) See wx_install in config.py

> --
> Robin Dunn
> Software Craftsmanhttp://wxPython.org

It is probably happening because the .pth file is being installed as part of the wxPython-common setup, and since it has no binary extensions those files are put in /usr/lib. Meanwhile the main wxPython setup does have binary extensions and are 64-bit, so they are being put in /usr/lib64.

Try adding ('', ['src/wx.pth']) to DATA_FILES so it will be installed as part of the wxPython setup() call.

···

On 5/31/12 5:46 PM, Mears wrote:

Aha! It is creating the file, but it's getting copied to /usr/lib/
python2.6 whereas wx-2.9.3-gtk2 is installed to /usr/lib64/python2.6.
[davidsj2@scts01] ~> ls /usr/lib64/python2.6/site-packages | grep -i
wx
wx-2.9.3-gtk2
[davidsj2@scts01] ~> ls /usr/lib/python2.6/site-packages | grep -i wx
wx.pth
wxPython_common-2.9.3.1-py2.6.egg-info
wxversion.py
wxversion.pyc
[davidsj2@scts01] ~> cat /usr/lib/python2.6/site-packages/wx.pth
wx-2.9.3-gtk2

Any ideas? Obviously, I could hack it, but I want to get the build
script working.

--
Robin Dunn
Software Craftsman

Adding:
DATA_FILES = [('..', ['src/wx.pth'])]
to config.py worked. '.' dumps wx.pth in /usr/lib64/python2.6/site-
packages/wx-2.9.3-gtk2/ instead of under site-packages. I tried
using --extra_setup, but couldn't get the string to parse correctly.

Is there any way to pass that in via command line? I tried

···

On Jun 1, 11:29 am, Robin Dunn <ro...@alldunn.com> wrote:

On 5/31/12 5:46 PM, Mears wrote:

> Aha! It is creating the file, but it's getting copied to /usr/lib/
> python2.6 whereas wx-2.9.3-gtk2 is installed to /usr/lib64/python2.6.
> [davidsj2@scts01] ~> ls /usr/lib64/python2.6/site-packages | grep -i
> wx
> wx-2.9.3-gtk2
> [davidsj2@scts01] ~> ls /usr/lib/python2.6/site-packages | grep -i wx
> wx.pth
> wxPython_common-2.9.3.1-py2.6.egg-info
> wxversion.py
> wxversion.pyc
> [davidsj2@scts01] ~> cat /usr/lib/python2.6/site-packages/wx.pth
> wx-2.9.3-gtk2

> Any ideas? Obviously, I could hack it, but I want to get the build
> script working.

It is probably happening because the .pth file is being installed as
part of the wxPython-common setup, and since it has no binary extensions
those files are put in /usr/lib. Meanwhile the main wxPython setup does
have binary extensions and are 64-bit, so they are being put in
/usr/lib64.

Try adding ('', ['src/wx.pth']) to DATA_FILES so it will be installed as
part of the wxPython setup() call.

--
Robin Dunn
Software Craftsmanhttp://wxPython.org