[Python-ogre-commit] SF.net SVN: python-ogre:[665] trunk/python-ogre
Brought to you by:
andy_miller,
roman_yakovenko
|
From: <mi...@us...> - 2008-07-22 09:50:58
|
Revision: 665
http://python-ogre.svn.sourceforge.net/python-ogre/?rev=665&view=rev
Author: mithro
Date: 2008-07-22 09:51:07 +0000 (Tue, 22 Jul 2008)
Log Message:
-----------
Fixed boost_python_index for non-deb builds.
Modified Paths:
--------------
trunk/python-ogre/boost/debian/rules
trunk/python-ogre/environment.py
Added Paths:
-----------
trunk/python-ogre/boost/Makefile
Added: trunk/python-ogre/boost/Makefile
===================================================================
--- trunk/python-ogre/boost/Makefile (rev 0)
+++ trunk/python-ogre/boost/Makefile 2008-07-22 09:51:07 UTC (rev 665)
@@ -0,0 +1,25 @@
+
+export GCC_VERSION=`gcc --version | head -1 | sed -e's/.*) \([0-9]\)\.\([0-9]\).*/\1\2/'`
+export PYTHON_VERSION=`python -V 2>&1 | sed -e's/Python \(2\.[45]\).*/\1/'`
+
+all: libs/python/src/indexing/indexing_slice.cpp libs/python/src/indexing/python_iterator.cpp
+ g++ $? \
+ -I . \
+ -I /usr/include/python${PYTHON_VERSION} \
+ -shared -Wl,-soname,libboost_python_index-gcc${GCC_VERSION}-1_34_1.so -o libboost_python_index-gcc${GCC_VERSION}-1_34_1.so -fPIC \
+ -lboost_python \
+ -lpython${PYTHON_VERSION}
+
+install:
+ mkdir -p ${PREFIX}/usr/lib
+ cp libboost_python_index-gcc${GCC_VERSION}-1_34_1.so ${PREFIX}/usr/lib
+ ln -sf /usr/lib/libboost_python_index-gcc${GCC_VERSION}-1_34_1.so ${PREFIX}/usr/lib/libboost_python_index.so
+
+ mkdir -p ${PREFIX}/usr/include
+ cp -rvf boost ${PREFIX}/usr/include
+ rm -rf `find ${PREFIX}/usr/include -name .svn -type d`
+
+clean:
+ rm *.so
+
+.PHONY: install clean
Modified: trunk/python-ogre/boost/debian/rules
===================================================================
--- trunk/python-ogre/boost/debian/rules 2008-07-22 04:45:24 UTC (rev 664)
+++ trunk/python-ogre/boost/debian/rules 2008-07-22 09:51:07 UTC (rev 665)
@@ -8,7 +8,9 @@
# Uncomment this to turn on verbose mode.
export DH_VERBOSE=1
+export DH_COMPAT=2
export GCC_VERSION=`gcc --version | head -1 | sed -e's/.*) \([0-9]\)\.\([0-9]\).*/\1\2/'`
+export PYTHON_VERSION=`python -V 2>&1 | sed -e's/Python \(2\.[45]\).*/\1/'`
# shared library versions, option 1
#version=2.0.5
@@ -23,25 +25,15 @@
configure-stamp:
dh_testdir
# Add here commands to configure the package.
-
+
touch configure-stamp
-
build: build-stamp
build-stamp: configure-stamp
dh_testdir
-
-
- # Add here commands to compile the package.
- g++ \
- ./libs/python/src/indexing/indexing_slice.cpp \
- ./libs/python/src/indexing/python_iterator.cpp \
- -I . \
- -I /usr/include/python2.5 \
- -shared -Wl,-soname,libboost_python_index-gcc${GCC_VERSION}-1_34_1.so -o libboost_python_index-gcc${GCC_VERSION}-1_34_1.so -fPIC \
- -lboost_python \
- -lpython2.5
-
+
+ make all
+
touch $@
clean:
@@ -51,7 +43,7 @@
# Add here commands to clean up after the build process.
rm *.so || true
-
+
dh_clean
install: build
@@ -59,17 +51,10 @@
dh_testroot
dh_clean -k
dh_installdirs
-
+
# Add here commands to install the package into debian/tmp
- mkdir -p $(CURDIR)/debian/tmp/usr/lib
- cp libboost_python_index-gcc${GCC_VERSION}-1_34_1.so $(CURDIR)/debian/tmp/usr/lib
- ln -sf /usr/lib/libboost_python_index-gcc${GCC_VERSION}-1_34_1.so $(CURDIR)/debian/tmp/usr/lib/libboost_python_index.so
+ PREFIX=$(CURDIR)/debian/tmp make install
- mkdir -p $(CURDIR)/debian/tmp/usr/include
- cp -rvf boost $(CURDIR)/debian/tmp/usr/include
- rm -rf `find $(CURDIR)/debian/tmp/usr/include -name .svn -type d`
-
-
# Build architecture-independent files here.
binary-indep: build install
# We have nothing to do by default.
@@ -84,7 +69,7 @@
dh_movefiles -plibboost-python1.34.1-index-dev /usr/include/boost
dh_movefiles -plibboost-python1.34.1-index /usr/lib
-
+
# dh_install
# dh_installmenu
# dh_installdebconf
Modified: trunk/python-ogre/environment.py
===================================================================
--- trunk/python-ogre/environment.py 2008-07-22 04:45:24 UTC (rev 664)
+++ trunk/python-ogre/environment.py 2008-07-22 09:51:07 UTC (rev 665)
@@ -528,8 +528,10 @@
["rm","-rf %s" % (base,), os.getcwd()],
["cp",'-rvf %s/ %s' % (os.path.join('python-ogre','boost'), base), os.getcwd()],
]
- # FIXME: This should have build commands!
- buildCmds = []
+ buildCmds = [
+ [0,'make all', os.path.join(os.getcwd(), base)],
+ [0,'PREFIX=%s make install' % PREFIX, os.path.join(os.getcwd(), base)],
+ ]
lib = boost.lib.replace("python", "python_index")
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|