more build and distrib stuff

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_2_BRANCH@7428 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2000-05-19 02:48:17 +00:00
parent e36ee5f7aa
commit a61639123c
4 changed files with 92 additions and 62 deletions

View File

@@ -285,10 +285,9 @@ class BuildConfig:
'`$(WXCONFIG) --cflags` -I$(PYINCLUDE) -I$(EXECINCLUDE) '\
'-I$(WXPSRCDIR)'
self.LFLAGS = '-L$(WXPSRCDIR) `$(WXCONFIG) --libs`'
self.LIBS = '-l$(HELPERLIB)'
self.RMCMD = '-rm -f '
self.WXCONFIG = 'wx-config'
self.USE_SONAME = '0'
# **** What to do when I start supporting Motif, etc.???
self.GENCODEDIR = 'gtk'
@@ -712,7 +711,7 @@ MODULE = %(MODULE)s
SWIGFLAGS = %(SWIGFLAGS)s %(SWIGTOOLKITFLAG)s %(OTHERSWIGFLAGS)s
CFLAGS = %(CFLAGS)s $(OPT) %(OTHERCFLAGS)s
LFLAGS = %(LFLAGS)s %(OTHERLFLAGS)s
LIBS = %(LIBS)s %(OTHERLIBS)s
PYVERSION = %(PYVERSION)s
PYPREFIX = %(PYPREFIX)s
EXECPREFIX = %(EXECPREFIX)s
@@ -753,6 +752,13 @@ ifeq ($(WXP_USE_THREAD), 1)
THREAD=-DWXP_USE_THREAD
endif
USE_SONAME = %(USE_SONAME)s
ifeq ($(USE_SONAME), 1)
LIBS = -l$(HELPERLIB) %(OTHERLIBS)s
else
LIBS = $(WXPSRCDIR)/lib$(HELPERLIB)$(SO) %(OTHERLIBS)s
endif
#----------------------------------------------------------------------
%(DEFAULTRULE)s %(OTHERTARGETS)s

View File

@@ -12,34 +12,51 @@ if [ -z $1 ]; then
fi
if [ ! -d wxPython ]; then
echo "Please run this script from the directory containing the wxPython directory."
echo "Please run this script from the root wxPython directory."
exit 1
fi
cp $WXWIN/docs/gpl.txt wxPython
cp $WXWIN/docs/lgpl.txt wxPython
cp $WXWIN/docs/licence.txt wxPython
cp $WXWIN/docs/licendoc.txt wxPython
cp $WXWIN/docs/preamble.txt wxPython
mkdir _distrib_tgz
mkdir _distrib_tgz/wxPython-$1
rm -f wxPython/distrib/filelist
for x in `cat wxPython/distrib/wxPython.rsp`; do
ls $x >> wxPython/distrib/filelist
# Copy license files
cp $WXWIN/docs/gpl.txt _distrib_tgz/wxPython-$1
cp $WXWIN/docs/lgpl.txt _distrib_tgz/wxPython-$1
cp $WXWIN/docs/licence.txt _distrib_tgz/wxPython-$1
cp $WXWIN/docs/licendoc.txt _distrib_tgz/wxPython-$1
cp $WXWIN/docs/preamble.txt _distrib_tgz/wxPython-$1
# Copy files from the live dirs
# first, get a list of files
for x in `cat distrib/wxPython.rsp`; do
ls $x >> _distrib_tgz/filelist
done
# and make a tar file containing those files
tar cf _distrib_tgz/dist-temp.tar -T _distrib_tgz/filelist
tar cf wxPython/distrib/dist-temp.tar -T wxPython/distrib/filelist
cd wxPython/distrib
tar xf dist-temp.tar
rm dist-temp.tar
mv wxPython wxPython-$1
# now untar it in the right place
cd _distrib_tgz/wxPython-$1
tar xf ../dist-temp.tar
cd ..
# update a few things
rm wxPython-$1/src/gtk/helpers.cpp
touch `find wxPython-$1 -name "*.cpp"`
touch `find wxPython-$1 -name "*.py"`
# Finally, make the finished tar file
tar cvf ../distrib/wxPython-$1.tar wxPython-$1
gzip ../distrib/wxPython-$1.tar
cd ..
rm -rf _distrib_tgz
tar cvf wxPython-$1.tar wxPython-$1
gzip wxPython-$1.tar
rm -rf wxPython-$1

View File

