This commit was manufactured by cvs2svn to create tag 'wxPy_2_3_4_1'.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/tags/wxPy_2_3_4_1@18324 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Bryan Petty
2002-12-18 06:48:23 +00:00
parent bf4a027ddb
commit ea5a206d1d
1457 changed files with 66856 additions and 42992 deletions

View File

@@ -0,0 +1,91 @@
README for wxPythonSrc-*.tar.gz
-------------------------------
Prior to version 2.3.3 of wxPython I had always made my Linux/Unix
binaries based on the released binary of wxGTK and wxGTK-gl. This
imposed a few restrictions and so starting with 2.3.3 I have decided
to do a combined binary that inlcudes wxGTK as well as wxPython. This
allows me a bit more flexibility and is consistent with how the
Windows and Mac OS X binaries are built.
If you are reading this file then you are probably interested in
building your own copy of wxPython from the sources contained in this
archive. If you wish to use the released wxGTK binary as has been
done in the past then you can still follow the old build directions in
wxPython/BUILD.unix.txt. If you are building for Windows or Mac OS X
then you should look at wxPython/BUILD.win32.txt or
wxPython/BUILD.osx.txt respectivly. In all these cases you should use
the IN_CVS_TREE=1 flag since this archive is really just a modified
CVS snapshot.
If, on the other hand, you would like to build Linux/Unix binaries
with a private copy of wxGTK like what I am now distributing then
you'll want to follow the instructions in this file.
Clear as mud? Good. Let's get started.
1. We'll be making a private copy of wxGTK so it doesn't conflict with
one used by wxGTK C++ apps that expect to have the default binary
installed from RPM or whatever. I put it in /usr/lib/wxPython, but
you can use whatever you like. I'll just set a variable to our wx
prefix to reference later:
export WXPREF=/usr/lib/wxPython
2. Make a build directory and configure wxGTK.
cd wxPythonGTK-2.3.3 # or whatever the top-level dir is
mkdir build
cd build
../configure --with-gtk \
--prefix=$WXPREF \
--enable-rpath=$WXPREF/lib \
--with-opengl \
--enable-geometry \
--enable-optimise \
--enable-debug_flag \
You may want to use --enable-debug instead of --enable-optimise if
you need to run though a debugger and want full debugging symbols.
if you want to use the image and zlib libraries included with
wxWindows instead of those already installed on your system, (for
example, to reduce dependencies on 3rd party libraries) then you
can add these flags to the configure command:
--with-libjpeg=builtin \
--with-libpng=builtin \
--with-libtiff=builtin \
--with-zlib=builtin
3. Build and install wxGTK. (You may need to be root for the last
step, depending on where your WXPREF is.)
make
cd ../locale
make allmo
cd ../build
make install
4. Build and install wxPython. If you want to use a different version
of Python than is found by default on the PATH then specify the
whole pathname in these steps. The version of Python that runs
setup.py is the version wxPython will be built and installed for.
(You will need to be root for the install step unless your Python
is not in a system location.)
cd ../wxPython
python setup.py \
IN_CVS_TREE=1 WX_CONFIG=$WXPREF/bin/wx-config \
build install
5. That's all!
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

View File

@@ -0,0 +1,16 @@
wxPythonDocs
------------
The wxWindows docs can now be viewed on non-Win32 platforms with a
nice viewer modeled after the MS HTMLHelp viewer. Simply execute the
viewdocs.py script located in this directory and you're all set.
(You'll need to first have wxPython installed and accessible via the
PYTHONPATH.)
You can also add other HTML books to be displayed by the viewer simply
by dropping their .zip file here and tweaking viewdocs.py. The zip
file just needs to contain a .hhp file that defines the contents of
the book. See the docs on wxHtmlHelpController for details.
If you'd still ike to view these docs in your regular browser you can
simply unzip each of the books into their own directory.

View File

