From dfc7e71f5bd34dc88570e8ba9762eeb045f7d95a Mon Sep 17 00:00:00 2001 From: Harry Moffat Date: Tue, 20 Mar 2007 22:42:17 +0000 Subject: [PATCH] Solaris 10 update Forgot the template specialization on the static storage declaration. Thus, previous commit wouldn't compile on linux. This fixes the problem. --- Cantera/clib/src/ct.cpp | 6 ++++-- Cantera/clib/src/ctreactor.cpp | 2 +- Cantera/fortran/src/fct.cpp | 2 +- Cantera/fortran/src/fctxml.cpp | 2 +- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/Cantera/clib/src/ct.cpp b/Cantera/clib/src/ct.cpp index 2caa7be10..9cc679d7d 100755 --- a/Cantera/clib/src/ct.cpp +++ b/Cantera/clib/src/ct.cpp @@ -26,6 +26,7 @@ #include "Cabinet.h" #include "InterfaceKinetics.h" #include "PureFluidPhase.h" +//#include "xml.h" #include "clib_defs.h" @@ -33,10 +34,11 @@ using namespace std; using namespace Cantera; // Assign storage for the static member of the Templated Cabinet class -Cabinet * Cabinet::__storage = 0; +//class Cabinet; +template<> Cabinet* Cabinet::__storage = (Cabinet* )0; inline XML_Node* _xml(int i) { - return Cabinet::cabinet(false)->item(i); + return Cabinet::cabinet(false)->item(i); } diff --git a/Cantera/clib/src/ctreactor.cpp b/Cantera/clib/src/ctreactor.cpp index 560facba5..fb0f161bf 100755 --- a/Cantera/clib/src/ctreactor.cpp +++ b/Cantera/clib/src/ctreactor.cpp @@ -61,7 +61,7 @@ inline ThermoPhase* _th(int n) { } // Assign storage for the templated Cabinet class's static member -Cabinet * Cabinet::__storage = 0; +template<> Cabinet * Cabinet::__storage = 0; inline Func1* _func(int i) { return Cabinet::cabinet()->item(i); diff --git a/Cantera/fortran/src/fct.cpp b/Cantera/fortran/src/fct.cpp index e9332fd64..e50a1149e 100644 --- a/Cantera/fortran/src/fct.cpp +++ b/Cantera/fortran/src/fct.cpp @@ -28,7 +28,7 @@ #include "flib_defs.h" // Assign storage for the templated classes' static member -Cabinet * Cabinet::__storage=0; +template<> Cabinet * Cabinet::__storage=0; inline XML_Node* _xml(const integer* n) { return Cabinet::cabinet()->item(*n); diff --git a/Cantera/fortran/src/fctxml.cpp b/Cantera/fortran/src/fctxml.cpp index b56f6dbe6..9253b790e 100644 --- a/Cantera/fortran/src/fctxml.cpp +++ b/Cantera/fortran/src/fctxml.cpp @@ -8,7 +8,7 @@ #include "../../clib/src/Cabinet.h" // Assign storage for the templated classes static member -Cabinet * Cabinet::__storage = 0; +template<> Cabinet * Cabinet::__storage = 0; inline XML_Node* _xml(const integer* i) { return Cabinet::cabinet(false)->item(*i);