@@ -1,5 +1,5 @@
%define pref /usr
%define ver 2.1.15
%define ver 2.1.16
%define rpmver 1
Summary: Cross platform GUI toolkit for use with the Python language.
@@ -12,7 +12,7 @@ Source: wxPython-%{ver}.tar.gz
Packager: Robin Dunn <robin@alldunn.com>
URL:http://alldunn.com/wxPython/index.html
Vendor: Total Control Software
Requires: python >= 1.5.1
Requires: python >= 1.5.2
##BuildRoot: /tmp/wxPython-build
##Prefix: /usr/lib/python1.5/site-packages
@@ -24,6 +24,17 @@ wxWindows C++ GUI library. wxPython provides a large variety of
window types and controls, all imlemented with a native look and
feel (and runtime speed) on the platforms it is supported on.
%package gl
Summary: Cross platform GUI toolkit for use with the Python language, OpenGL addon.
Group: Development/Languages/Python
Requires: wxPython
%description gl
OpenGL add on for wxPython.
#----------------------------------------------------------------------
%prep
%setup
@@ -31,10 +42,6 @@ feel (and runtime speed) on the platforms it is supported on.
%build
cd src
python ../distrib/build.py -b WXPSRCDIR=$PWD
cd ../modules/html
python ../../distrib/build.py -b WXPSRCDIR=../../src
cd ../utils
python ../../distrib/build.py -b WXPSRCDIR=../../src
cd ../ogl
python ../../distrib/build.py -b WXPSRCDIR=../../src
cd ../stc
@@ -44,13 +51,11 @@ if [ ! -z $NOGLCANVAS ]; then
python ../../distrib/build.py -b WXPSRCDIR=../../src
fi
#----------------------------------------------------------------------
%install
cd src
python ../distrib/build.py -i
cd ../modules/html
python ../../distrib/build.py -i
cd ../utils
python ../../distrib/build.py -i
cd ../ogl
python ../../distrib/build.py -i
cd ../stc
@@ -60,6 +65,7 @@ if [ ! -z $NOGLCANVAS ]; then
python ../../distrib/build.py -i
fi
#----------------------------------------------------------------------
%post
/sbin/ldconfig
@@ -67,10 +73,24 @@ fi
%postun
/sbin/ldconfig
#----------------------------------------------------------------------
%files
%doc BUILD.txt CHANGES.txt README.txt gpl.txt lgpl.txt licence.txt licendoc.txt preamble.txt
%{pref}/lib/libwxPyHelpers.so
%{pref}/lib/python1.5/site-packages/wxPython
%{pref}/lib/python1.5/site-packages/wxPython/*.py
%{pref}/lib/python1.5/site-packages/wxPython/*.py?
%{pref}/lib/python1.5/site-packages/wxPython/lib
%{pref}/lib/python1.5/site-packages/wxPython/wxcmodule.so
%{pref}/lib/python1.5/site-packages/wxPython/oglcmodule.so
%{pref}/lib/python1.5/site-packages/wxPython/stc_cmodule.so
%files gl
%{pref}/lib/python1.5/site-packages/wxPython/glcanvascmodule.so

View File

@@ -38,10 +38,10 @@ __version__.py: ../distrib/build.py build.cfg
else:
DEFAULTRULE = 'default: $(GENCODEDIR) lib$(HELPERLIB)$(SO) $(TARGET) $(BUILDDIR)/$(TARGET) bldpycfiles'
OTHERINSTALLTARGETS = 'installLibDemo installHelpers '
OTHERUNINSTALLTARGETS = 'uninstallLibDemo uninstallHelpers '
OTHERINSTALLTARGETS = 'installLib installHelpers '
OTHERUNINSTALLTARGETS = 'uninstallLib uninstallHelpers '
OTHERLFLAGS = '-L. '
#OTHERLFLAGS = '-L. '
OTHERRULES = """
lib$(HELPERLIB)$(SO) : helpers.o libpy.o
$(LDSHARED) helpers.o libpy.o $(LFLAGS) -o $@
@@ -60,35 +60,23 @@ $(HELPERLIBDIR)/lib$(HELPERLIB)$(SO) : lib$(HELPERLIB)$(SO)
@echo ---------------------------------------------------------
installLibDemo:
@if [ "$(TARGETDIR)" != ".." -a "$(TARGETDIR)" != "$(WXWIN)/utils/wxPython" ]; then \\
installLib:
mkdir $(TARGETDIR)/lib; \\
mkdir $(TARGETDIR)/lib/sizers; \\
mkdir $(TARGETDIR)/lib/editor; \\
mkdir $(TARGETDIR)/demo; \\
mkdir $(TARGETDIR)/demo/bitmaps; \\
mkdir $(TARGETDIR)/demo/data; \\
cp ../lib/*.py $(TARGETDIR)/lib; \\
cp ../lib/sizers/*.py $(TARGETDIR)/lib/sizers; \\
cp ../lib/editor/*.py $(TARGETDIR)/lib/editor; \\
cp ../demo/*.py $(TARGETDIR)/demo; \\
cp ../lib/*.txt $(TARGETDIR)/lib; \\
cp ../lib/sizers/*.txt $(TARGETDIR)/lib/sizers; \\
cp ../lib/editor/*.txt $(TARGETDIR)/lib/editor; \\
cp ../demo/*.txt $(TARGETDIR)/demo; \\
cp ../demo/bitmaps/* $(TARGETDIR)/demo/bitmaps; \\
cp ../demo/data/* $(TARGETDIR)/demo/data; \\
cp ../wxPython/lib/*.py $(TARGETDIR)/lib; \\
cp ../wxPython/lib/sizers/*.py $(TARGETDIR)/lib/sizers; \\
cp ../wxPython/lib/editor/*.py $(TARGETDIR)/lib/editor; \\
cp ../wxPython/lib/*.txt $(TARGETDIR)/lib; \\
cp ../wxPython/lib/sizers/*.txt $(TARGETDIR)/lib/sizers;\\
cp ../wxPython/lib/editor/*.txt $(TARGETDIR)/lib/editor;\\
$(EXECPREFIX)/bin/python $(PYLIB)/compileall.py $(TARGETDIR); \\
$(EXECPREFIX)/bin/python -O $(PYLIB)/compileall.py $(TARGETDIR); \\
fi
$(EXECPREFIX)/bin/python -O $(PYLIB)/compileall.py $(TARGETDIR);
uninstallLibDemo:
@if [ "$(TARGETDIR)" != ".." -a "$(TARGETDIR)" != "$(WXWIN)/utils/wxPython" ]; then \\
rm -rf $(TARGETDIR)/lib; \\
rm -rf $(TARGETDIR)/demo; \\
fi
uninstallLib:
rm -rf $(TARGETDIR)/lib;
uninstallHelpers:
@@ -104,13 +92,12 @@ __version__.py: ../distrib/build.py build.cfg
dist: tgz rpm
tgz:
cd ../..; wxPython/distrib/maketgz $(VERSION)
cd ..; distrib/maketgz $(VERSION)
rpm:
cd ../distrib; ./makerpm $(VERSION)
"""