@@ -0,0 +1,51 @@
"""
Walk a directory tree and output a filename list suitable for use
in an RPM spec.
Usage: genfilelist.py [-r] build_root filespec(s)
"""
import sys, os, glob
def walktree(names, buildroot, recurse):
for name in names:
isdir = os.path.isdir(name)
printfilename(name, buildroot, isdir)
if isdir and recurse:
walktree([os.path.join(name, x) for x in os.listdir(name)], buildroot, recurse)
def printfilename(name, buildroot, isdir):
s = os.lstat(name)
realname = name[len(buildroot):]
if isdir:
fmt = "%%dir %%attr(%o, root, root) %s"
else:
fmt = "%%attr(%o, root, root) %s"
print fmt % (s.st_mode & 0777, realname)
def main(args):
if args[0] == '-r':
recurse = 1
args = args[1:]
else:
recurse = 0
if len(args) < 2:
print __str__
sys.exit(1)
buildroot = args[0]
for arg in args[1:]:
if arg[0] == '/':
arg = arg[1:]
walktree(glob.glob(os.path.join(buildroot, arg)), buildroot, recurse)
if __name__ == "__main__":
main(sys.argv[1:])

View File

@@ -1,2 +1,2 @@
You will be guided through the steps necessary to install wxPython 2.3.3pre (including wxMac) for MachoPython 2.2.x on Mac OS X 10.1 or later.
You will be guided through the steps necessary to install wxPython 2.3.4.1 (including wxMac) for MachoPython 2.2.x on Mac OS X 10.1 or later.

View File

@@ -7,7 +7,7 @@ will be created.
"""
import sys, os, string
import sys, os, string, time
KEEP_TEMPS = 0
ISCC = r"%s\InnoSetup2Ex\ISCC.exe %s"
@@ -32,21 +32,23 @@ OutputDir = dist
WizardStyle = modern
UninstallStyle = modern
DisableStartupPrompt = true
CompressLevel = 9
Compression = bzip
DirExistsWarning = no
DisableReadyMemo = true
DisableReadyPage = true
;;DisableDirPage = true
DisableProgramGroupPage = true
DisableProgramGroupPage = no
DisableAppendDir = true
UsePreviousAppDir = no
UsePreviousGroup = no
UsePreviousGroup = yes
UninstallFilesDir = {app}\wxPython
AppPublisherURL = http://wxPython.org/
LicenseFile = licence\licence.txt
CodeFile = %(IFSFILE)s
;; WizardDebug = yes
;;------------------------------------------------------------
;;[Dirs]
@@ -142,6 +144,7 @@ Source: "wxPython\tools\*.py"; DestDir: "{app}\wxPython\tools"; Com
Source: "wxPython\tools\XRCed\CHANGES"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
Source: "wxPython\tools\XRCed\TODO"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
Source: "wxPython\tools\XRCed\README"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
Source: "wxPython\tools\XRCed\sawfishrc"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
Source: "wxPython\tools\XRCed\*.py"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
Source: "wxPython\tools\XRCed\*.xrc"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
Source: "wxPython\tools\XRCed\*.ico"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
@@ -269,6 +272,7 @@ var
PythonDir : String;
InstallDir : String;
function InitializeSetup(): Boolean;
begin
if not RegQueryStringValue(HKEY_LOCAL_MACHINE,
@@ -279,7 +283,8 @@ begin
'Software\Python\PythonCore\%(PYTHONVER)s\InstallPath',
'', PythonDir) then begin
MsgBox('No installation of Python %(PYTHONVER)s found in registry.\nBe sure to enter a pathname that places wxPython\non the PYTHONPATH',
MsgBox('No installation of Python %(PYTHONVER)s found in registry.' + #13 +
'Be sure to enter a pathname that places wxPython on the PYTHONPATH',
mbConfirmation, MB_OK);
PythonDir := 'C:\Put a directory on PYTHONPATH here\';
end;
@@ -300,12 +305,34 @@ begin
Result := InstallDir;
end;
function NextButtonClick(CurPage: Integer): Boolean;
var
FileName: string;
ResultCode: Integer;
begin
Result := True;
if CurPage <> wpSelectDir then Exit;
FileName := WizardDirValue() + '\wxPython\unins000.exe';
if FileExists(FileName) then begin
ResultCode := MsgBox('A prior wxPython installation was found in this directory. It' + #13 +
'is recommended that it be uninstalled first.' + #13#13 +
'Should I do it?',
mbConfirmation, MB_YESNO);
if ResultCode = IDYES then begin
InstExec(FileName, '/SILENT', WizardDirValue()+'\wxPython', True, False, SW_SHOWNORMAL, ResultCode);
end;
end;
end;
begin
end.
"""
#----------------------------------------------------------------------
def find_DLLs():
@@ -370,6 +397,7 @@ def main():
os.system(ISCC % (os.environ['TOOLS'], ISSFILE))
if not KEEP_TEMPS:
time.sleep(1)
os.remove(ISSFILE)
os.remove(IFSFILE)

