From b32b2c28447858189016700b514b0bd0f7ae7bea Mon Sep 17 00:00:00 2001 From: Harry Moffat Date: Tue, 10 Apr 2007 22:04:06 +0000 Subject: [PATCH] Fixed linking error in python module that was caused by duplicate static member storage statements on linux. --- Cantera/clib/src/ct.cpp | 4 ---- Cantera/clib/src/ctfunc.cpp | 1 + Cantera/clib/src/ctreactor.cpp | 3 --- Cantera/clib/src/ctxml.cpp | 2 ++ 4 files changed, 3 insertions(+), 7 deletions(-) diff --git a/Cantera/clib/src/ct.cpp b/Cantera/clib/src/ct.cpp index 9cc679d7d..adbbb53e4 100755 --- a/Cantera/clib/src/ct.cpp +++ b/Cantera/clib/src/ct.cpp @@ -33,10 +33,6 @@ using namespace std; using namespace Cantera; -// Assign storage for the static member of the Templated Cabinet class -//class Cabinet; -template<> Cabinet* Cabinet::__storage = (Cabinet* )0; - inline XML_Node* _xml(int i) { return Cabinet::cabinet(false)->item(i); } diff --git a/Cantera/clib/src/ctfunc.cpp b/Cantera/clib/src/ctfunc.cpp index 635bf16d7..0c788701a 100755 --- a/Cantera/clib/src/ctfunc.cpp +++ b/Cantera/clib/src/ctfunc.cpp @@ -20,6 +20,7 @@ using namespace Cantera; typedef Func1 func_t; +// Assign storage to the Cabinet static member template<> Cabinet* Cabinet::__storage = 0; inline func_t* _func(int i) { diff --git a/Cantera/clib/src/ctreactor.cpp b/Cantera/clib/src/ctreactor.cpp index fb0f161bf..62c978f0b 100755 --- a/Cantera/clib/src/ctreactor.cpp +++ b/Cantera/clib/src/ctreactor.cpp @@ -60,9 +60,6 @@ inline ThermoPhase* _th(int n) { return Storage::__storage->__thtable[n]; } -// Assign storage for the templated Cabinet class's static member -template<> Cabinet * Cabinet::__storage = 0; - inline Func1* _func(int i) { return Cabinet::cabinet()->item(i); } diff --git a/Cantera/clib/src/ctxml.cpp b/Cantera/clib/src/ctxml.cpp index 8eb50bbc5..404756248 100644 --- a/Cantera/clib/src/ctxml.cpp +++ b/Cantera/clib/src/ctxml.cpp @@ -19,6 +19,8 @@ #define ERR -999 #define DERR -999.999 +// Assign storage for the static member of the Templated Cabinet class +// class Cabinet; template<> Cabinet* Cabinet::__storage = 0; inline XML_Node* _xml(int i) {