← Back to team overview

yade-dev team mailing list archive

[svn] r1800 - in trunk/pkg/common: . Engine/FilterEngine

 

Author: eudoxos
Date: 2009-06-15 19:42:13 +0200 (Mon, 15 Jun 2009)
New Revision: 1800

Modified:
   trunk/pkg/common/Engine/FilterEngine/PythonRunnerFilter.hpp
   trunk/pkg/common/SConscript
Log:
Include Python.h in PythonRunnerFilter. Build this plugin only with EMBED_PYTHON.


Modified: trunk/pkg/common/Engine/FilterEngine/PythonRunnerFilter.hpp
===================================================================
--- trunk/pkg/common/Engine/FilterEngine/PythonRunnerFilter.hpp	2009-06-15 17:34:09 UTC (rev 1799)
+++ trunk/pkg/common/Engine/FilterEngine/PythonRunnerFilter.hpp	2009-06-15 17:42:13 UTC (rev 1800)
@@ -8,6 +8,7 @@
 #pragma once
 #include<yade/core/MetaBody.hpp>
 #include<yade/pkg-common/FilterEngine.hpp>
+#include<Python.h>
 
 // Run python command
 class PythonRunnerFilter: public FilterEngine {

Modified: trunk/pkg/common/SConscript
===================================================================
--- trunk/pkg/common/SConscript	2009-06-15 17:34:09 UTC (rev 1799)
+++ trunk/pkg/common/SConscript	2009-06-15 17:42:13 UTC (rev 1800)
@@ -1,5 +1,12 @@
 # vim: set filetype=python :
 Import('*')
+
+if 'EMBED_PYTHON' in env['CPPDEFINES']:
+	env.Install("$PREFIX/lib/yade$SUFFIX/pkg-common",[
+		env.SharedLibrary('PythonRunnerFilter',['Engine/FilterEngine/PythonRunnerFilter.cpp'],LIBS=env['LIBS']+['FilterEngine']),
+	])
+
+
 env.Install('$PREFIX/lib/yade$SUFFIX/pkg-common',[
 
 	env.SharedLibrary('ParallelEngine',
@@ -89,8 +96,6 @@
 		LIBS=env['LIBS']+['FilterEngine','ColorScale']),
 	env.SharedLibrary('ColorizedTimeFilter',['Engine/FilterEngine/ColorizedTimeFilter.cpp'],
 		LIBS=env['LIBS']+['FilterEngine','ColorScale']),
-	env.SharedLibrary('PythonRunnerFilter',['Engine/FilterEngine/PythonRunnerFilter.cpp'],
-		LIBS=env['LIBS']+['FilterEngine']),
 	env.SharedLibrary('BoundingVolumeMetaEngine',['Engine/MetaEngine/BoundingVolumeMetaEngine.cpp']),
 	env.SharedLibrary('GeometricalModelMetaEngine',['Engine/MetaEngine/GeometricalModelMetaEngine.cpp']),
 	env.SharedLibrary('InteractingGeometryMetaEngine',['Engine/MetaEngine/InteractingGeometryMetaEngine.cpp']),