Commit 346e6392 authored by hrchilds's avatar hrchilds
Browse files

Update from July 15, 2004

git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@280 18c085ea-50e0-402c-830e-de6fd14e8384
parent 083be2b8
......@@ -570,10 +570,10 @@ configure script or can listed by the configure script by typing
--with-exodus-lib[=<DIR>] specify Exodus lib path
The enable parallel option builds the parallel version of VisIt. Parallel
versions are supported on SGI and IBM AIX systems. The disable scripting
option builds VisIt without the Python scripting. The enable buildall
option builds all the VisIt plugins. By default, only the most common
plugins are built.
versions are supported on SGI, IBM AIX, Tru64, and some Linux systems. The
disable scripting option builds VisIt without the Python scripting. The
enable buildall option builds all the VisIt plugins. By default, only the
most common plugins are built.
The second group of options are used when building with support for reading
SAF files. The third group of options are used when building with support
......
......@@ -232,7 +232,7 @@ cd Mesa-5.0.2
# The additions above will cause the two modified libraries to be built
# as prebound dynamic libraries, which will help reduce VisIt's start
# time.
# 3. Open src/Makefile.X11 and remove all of the source code files from
# 3. Open src/mesa/Makefile.X11 and remove all of the source code files from
# the DRIVER_SOURCES variable so it is defined as:
# DRIVER_SOURCES =
#
......@@ -291,14 +291,15 @@ cd VTK
# Look for the following CMake keys and set these values:
#
# CMAKE_BUILD_TYPE:STRING = Release
# CMAKE_CXXFLAGS_RELEASE = '-O2'
# CMAKE_CXX_FLAGS_RELEASE:STRING = '-O2'
# CMAKE_EXE_LINKER_FLAGS_RELEASE:STRING='-prebind'
# CMAKE_MODULE_LINKER_FLAGS_RELEASE:STRING='-prebind'
# CMAKE_SHARED_LINKER_FLAGS_RELASE:STRING='-prebind'
# CMAKE_VERBOSE_MAKEFILE:BOOL=TRUE
# VTK_USE_MANGLED_MESA:BOOL=OFF
# VTK_USE_MANGLED_MESA:BOOL=ON
#
# Look for -flat_namespace and replace it with -twolevel_namespace
# Look for -flat_namespace and replace it with -twolevel_namespace, delete
# the -U flag and its argument.
#
../cmake-1.8.1/bin/cmake .
make
......@@ -378,7 +379,7 @@ cp IO/*.h ../visit/vtk/IO
cp Imaging/*.h ../visit/vtk/Imaging
cp Rendering/*.h ../visit/vtk/Rendering
cp MangleMesaInclude/*.h ../visit/vtk/MangleMesaInclude
cp bin/*.so ../visit/vtk/lib
cp bin/*.dylib ../visit/vtk/lib
cd ..
The next offset after libvtkRendering.dylib, which has an offset of 0x21f6f000 and
......@@ -419,8 +420,8 @@ ar -x ../libpython2.3.a
echo "char **environ=0;" > environhack.c
gcc -o environhack.o -c environhack.c
gcc -dynamiclib -prebind -Wl,-seg1addr,0x222b3000,-install_name,@executable_path/../lib/libpython2.3.dylib,-compatibility_version,2.3.3,-current_version,2.3.3 -twolevel_namespace -o libpython2.3.dylib *.o -framework Carbon
cp libpython2.3.dylib ../visit/python/lib/python2.3/config/libpython2.3.dylib
cd ..
cp libpython2.3.dylib ../../visit/python/lib/python2.3/config/libpython2.3.dylib
cd ../..
The next offset after libpython.dylib, which has an offset of 0x222b3000 and a library
size of 3,311,968 (0x328960) bytes is:
......@@ -599,9 +600,9 @@ More information about building VisIt follows after that.
#
# Configure VisIt
#
gunzip visit040517.tar.gz
tar xf visit040517.tar
cd visit040517/config-site
gunzip visit040719.tar.gz
tar xf visit040719.tar
cd visit040719/config-site
echo VISITHOME=`cat ../../visitpath` > `hostname`.conf
cat Template.conf >> `hostname`.conf
cd ..
......@@ -620,8 +621,18 @@ it runs out of memory with the default -O2 optimization flag.
cd databases/Silo
vi Makefile
# Change -O2 to -O1
# Look for CXXFLAGS=$(CXXFLAGSORIG) and right after $(CXXFLAGSORIG), add -O1
# so the Silo database reader can build. The default optimization level (-O2)
# causes gcc to run out of memory on some MacOS X computers.
# Change Silo version if you have a slightly old version of Silo.
vi avtSiloWriter.h
comment out #define SILO_VERSION_4_4
cd ../..
# Build VisIt
make
If you have any problems send e-mail to visit-help@llnl.gov.
......@@ -260,7 +260,8 @@ main(int argc, char *argv[])
* Date: Mon Aug 26 13:08:21 PST 2002
*
* Input Arguments:
* key : The key that we're looking for.
* which_root : The root key to open.
* key : The key that we're looking for.
*
* Output Arguments:
* keyval : A string containing the value for the key. This memory is
......@@ -268,22 +269,31 @@ main(int argc, char *argv[])
* should be freed by the caller.
*
* Modifications:
* Brad Whitlock, Mon Jul 12 16:34:18 PST 2004
* I made it use ReadKeyFromRoot so we can check for VisIt information
* in a couple places. This is to avoid the situation where VisIt won't
* run when installed without Administrator access.
*
*****************************************************************************/
int
ReadKey(const char *key, char **keyval)
ReadKeyFromRoot(HKEY which_root, const char *key, char **keyval)
{
int retval = 0;
int readSuccess = 0;
char regkey[100];
HKEY hkey;
if((retval = ReadKeyFromRoot(HKEY_LOCAL_MACHINE, key, keyval)) == 0)
retval = ReadKeyFromRoot(HKEY_CURRENT_USER, key, keyval);
return retval;
/* Try and read the key from the system registry. */
sprintf(regkey, "VISIT%s", VERSION);
*keyval = (char *)malloc(500);
if(RegOpenKeyEx(which_root, regkey, 0, KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS)
{
DWORD keyType, strSize = 500;
if(RegQueryValueEx(hkey, key, NULL, &keyType, *keyval, &strSize) == ERROR_SUCCESS)
{
readSuccess = 1;
}
RegCloseKey(hkey);
}
return readSuccess;
}
/******************************************************************************
......@@ -295,8 +305,7 @@ ReadKey(const char *key, char **keyval)
* Date: Mon Aug 26 13:08:21 PST 2002
*
* Input Arguments:
* which_root : The root key to open.
* key : The key that we're looking for.
* key : The key that we're looking for.
*
* Output Arguments:
* keyval : A string containing the value for the key. This memory is
......@@ -304,31 +313,22 @@ ReadKey(const char *key, char **keyval)
* should be freed by the caller.
*
* Modifications:
* Brad Whitlock, Mon Jul 12 16:34:18 PST 2004
* I made it use ReadKeyFromRoot so we can check for VisIt information
* in a couple places. This is to avoid the situation where VisIt won't
* run when installed without Administrator access.
*
*****************************************************************************/
int
ReadKeyFromRoot(HKEY which_root, const char *key, char **keyval)
ReadKey(const char *key, char **keyval)
{
int readSuccess = 0;
char regkey[100];
HKEY hkey;
/* Try and read the key from the system registry. */
sprintf(regkey, "VISIT%s", VERSION);
*keyval = (char *)malloc(500);
if(RegOpenKeyEx(which_root, regkey, 0, KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS)
{
DWORD keyType, strSize = 500;
if(RegQueryValueEx(hkey, key, NULL, &keyType, *keyval, &strSize) == ERROR_SUCCESS)
{
readSuccess = 1;
}
RegCloseKey(hkey);
}
int retval = 0;
return readSuccess;
if((retval = ReadKeyFromRoot(HKEY_CLASSES_ROOT, key, keyval)) == 0)
retval = ReadKeyFromRoot(HKEY_CURRENT_USER, key, keyval);
return retval;
}
/******************************************************************************
......
......@@ -12,7 +12,7 @@
<Field name="id" type="stringVector">Streamline_1.0 InverseGhostZone_1.0 </Field>
<Field name="enabled" type="intVector">0 0 </Field>
</Object>
<Object name="HostProfileList" childObjects="31">
<Object name="HostProfileList" childObjects="33">
<Object name="HostProfile" childObjects="0">
<Field name="shareOneBatchJob" type="bool">true</Field>
<Field name="profileName" type="string">Q-LANL parallel ldevq</Field>
......@@ -715,6 +715,52 @@
<Field name="parallel" type="bool">true</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Object name="HostProfile" childObjects="0">
<Field name="profileName" type="string">serial</Field>
<Field name="host" type="string">um.asci.llnl.gov</Field>
<Field name="hostAliases" type="string">um#.asci.llnl.gov um##.asci.llnl.gov um###.asci.llnl.gov um# um## um###</Field>
<Field name="timeout" type="int">480</Field>
<Field name="numProcessors" type="int">1</Field>
<Field name="numNodesSet" type="bool">false</Field>
<Field name="numNodes" type="int">0</Field>
<Field name="partitionSet" type="bool">false</Field>
<Field name="partition" type="string"></Field>
<Field name="bankSet" type="bool">false</Field>
<Field name="bank" type="string"></Field>
<Field name="timeLimitSet" type="bool">false</Field>
<Field name="timeLimit" type="string"></Field>
<Field name="launchMethodSet" type="bool">false</Field>
<Field name="launchMethod" type="string"></Field>
<Field name="forceStatic" type="bool">true</Field>
<Field name="forceDynamic" type="bool">false</Field>
<Field name="active" type="bool">true</Field>
<Field name="arguments" type="stringVector">-dir /usr/gapps/visit </Field>
<Field name="parallel" type="bool">false</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Object name="HostProfile" childObjects="0">
<Field name="profileName" type="string">parallel pbatch</Field>
<Field name="host" type="string">um.asci.llnl.gov</Field>
<Field name="hostAliases" type="string">>um#.asci.llnl.gov um##.asci.llnl.gov um###.asci.llnl.gov um# um## um###</Field>
<Field name="timeout" type="int">480</Field>
<Field name="numProcessors" type="int">16</Field>
<Field name="numNodesSet" type="bool">true</Field>
<Field name="numNodes" type="int">2</Field>
<Field name="partitionSet" type="bool">true</Field>
<Field name="partition" type="string">um</Field>
<Field name="bankSet" type="bool">true</Field>
<Field name="bank" type="string">bdivp</Field>
<Field name="timeLimitSet" type="bool">true</Field>
<Field name="timeLimit" type="string">30m</Field>
<Field name="launchMethodSet" type="bool">true</Field>
<Field name="launchMethod" type="string">psub</Field>
<Field name="forceStatic" type="bool">true</Field>
<Field name="forceDynamic" type="bool">false</Field>
<Field name="active" type="bool">false</Field>
<Field name="arguments" type="stringVector">-dir /usr/gapps/visit </Field>
<Field name="parallel" type="bool">true</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Field name="activeProfile" type="int">1</Field>
</Object>
</Object>
......
......@@ -12,7 +12,7 @@
<Field name="id" type="stringVector">Streamline_1.0 InverseGhostZone_1.0 </Field>
<Field name="enabled" type="intVector">0 0 </Field>
</Object>
<Object name="HostProfileList" childObjects="21">
<Object name="HostProfileList" childObjects="25">
<Object name="HostProfile" childObjects="0">
<Field name="profileName" type="string">serial</Field>
<Field name="host" type="string">blue.llnl.gov</Field>
......@@ -496,6 +496,74 @@
<Field name="parallel" type="bool">true</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Object name="HostProfile" childObjects="0">
<Field name="profileName" type="string">serial</Field>
<Field name="host" type="string">uv.asci.llnl.gov</Field>
<Field name="hostAliases" type="string">uv#.asci.llnl.gov uv##.asci.llnl.gov uv###.asci.llnl.gov uv# uv## uv###</Field>
<Field name="timeout" type="int">480</Field>
<Field name="numProcessors" type="int">1</Field>
<Field name="numNodesSet" type="bool">false</Field>
<Field name="numNodes" type="int">0</Field>
<Field name="partitionSet" type="bool">false</Field>
<Field name="partition" type="string"></Field>
<Field name="bankSet" type="bool">false</Field>
<Field name="bank" type="string"></Field>
<Field name="timeLimitSet" type="bool">false</Field>
<Field name="timeLimit" type="string"></Field>
<Field name="launchMethodSet" type="bool">false</Field>
<Field name="launchMethod" type="string"></Field>
<Field name="forceStatic" type="bool">true</Field>
<Field name="forceDynamic" type="bool">false</Field>
<Field name="active" type="bool">true</Field>
<Field name="arguments" type="stringVector">-dir /usr/gapps/visit </Field>
<Field name="parallel" type="bool">false</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Object name="HostProfile" childObjects="0">
<Field name="profileName" type="string">parallel pbatch</Field>
<Field name="host" type="string">uv.asci.llnl.gov</Field>
<Field name="hostAliases" type="string">>uv#.asci.llnl.gov uv##.asci.llnl.gov uv###.asci.llnl.gov uv# uv## uv###</Field>
<Field name="timeout" type="int">480</Field>
<Field name="numProcessors" type="int">16</Field>
<Field name="numNodesSet" type="bool">true</Field>
<Field name="numNodes" type="int">2</Field>
<Field name="partitionSet" type="bool">true</Field>
<Field name="partition" type="string">uv</Field>
<Field name="bankSet" type="bool">true</Field>
<Field name="bank" type="string">bdivp</Field>
<Field name="timeLimitSet" type="bool">true</Field>
<Field name="timeLimit" type="string">30m</Field>
<Field name="launchMethodSet" type="bool">true</Field>
<Field name="launchMethod" type="string">psub</Field>
<Field name="forceStatic" type="bool">true</Field>
<Field name="forceDynamic" type="bool">false</Field>
<Field name="active" type="bool">false</Field>
<Field name="arguments" type="stringVector">-dir /usr/gapps/visit </Field>
<Field name="parallel" type="bool">true</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Object name="HostProfile">
<Field name="profileName" type="string">serial</Field>
<Field name="host" type="string">thunder.llnl.gov</Field>
<Field name="active" type="bool">true</Field>
<Field name="arguments" type="stringVector">"-dir" "/usr/gapps/visit" </Field>
<Field name="hostAliases" type="string">thunder#.llnl.gov thunder##.llnl.gov thunder###.llnl.gov thunder####.llnl.gov thunder# thunder## thunder### thunder####</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Object name="HostProfile">
<Field name="profileName" type="string">parallel pbatch</Field>
<Field name="host" type="string">thunder.llnl.gov</Field>
<Field name="numProcessors" type="int">8</Field>
<Field name="numNodes" type="int">0</Field>
<Field name="partitionSet" type="bool">true</Field>
<Field name="partition" type="string">pbatch</Field>
<Field name="launchMethodSet" type="bool">true</Field>
<Field name="launchMethod" type="string">srun</Field>
<Field name="arguments" type="stringVector">"-dir" "/usr/gapps/visit" </Field>
<Field name="parallel" type="bool">true</Field>
<Field name="hostAliases" type="string">thunder#.llnl.gov thunder##.llnl.gov thunder###.llnl.gov thunder####.llnl.gov thunder# thunder## thunder### thunder####</Field>
<Field name="clientHostDetermination" type="string">ParsedFromSSHCLIENT</Field>
</Object>
<Field name="activeProfile" type="int">1</Field>
</Object>
</Object>
......
......@@ -386,6 +386,10 @@ avtMatvfFilter::DeriveVariable(vtkDataSet *in_ds)
// Added support for integer material indices.
// Added support for integer ranges.
//
// Hank Childs, Thu Jul 15 14:44:17 PDT 2004
// Make sure the base pointer type for the dynamic cast is in the
// inheritance tree of what we are downcasting type. ('5201)
//
// ****************************************************************************
void
avtMatvfFilter::ProcessArguments(ArgsExpr *args, ExprPipelineState *state)
......@@ -419,7 +423,7 @@ avtMatvfFilter::ProcessArguments(ArgsExpr *args, ExprPipelineState *state)
// Pull off the second argument and see if it's a string or a list.
ArgExpr *secondarg = (*arguments)[1];
ExprNode *secondTree = secondarg->GetExpr();
ExprGrammarNode *secondTree = secondarg->GetExpr();
string type = secondTree->GetTypeName();
if ((type != "Const") && (type != "List"))
{
......
......@@ -470,6 +470,10 @@ avtSpecMFFilter::DeriveVariable(vtkDataSet *in_ds)
// Added support for integer material indices.
// Added support for integer ranges.
//
// Hank Childs, Thu Jul 15 14:44:17 PDT 2004
// Make sure the base pointer type for the dynamic cast is in the
// inheritance tree of what we are downcasting type. ('5201)
//
// ****************************************************************************
void
avtSpecMFFilter::ProcessArguments(ArgsExpr *args, ExprPipelineState *state)
......@@ -503,7 +507,7 @@ avtSpecMFFilter::ProcessArguments(ArgsExpr *args, ExprPipelineState *state)
// Pull off the second argument and see if it's a constant.
ArgExpr *secondarg = (*arguments)[1];
ExprNode *secondTree = secondarg->GetExpr();
ExprGrammarNode *secondTree = secondarg->GetExpr();
string secondtype = secondTree->GetTypeName();
if ((secondtype != "Const"))
{
......
......@@ -196,13 +196,14 @@ avtQueryOverTimeFilter::Execute(void)
if (skippedTimes.size() != 0)
{
ostrstream osm;
osm << "\nQueryOverTime ( " << qatts.GetName() << ") experienced\n"
osm << "\nQueryOverTime ( " << qatts.GetName().c_str()
<< ") experienced\n"
<< "problems with the following timesteps and \n"
<< "skipped them while generating the curve:\n ";
for (int j = 0; j < skippedTimes.size(); j++)
osm << skippedTimes[j] << " ";
osm << "\nLast message received: " << eM << endl;
osm << "\nLast message received: " << eM.c_str() << endl;
string errorMessage = osm.str();
debug5 << errorMessage.c_str() << endl;
avtCallback::IssueWarning(errorMessage.c_str());
......
......@@ -9,7 +9,6 @@
#include <string>
#include <vector>
#include <float.h>
#include <strstream.h>
#include <vtkCell.h>
#include <vtkCellData.h>
......@@ -699,11 +698,11 @@ avtMinMaxQuery::InfoToString(const MinMaxInfo &info)
os.setf(ios::fixed);
os.setf(ios::showpoint);
os << info.GetValue() << " (" << elementName << " " << elNum << " ";
os << info.GetValue() << " (" << elementName.c_str() << " " << elNum << " ";
if (info.GetMatName() != "NO_MAT")
os << "for material " << info.GetMatName() << " ";
os << "for material " << info.GetMatName().c_str() << " ";
if (!singleDomain)
{
......@@ -713,7 +712,7 @@ avtMinMaxQuery::InfoToString(const MinMaxInfo &info)
if (domainName.size() > 0)
{
os << "in " << domainName << " " ;
os << "in " << domainName.c_str() << " " ;
}
else
{
......
......@@ -169,7 +169,7 @@ avtCosmosPPFileFormat::avtCosmosPPFileFormat(const char *fname)
}
else
{
debug1 << "Found bad key = " << key << endl;
debug1 << "Found bad key = " << key.c_str() << endl;
EXCEPTION1(InvalidDBTypeException, "Badly formed cosmos file.");
}
}
......
......@@ -117,8 +117,8 @@ void avtImageFileFormat::ReadInImage(void)
}
// find the file extension
int start;
for(int i=0; i<fname.size(); i++)
int i, start;
for(i=0; i<fname.size(); i++)
if(fname[i] == '.')
start = i;
string ext(fname, start+1, fname.size()-1);
......@@ -184,7 +184,6 @@ void avtImageFileFormat::ReadInImage(void)
// load in color info
std::vector<float> red, green, blue, intensity, alpha;
int i,j;
red.resize(xdim*ydim);
green.resize(xdim*ydim);
blue.resize(xdim*ydim);
......@@ -193,7 +192,7 @@ void avtImageFileFormat::ReadInImage(void)
// if the image has an alpha channel set, read it in
if (image->GetNumberOfScalarComponents() == 4)
{
for(j=0; j < ydim; j++)
for(int j=0; j < ydim; j++)
{
for(i=0; i < xdim; i++)
{
......@@ -207,7 +206,7 @@ void avtImageFileFormat::ReadInImage(void)
// otherwise, set alpha in each pixel to be maximum
else if (image->GetNumberOfScalarComponents() == 3)
{
for(j=0; j < ydim; j++)
for(int j=0; j < ydim; j++)
{
for(i=0; i < xdim; i++)
{
......@@ -221,7 +220,7 @@ void avtImageFileFormat::ReadInImage(void)
}
else if (image->GetNumberOfScalarComponents() == 1)
{
for(j=0; j < ydim; j++)
for(int j=0; j < ydim; j++)
{
for(i=0; i < xdim; i++)
{
......
......@@ -225,7 +225,7 @@ avtKullLiteFileFormat::~avtKullLiteFileFormat()
void
avtKullLiteFileFormat::ReadInFile(int fi)
{
debug4 << "Reading in dataset from KullLite file " << my_filenames[fi]<< endl;
debug4 << "Reading in dataset from KullLite file " << my_filenames[fi].c_str()<< endl;
m_pdbFile = PD_open((char *) my_filenames[fi].c_str(), "r");
if (m_pdbFile == NULL)
......@@ -611,7 +611,7 @@ avtKullLiteFileFormat::ReadInFile(int fi)
vtkDataSet *
avtKullLiteFileFormat::GetMesh(int dom, const char *mesh)
{
debug5 << "Getting mesh from KullLite file: " << my_filenames[dom] << endl;
debug5 << "Getting mesh from KullLite file: " << my_filenames[dom].c_str() << endl;
if (dom < 0 || dom >= my_filenames.size())
EXCEPTION2(BadDomainException, dom, my_filenames.size());
......@@ -1067,7 +1067,7 @@ void avtKullLiteFileFormat::ReadInMaterialNames()
void avtKullLiteFileFormat::ReadInMaterialName(int fi)
{
debug4 << "Reading in material header from KullLite file "
<< my_filenames[fi] << endl;
<< my_filenames[fi].c_str() << endl;
m_pdbFile = PD_open((char *) my_filenames[fi].c_str(), "r");
if (m_pdbFile == NULL)
......
......@@ -10,8 +10,6 @@
#include <KullFormatStructures.h>
#include <avtSTMDFileFormat.h>
#include <database_exports.h>
#include <void_ref_ptr.h>
struct s_PDBfile;
......@@ -37,7 +35,7 @@ class vtkDataArray;
//
// ****************************************************************************
class DATABASE_API avtKullLiteFileFormat : public avtSTMDFileFormat
class avtKullLiteFileFormat : public avtSTMDFileFormat
{
public:
avtKullLiteFileFormat(const char *);
......
No preview for this file type
......@@ -24,6 +24,11 @@
// Jeremy Meredith, Wed Jul 7 17:08:03 PDT 2004
// Allow for mdserver-specific code in a plugin's source files.
//
// Brad Whitlock, Wed Jul 14 10:54:35 PDT 2004
// Changed the registry stuff so it gets the keys from the right place. I
// also fixed a bunch of bugs with the project files generated for
// mdserver and engine plugins.
//
// ****************************************************************************
class ProjectFileGeneratorPlugin
......@@ -112,6 +117,17 @@ protected:
#if defined(_WIN32)
bool ReadKey(const char *key, unsigned char **keyval) const
{
bool retval = false;
*keyval = 0;
if((retval = ReadKeyFromRoot(HKEY_CLASSES_ROOT, key, keyval)) == false)
retval = ReadKeyFromRoot(HKEY_CURRENT_USER, key, keyval);
return retval;
}
bool ReadKeyFromRoot(HKEY which_root, const char *key, unsigned char **keyval) const
{
bool readSuccess = false;
QString regkey;
......@@ -120,7 +136,7 @@ protected:
/* Try and read the key from the system registry. */
regkey.sprintf("VISIT%s", VERSION);
*keyval = new unsigned char[500];
if(RegOpenKeyEx(HKEY_CLASSES_ROOT, regkey.latin1(), 0, KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS)
if(RegOpenKeyEx(which_root, regkey.latin1(), 0, KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS)
{
DWORD keyType, strSize = 500;
if(RegQueryValueEx(hkey, key, NULL, &keyType, *keyval, &strSize) == ERROR_SUCCESS)
......@@ -131,6 +147,12 @@ protected:
RegCloseKey(hkey);
}
if(!readSuccess)
{
delete [] *keyval;
*keyval = 0;
}
return readSuccess;
}
#endif
......@@ -143,7 +165,7 @@ protected:
if(ReadKey("VISITDEVDIR", &VISITDEVDIR))
{
retval = QString((char *)VISITDEVDIR) + QString("\\projects\\databases\\");
retval = QString((char *)VISITDEVDIR);
delete [] VISITDEVDIR;
}
else
......@@ -305,6 +327,8 @@ protected:
void WriteProjectHelper(ostream &out, const QString &pluginType, char pluginComponent,
const QString &exports, const QString &libs, const vector<QString> &srcFiles)
{
char *suffix = (pluginComponent == 'E') ? "_ser" : "";
out << "# Microsoft Developer Studio Project File - Name=\"" << name << pluginComponent << "\" - Package Owner=<4>" << endl;
out << "# Microsoft Developer Studio Generated Build File, Format Version 6.00" << endl;
out << "# ** DO NOT EDIT **" << endl;
......@@ -363,10 +387,10 @@ protected:
out << "# ADD BSC32 /nologo" << endl;
out << "LINK32=link.exe" << endl;
out << "# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386" << endl;
out << "# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib " << libs << " /nologo /dll /machine:I386 /out:\"Release/lib" << pluginComponent << name << ".dll\"" << endl;
out << "# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib " << libs << " /nologo /dll /machine:I386 /out:\"Release/lib" << pluginComponent << name << suffix <<".dll\"" << endl;