View File

@@ -23,13 +23,15 @@ rm -f `find _distrib_tgz/wxPython-$1 -name "*.pyc"`
rm -f `find _distrib_tgz/wxPython-$1 -name .cvsignore`
rm -f `find _distrib_tgz/wxPython-$1 -name core`
rm -f `find _distrib_tgz/wxPython-$1 -name wxPython`
rm -f `find _distrib_tgz/wxPython-$1 -name *.o`
rm -f `find _distrib_tgz/wxPython-$1 -name *.so`
rm -f `find _distrib_tgz/wxPython-$1 -name "*.o"`
rm -f `find _distrib_tgz/wxPython-$1 -name "*.so"`
rm -f `find _distrib_tgz/wxPython-$1 -name "*~"`
rm -f `find _distrib_tgz/wxPython-$1 -name ".#*"`
cd _distrib_tgz
tar cvf ../dist/wxPythonDemo-$1.tar wxPython-$1
gzip ../dist/wxPythonDemo-$1.tar
gzip -9 ../dist/wxPythonDemo-$1.tar
cd ..
rm -r _distrib_tgz

61
wxPython/distrib/makedocs Executable file
View File

@@ -0,0 +1,61 @@
#!/bin/bash
#----------------------------------------------------------------------
if [ -z $1 ]; then
echo "Please specify a version number on the command line."
exit 1
fi
if [ ! -d wxPython ]; then # TODO: make this test more robust
echo "Please run this script from the root wxPython directory."
exit 1
fi
# **** Make a directory to build up a distribution tree
mkdir _distrib_bld
mkdir _distrib_bld/wxPythonDocs-$1
cd _distrib_bld
mkdir wxPythonDocs-$1/wx
mkdir wxPythonDocs-$1/ogl
WXDIR=../..
# **** Build the docs using tex2rtf
cp $WXDIR/docs/latex/wx/*.gif wxPythonDocs-$1/wx
$WXDIR/utils/tex2rtf/src/tex2rtf $WXDIR/docs/latex/wx/manual.tex wxPythonDocs-$1/wx/wx.htm -twice -html
cp wxPythonDocs-$1/wx/wx.htm wxPythonDocs-$1/wx/index.htm
cp $WXDIR/contrib/docs/latex/ogl/*.gif wxPythonDocs-$1/ogl
cp $WXDIR/contrib/docs/latex/ogl/*.bmp wxPythonDocs-$1/ogl
$WXDIR/utils/tex2rtf/src/tex2rtf $WXDIR/contrib/docs/latex/ogl/ogl.tex wxPythonDocs-$1/ogl/ogl.htm -twice -html
cp wxPythonDocs-$1/ogl/ogl.htm wxPythonDocs-$1/ogl/index.htm
# **** zip the docs into "books"
cd wxPythonDocs-$1
cd wx
zip ../wx.zip *
cd ..
rm -r wx
cd ogl
zip ../ogl.zip *
cd ..
rm -r ogl
cd ..
cp ../distrib/viewdocs.py wxPythonDocs-$1
cp ../distrib/README.viewdocs.txt wxPythonDocs-$1/README.txt
rm -f ../dist/wxPythonDocs-$1.tar.gz
tar cvf ../dist/wxPythonDocs-$1.tar wxPythonDocs-$1
gzip -9 ../dist/wxPythonDocs-$1.tar
# **** Cleanup
cd ..
rm -r _distrib_bld

View File

@@ -1,26 +0,0 @@
@echo off
rem **** Make a directory to build up a distribution tree
md _distrib_zip
md _distrib_zip\wxPython-%1
cd _distrib_zip
rem **** copy the docs into the tree
md wxPython-%1\docs
md wxPython-%1\docs\wx
md wxPython-%1\docs\ogl
copy %WXWIN%\docs\html\wx\*.* wxPython-%1\docs\wx
copy wxPython-%1\docs\wx\wx.htm wxPython-%1\docs\wx\index.htm
copy %WXWIN%\docs\html\ogl\*.* wxPython-%1\docs\ogl
copy wxPython-%1\docs\ogl\ogl.htm wxPython-%1\docs\ogl\index.htm
rem **** zip up the docs
rem zip -r ..\distrib\wxPython-docs-%1.zip wxPython-%1\docs
tar cvf ..\dist\wxPythonDocs-%1.tar wxPython-%1
gzip -9 ..\dist\wxPythonDocs-%1.tar
rem **** Cleanup
cd ..
del /sxzy _distrib_zip

View File

@@ -16,12 +16,11 @@ fi
distdir=`pwd`/dist
builddir=`pwd`/_build_rpm
rpmtop=${builddir}/rpmtop
cvsroot=:pserver:anoncvs@cvs.wxwindows.org:/home/wxcvs
cvsroot=:pserver:anoncvs@cvs.wxwindows.org:/pack/cvsroots/wxwindows
pythonbin=/usr/bin/python
port=GTK
lcport=gtk
tarname=wxPythonSrc
debug=0
#----------------------------------------------------------------------
@@ -40,7 +39,6 @@ function useage {
echo " skiprpm Don't build the RPM (but why?)"
echo " skipclean Don't do the cleanup at the end"
echo " speconly Do nothing but write the RPM spec file"
echo " debug Make a __WXDEBUG__ version"
echo " smp Add SMP=2 to the envivonment to speed wxGTK build"
}
@@ -70,7 +68,6 @@ function makespec {
cat ${spectemplate} \
| sed s:@PYTHON@:${python}:g \
| sed s:@PYVER@:${pyver}:g \
| sed s:@DEBUG@:${debug}:g \
| sed s:@PORT@:${port}:g \
| sed s:@LCPORT@:${lcport}:g \
| sed s:@TARNAME@:${tarname}:g \
@@ -88,7 +85,6 @@ for flag in $*; do
skiptar) skiptar=1 ;;
skiprpm) skiprpm=1 ;;
smp) export SMP=2 ;;
debug) debug=1 ;;
speconly) makespec; exit 0 ;;
*) echo "Unknown flag \"${flag}\""
@@ -172,6 +168,7 @@ cp ${distdir}/wxPython${port}.spec ${builddir}/${tarver}/wxPython${port}.spec
if [ -z "${skiptar}" ]; then
echo "*** Creating tarball..."
cp distrib/README.1st.txt ${builddir}/${tarver}
pushd ${builddir} > /dev/null
tar cvf ${distdir}/${tarver}.tar ${tarver} > /dev/null
echo "*** Compressing..."
@@ -189,7 +186,7 @@ fi
if [ -z "${skiprpm}" ]; then
echo "*** Building RPMs..."
cp ${distdir}/${tarver}.tar.gz ${rpmtop}/SOURCES
rpm -ba \
rpmbuild -ba \
--define "_topdir ${rpmtop}" \
--define "_tmppath ${builddir}" \
${distdir}/wxPython${port}.spec

25
wxPython/distrib/viewdocs.py Executable file
View File

@@ -0,0 +1,25 @@
#!/usr/bin/env python
#---------------------------------------------------------------------------
import sys, os
from wxPython.tools import helpviewer
# Figure out the path where this app is located
if __name__ == '__main__':
basePath = os.path.dirname(sys.argv[0])
else:
basePath = os.path.dirname(__file__)
# setup the args
args = ['',
'--cache='+basePath,
os.path.join(basePath, 'wx.zip'),
os.path.join(basePath, 'ogl.zip'),
]
# launch helpviewer
helpviewer.main(args)
#---------------------------------------------------------------------------

View File

@@ -1,7 +1,6 @@
%define pref %{_prefix}
%define python @PYTHON@
%define pyver @PYVER@
%define debug @DEBUG@
%define port @PORT@
%define lcport @LCPORT@
%define tarname @TARNAME@
@@ -9,21 +8,16 @@
%define ver2 @VER2@
%define release 1
%define wxpref %{pref}/lib/wxPython
%define name wxPython%{port}-py%{pyver}
# Should --enable-debug_flag be used in release builds?
# Using it defines __WXDEBUG__ and gives us runtime diagnostics
# that are turned into Python exceptions starting with 2.3.4.
%define debug_flag 1
%if %{debug}
%define name wxPython%{port}-py%{pyver}-dbg
%define othername wxPython%{port}-py%{pyver}
%else
%define name wxPython%{port}-py%{pyver}
%define othername wxPython%{port}-py%{pyver}-dbg
%endif
%if %{debug} || %{debug_flag}
%if %{debug_flag}
%define wxconfigname %{wxpref}/bin/wx%{lcport}d-%{ver2}-config
%else
%define wxconfigname %{wxpref}/bin/wx%{lcport}-%{ver2}-config
@@ -49,8 +43,6 @@ Provides: wx%{port} = %{version}
Provides: wxPython = %{version}
# They conflict with each other, so let them replace each other
Obsoletes: %{othername}
# old wxPython packages
Obsoletes: wxPython
@@ -65,13 +57,13 @@ This package is implemented using the %{port} port of wxWindows, and
includes the wx%{port} shared libs and etc.
%package devel
%package -n wxPython%{port}-devel
Summary: wxPython%{port} development files
Group: Development/Libraries
Requires: wxPython%{port} = %{version}
%description devel
%description -n wxPython%{port}-devel
This packages contains the headers and etc. for building apps or
Python extension modules that use the same wx%{port} shared libraries
that wxPython uses.
@@ -89,61 +81,53 @@ else
MAKE="make"
fi
WXDIR=`pwd`
mkdir build
cd build
# Configure, trying to reduce dependencies
../configure --with-%{lcport} \
# Configure, trying to reduce external dependencies
$WXDIR/configure --with-%{lcport} \
--prefix=%{wxpref} \
--disable-soname \
--enable-rpath=%{wxpref}/lib \
--with-opengl \
%if %{debug}
--enable-debug \
%else
--enable-geometry \
--enable-optimise \
%if %{debug_flag}
--enable-debug_flag \
%endif
%endif
--with-libjpeg=builtin \
--with-libpng=builtin \
--with-libtiff=builtin \
--with-zlib=builtin \
## --enable-debug_flag \
## --with-odbc \
# Build wxWindows
$MAKE
cd ../locale
cd $WXDIR/locale
make allmo
# ** Unfortunately we have to do a bit of installation here so wxPython
# can be built. Perhaps wx-config should be changed to be able to be
# used from the build dir, maybe with an --inplace flag... Move these
# three lines to %install if/when that happens.
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
cd ../build
make prefix=$RPM_BUILD_ROOT%{wxpref} install
# Now build wxPython
cd ../wxPython
cd $WXDIR/wxPython
%{python} setup.py \
IN_CVS_TREE=1 \
NO_SCRIPTS=1 \
WX_CONFIG="$RPM_BUILD_ROOT%{wxpref}/bin/wx-config --prefix=$RPM_BUILD_ROOT%{wxpref}" \
WX_CONFIG="$WXDIR/build/wx-config --inplace --prefix=$RPM_BUILD_ROOT%{wxpref}" \
build
#----------------------------------------------------------------
%install
%find_lang wxstd
cd wxPython
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
# install wxWindows
WXDIR=`pwd`
cd build
make prefix=$RPM_BUILD_ROOT%{wxpref} install
# install wxPython
cd $WXDIR/wxPython
%{python} setup.py \
IN_CVS_TREE=1 \
NO_SCRIPTS=1 \
@@ -152,11 +136,11 @@ cd wxPython
--root=$RPM_BUILD_ROOT
# Since I want this RPM to be as generic as possible I won't let
# distutils copy the scripts, since it will mangle the #! line
# to use the real python pathname. Since some distros install
# python 2.2 as python2 and others as python, then I can't let
# it do that otherwise the dependencies will be fouled up. Copy
# them manually instead:
# distutils copy the scripts since it will mangle the #! line to use
# the real python pathname. Since some distros install python 2.2 as
# python2 and others as python, then I can't let distutils do that
# otherwise the dependencies will be fouled up. Copy them manually
# instead, leaving the #!/bin/env line intact:
mkdir -p $RPM_BUILD_ROOT/usr/bin
for s in \
@@ -170,6 +154,29 @@ for s in \
done
# Generate the filelists. For some reason the %defattr below is still
# resulting in many (but not all) files not owned by root when just
# specifying directories and wildcards to be included in each package.
# So instead we'll build some explicit filelists here and use %attr on
# each entry.
cd $WXDIR
mkdir -p $RPM_BUILD_ROOT%{pref}/share/doc
GFL="%{python} wxPython/distrib/genfilelist.py"
$GFL $RPM_BUILD_ROOT %{pref} > FILELIST
$GFL -r $RPM_BUILD_ROOT %{pref}/bin >> FILELIST
$GFL $RPM_BUILD_ROOT %{pref}/lib >> FILELIST
$GFL -r $RPM_BUILD_ROOT %{pref}/lib/python%{pyver} >> FILELIST
$GFL -r $RPM_BUILD_ROOT %{pref}/share >> FILELIST
$GFL $RPM_BUILD_ROOT %{wxpref} >> FILELIST
$GFL $RPM_BUILD_ROOT %{wxpref}/lib >> FILELIST
$GFL $RPM_BUILD_ROOT "%{wxpref}/lib/libwx*" >> FILELIST
$GFL -r $RPM_BUILD_ROOT %{wxpref}/share >> FILELIST
$GFL $RPM_BUILD_ROOT %{wxpref}/include > DEVELLIST
$GFL -r $RPM_BUILD_ROOT %{wxpref}/include/wx >> DEVELLIST
$GFL -r $RPM_BUILD_ROOT %{wxpref}/lib/wx >> DEVELLIST
$GFL $RPM_BUILD_ROOT %{wxconfigname} >> DEVELLIST
$GFL $RPM_BUILD_ROOT %{wxpref}/bin/wx-config >> DEVELLIST
#----------------------------------------------------------------
@@ -178,37 +185,15 @@ done
#----------------------------------------------------------------
%post
/sbin/ldconfig
#----------------------------------------------------------------
%postun
/sbin/ldconfig
#----------------------------------------------------------------
%files
%doc docs/preamble.txt
%doc docs/licence.txt
%doc docs/readme.txt
%doc docs/changes.txt
%doc wxPython/README.txt
%doc wxPython/CHANGES.txt
%files -f FILELIST
%defattr(-,root,root)
%{wxpref}/lib/libwx*
%{pref}/lib/python*
%{wxpref}/share/
%{pref}/bin/*
%doc docs/preamble.txt docs/licence.txt docs/readme.txt docs/changes.txt
%doc wxPython/README.txt wxPython/CHANGES.txt
%files devel
%files -n wxPython%{port}-devel -f DEVELLIST
%defattr(-,root,root)
%{wxpref}/include/wx
%{wxpref}/lib/wx
%{wxconfigname}
%{wxpref}/bin/wx-config
#----------------------------------------------------------------