Permalink
Browse files

improved the readme

  • Loading branch information...
1 parent 5831063 commit c00e9a644917a2181b76d5b1f949fe9fcd04abf4 @b45ch1 committed Jan 9, 2009
Showing with 49 additions and 2 deletions.
  1. +4 −0 .gitignore
  2. +4 −2 README
  3. +41 −0 SConstruct.EXAMPLE
View
@@ -19,6 +19,10 @@ report/*
*~
*.tex
Doxyfile
+build
+
+setup.py
+SConstruct
# EXCEPTIONS
!README
View
6 README
@@ -76,7 +76,9 @@ INSTALLATION:
configure make
do NOT "make install"
-3) modify the SConstruct file such that the boost include files and libraries can be found
+3) rename setup.py.EXAMPLE to setup.py to fit your system:
+Run python setup.py build_ext --inplace
-4) run scons on a command shell
+Alternatively you can rename SConstruct.EXAMPLE to SConstruct and modify it to fit your system and build with
+ scons
View
@@ -0,0 +1,41 @@
+import distutils.sysconfig
+import os
+import numpy
+
+#adolc_include_path = os.getcwd() + '/adolc-1.11.0-trunk/include'
+#adolc_library_path = os.getcwd() + '/adolc-1.11.0-trunk/lib'
+
+
+adolc_include_path = os.getcwd() + '/adolc-2.0.0/include'
+adolc_library_path = os.getcwd() + '/adolc-2.0.0/lib'
+
+LIBS = ['adolc',
+ #'boost_python-gcc42-mt-1_34_1'
+ 'boost_python-gcc42-1_34_1'
+ ]
+LIBPATH = [
+ adolc_library_path,
+ #'/u/walter/workspace/python_extension_for_adolc/adolc-1.10.2/lib',
+ #'/data/walter/opt_software/boost_1_34_1/bin.v2/libs/python/build/gcc-4.2.1/release/threading-multi'
+ '/data/walter/opt_software/boost_1_34_1/bin.v2/libs/python/build/gcc-4.2.1/release'
+ ]
+INCLUDEPATH = [
+ adolc_include_path,
+ '/u/walter/opt_software/my_global_cpp_libaries',
+ #'/u/walter/workspace/python_extension_for_adolc/adolc-1.10.2/include/adolc',
+ '/data/walter/opt_software/boost_1_34_1',
+ '/usr/include/python2.5'
+ ]
+
+env = Environment(
+ CPPPATH=[distutils.sysconfig.get_python_inc(),numpy.get_include()] + INCLUDEPATH,
+ CXXFLAGS="-ftemplate-depth-100 -DBOOST_PYTHON_DYNAMIC_LIB -O2",
+ LIBPATH=["/usr/lib/python2.5/config"] + LIBPATH,
+ LIBS= LIBS,
+ RPATH = LIBPATH, #include information where shared libraries can be found to avoid errors like: "ImportError: libboost_python-gcc42-mt-1_34_1.so.1.34.1: cannot open shared object file: No such file or directory"
+ SHLIBPREFIX="", #gets rid of lib prefix
+)
+Default('.')
+adolc = env.SharedLibrary(target='_adolc', source=['py_adolc.cpp', 'num_util.cpp'])
+#env.Install("./release/adolc", adolc)
+

0 comments on commit c00e9a6

Please sign in to comment.