← Back to team overview

yade-dev team mailing list archive

[svn] r1610 - in trunk: core pkg/dem pkg/dem/PreProcessor

 

Author: cosurgi
Date: 2009-01-05 18:06:57 +0100 (Mon, 05 Jan 2009)
New Revision: 1610

Modified:
   trunk/core/yade.cpp
   trunk/pkg/dem/PreProcessor/TriaxialTestWater.cpp
   trunk/pkg/dem/SConscript
Log:
1. argh, guys. svn HEAD must compile. You didn't check your commits and then I waste 1h to fix that. See this commit, to check what I had to comment out about WATER

2. added 'yade -x' option which disables call to gdb, to speed up crashes due to missing libraries.



Modified: trunk/core/yade.cpp
===================================================================
--- trunk/core/yade.cpp	2009-01-05 16:46:36 UTC (rev 1609)
+++ trunk/core/yade.cpp	2009-01-05 17:06:57 UTC (rev 1610)
@@ -31,6 +31,8 @@
 
 using namespace std;
 
+bool dontUseGdb(false);
+
 #ifdef LOG4CXX
 	// provides parent logger for everybody
 	log4cxx::LoggerPtr logger=log4cxx::Logger::getLogger("yade");
@@ -57,7 +59,8 @@
 		if(sig==SIGABRT || sig==SIGSEGV){
 			signal(SIGSEGV,SIG_DFL); signal(SIGABRT,SIG_DFL); // prevent loops - default handlers
 			cerr<<"SIGSEGV/SIGABRT handler called; gdb batch file is `"<<Omega::instance().gdbCrashBatch<<"'"<<endl;
-			std::system((string("gdb -x ")+Omega::instance().gdbCrashBatch).c_str());
+			if(!dontUseGdb)
+				std::system((string("gdb -x ")+Omega::instance().gdbCrashBatch).c_str());
 			unlink(Omega::instance().gdbCrashBatch.c_str()); // delete the crash batch file
 			raise(sig); // reemit signal after exiting gdb
 		}
@@ -126,6 +129,7 @@
 	-n      : use NullGUI (command line interface) instead of default GUI.\n\
 	-w      : write default configuration (automatic at first run)\n\
 	-c      : use the current directory ./ as configuration directory\n\
+	-x      : don't use gdb\n\
 	-C path : configuration directory different from the default ~/.yade-something/\n\
 	-S file : load simulation from file (works with QtGUI only)\n\
 	-v      : be verbose (may be repeated)\n\
@@ -148,7 +152,7 @@
 	string configPath=string(getenv("HOME")) + "/.yade" SUFFIX; // this is the default, may be overridden by -c / -C
 	
 	int ch; string gui=""; string simulationFileName=""; bool setup=false; int verbose=0; bool coreOptions=true; bool explicitUI=false;
-	while(coreOptions && (ch=getopt(argc,argv,"hnN:wC:cvS:"))!=-1)
+	while(coreOptions && (ch=getopt(argc,argv,"hnN:wC:cxvS:"))!=-1)
 		switch(ch){
 			case 'h': printHelp(); return 1;
 			case 'n': gui="NullGUI"; explicitUI=true; break;
@@ -156,6 +160,7 @@
 			case 'w': setup=true; break;
 			case 'C': configPath=optarg; break;
 			case 'c': configPath="."; break;
+			case 'x': dontUseGdb=true; break;
 			case 'v': verbose+=1; break;
 			case 'S': simulationFileName=optarg; break;
 			case '-': coreOptions=false; break;

Modified: trunk/pkg/dem/PreProcessor/TriaxialTestWater.cpp
===================================================================
--- trunk/pkg/dem/PreProcessor/TriaxialTestWater.cpp	2009-01-05 16:46:36 UTC (rev 1609)
+++ trunk/pkg/dem/PreProcessor/TriaxialTestWater.cpp	2009-01-05 17:06:57 UTC (rev 1610)
@@ -19,7 +19,7 @@
 // #include<yade/pkg-dem/ElasticCohesiveLaw.hpp>
 #include <yade/pkg-dem/CapillaryCohesiveLaw.hpp>
 // #include<yade/pkg-dem/SimpleElasticRelationships.hpp>
-#include<yade/pkg-dem/SimpleElasticRelationshipsWater.hpp>
+/////////////#include<yade/pkg-dem/SimpleElasticRelationshipsWater.hpp>
 #include<yade/pkg-dem/BodyMacroParameters.hpp>
 #include<yade/pkg-dem/SDECLinkPhysics.hpp>
 
@@ -534,8 +534,8 @@
 	/// OLD
 	//interactionPhysicsDispatcher->add("BodyMacroParameters","BodyMacroParameters","MacroMicroElasticRelationshipsWater");
 	/// NEW
-	shared_ptr<InteractionPhysicsEngineUnit> ss(new SimpleElasticRelationshipsWater);
-	interactionPhysicsDispatcher->add(ss);
+/////////////	shared_ptr<InteractionPhysicsEngineUnit> ss(new SimpleElasticRelationshipsWater);
+/////////////	interactionPhysicsDispatcher->add(ss);
 	
 		
 	shared_ptr<BoundingVolumeMetaEngine> boundingVolumeDispatcher	= shared_ptr<BoundingVolumeMetaEngine>(new BoundingVolumeMetaEngine);

Modified: trunk/pkg/dem/SConscript
===================================================================
--- trunk/pkg/dem/SConscript	2009-01-05 16:46:36 UTC (rev 1609)
+++ trunk/pkg/dem/SConscript	2009-01-05 17:06:57 UTC (rev 1610)
@@ -885,6 +885,8 @@
 		LIBS=env['LIBS']+['ParticleParameters',
 			'ElasticContactInteraction',
 			'CapillaryParameters',
+			'TriaxialStressController',
+			'TriaxialCompressionEngine',
 			'Force',
 			'CapillaryCohesiveLaw']),
 
@@ -895,6 +897,7 @@
         CapillaryCohesiveLaw
         AveragePositionRecorder
         VelocityRecorder
+	PositionOrientationRecorder
         ForceRecorder
         TriaxialStateRecorder
         CapillaryStressRecorder
@@ -907,6 +910,7 @@
         BodyRedirectionVector
         InteractingSphere
         InteractingBox
+	NewtonsDampedLaw
         CundallNonViscousDamping
         CundallNonViscousDamping
         MetaInteractingGeometry




Follow ups