summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2001-03-09 21:56:38 (GMT)
committerBrad King <brad.king@kitware.com>2001-03-09 21:56:38 (GMT)
commit8fb07209ebb805f9f1dbade9b68134f9a33555cf (patch)
tree4ab6abc45af5e58d7047fed0f6d7655511fa4464 /Source
parent772b1f627826d6095b87f73ca6db7eef32d6482e (diff)
downloadCMake-8fb07209ebb805f9f1dbade9b68134f9a33555cf.zip
CMake-8fb07209ebb805f9f1dbade9b68134f9a33555cf.tar.gz
CMake-8fb07209ebb805f9f1dbade9b68134f9a33555cf.tar.bz2
ENH: Finished Simplifying dsptemplate processing with in place of separate Release, Debug, ReleaseDLL, ... configurations.
Diffstat (limited to 'Source')
-rw-r--r--Source/DLLHeader.dsptemplate6
-rw-r--r--Source/EXEHeader.dsptemplate9
-rw-r--r--Source/cmDSPMakefile.cxx45
-rw-r--r--Source/cmDSPMakefile.h6
-rw-r--r--Source/cmDSPWriter.cxx45
-rw-r--r--Source/cmDSPWriter.h6
-rw-r--r--Source/staticLibHeader.dsptemplate1
7 files changed, 37 insertions, 81 deletions
diff --git a/Source/DLLHeader.dsptemplate b/Source/DLLHeader.dsptemplate
index 37408fc..ac87994 100644
--- a/Source/DLLHeader.dsptemplate
+++ b/Source/DLLHeader.dsptemplate
@@ -68,7 +68,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# 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
-# ADD LINK32 CM_RELEASEDLL_LIBRARIES 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
+# ADD LINK32 CM_LIBRARIES 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
!ELSEIF "$(CFG)" == "OUTPUT_LIBNAME - Win32 Debug"
@@ -95,9 +95,9 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# 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 /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 CM_DEBUGDLL_LIBRARIES 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 /debug /machine:I386 /pdbtype:sept
+# ADD LINK32 CM_LIBRARIES 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 /debug /machine:I386 /pdbtype:sept
-!ENDIF
+!ENDIF
# Begin Target
diff --git a/Source/EXEHeader.dsptemplate b/Source/EXEHeader.dsptemplate
index b82ce76..4183d40 100644
--- a/Source/EXEHeader.dsptemplate
+++ b/Source/EXEHeader.dsptemplate
@@ -13,8 +13,7 @@
# BUILD_INCLUDES == include path
# EXTRA_DEFINES == compiler defines
# OUTPUT_LIBNAME == name of output library
-# CM_DEBUG_LIBRARIES == libraries linked in
-# CM_RELEASE_LIBRARIES == libraries linked in
+# CM_LIBRARIES == libraries linked in
# TARGTYPE "Win32 (x86) Application" 0x0101
CFG=OUTPUT_LIBNAME - Win32 Debug
@@ -64,7 +63,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# 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 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 /subsystem:console /machine:I386 /force
-# ADD LINK32 CM_RELEASE_LIBRARIES kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib 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 /subsystem:console /machine:I386 /force
+# ADD LINK32 CM_LIBRARIES kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib 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 /subsystem:console /machine:I386 /force
!ELSEIF "$(CFG)" == "OUTPUT_LIBNAME - Win32 Debug"
@@ -89,7 +88,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# 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 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 /subsystem:console /debug /machine:I386 /pdbtype:sept /force
-# ADD LINK32 CM_DEBUG_LIBRARIES kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib 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 /subsystem:console /debug /machine:I386 /pdbtype:sept /force
+# ADD LINK32 CM_LIBRARIES kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib 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 /subsystem:console /debug /machine:I386 /pdbtype:sept /force
!ELSEIF "$(CFG)" == "OUTPUT_LIBNAME - Win32 Release MinSize"
# PROP BASE Use_MFC 0
@@ -111,7 +110,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# 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 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 /subsystem:console /machine:I386 /force
-# ADD LINK32 CM_RELEASE_LIBRARIES kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib 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 /subsystem:console /machine:I386 /force
+# ADD LINK32 CM_LIBRARIES kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib 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 /subsystem:console /machine:I386 /force
!ENDIF
diff --git a/Source/cmDSPMakefile.cxx b/Source/cmDSPMakefile.cxx
index 97359b8..8992f56 100644
--- a/Source/cmDSPMakefile.cxx
+++ b/Source/cmDSPMakefile.cxx
@@ -54,36 +54,25 @@ void cmDSPMakefile::OutputDSPFile()
std::vector<std::string>& libs = m_Makefile->GetLinkLibraries();
for(i = libs.begin(); i != libs.end(); ++i)
{
- m_DebugLibraryOptions += " ";
- m_DebugLibraryOptions += *i;
- m_DebugLibraryOptions += ".lib ";
+ m_LibraryOptions += " ";
+ m_LibraryOptions += *i;
+ m_LibraryOptions += ".lib ";
}
std::vector<std::string>& libswin32 = m_Makefile->GetLinkLibrariesWin32();
for(i = libswin32.begin(); i != libswin32.end(); ++i)
{
- m_DebugLibraryOptions += " ";
- m_DebugLibraryOptions += *i;
- m_DebugLibraryOptions += ".lib ";
+ m_LibraryOptions += " ";
+ m_LibraryOptions += *i;
+ m_LibraryOptions += ".lib ";
}
std::vector<std::string>& libdirs = m_Makefile->GetLinkDirectories();
for(i = libdirs.begin(); i != libdirs.end(); ++i)
{
- m_DebugLibraryOptions += " /LIBPATH:\"";
- m_DebugLibraryOptions += *i;
- if(i->find("Debug") == std::string::npos)
- {
- if(i->find("Release") == std::string::npos)
- {
- m_DebugLibraryOptions += "/$(OUTDIR)\" ";
- }
- }
+ m_LibraryOptions += " /LIBPATH:\"";
+ m_LibraryOptions += *i;
+ m_LibraryOptions += "/$(OUTDIR)\" ";
}
- m_DebugLibraryOptions += "/STACK:10000000 ";
- // add any extra define flags
- m_ReleaseLibraryOptions = m_DebugLibraryOptions;
- m_DebugDLLLibraryOptions = m_DebugLibraryOptions;
- m_ReleaseDLLLibraryOptions = m_DebugDLLLibraryOptions;
- m_ReleaseMinSizeLibraryOptions = m_ReleaseLibraryOptions;
+ m_LibraryOptions += "/STACK:10000000 ";
// Create the DSP or set of DSP's for libraries and executables
if(strlen(m_Makefile->GetLibraryName()) != 0)
@@ -317,16 +306,8 @@ void cmDSPMakefile::WriteDSPHeader(std::ostream& fout)
{
fin.getline(buffer, 2048);
std::string line = buffer;
- cmSystemTools::ReplaceString(line, "CM_RELEASE_LIBRARIES",
- m_ReleaseLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_RELEASEMINSIZE_LIBRARIES",
- m_ReleaseMinSizeLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_DEBUG_LIBRARIES",
- m_DebugLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_RELEASEDLL_LIBRARIES",
- m_ReleaseDLLLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_DEBUGDLL_LIBRARIES",
- m_DebugDLLLibraryOptions.c_str());
+ cmSystemTools::ReplaceString(line, "CM_LIBRARIES",
+ m_LibraryOptions.c_str());
cmSystemTools::ReplaceString(line, "BUILD_INCLUDES",
m_IncludeOptions.c_str());
cmSystemTools::ReplaceString(line, "OUTPUT_LIBNAME",
@@ -418,3 +399,5 @@ void cmDSPMakefile::WriteDSPBuildRule(std::ostream& fout, const char* path)
<< path << "\n";
fout << "# End Source File\n";
}
+
+
diff --git a/Source/cmDSPMakefile.h b/Source/cmDSPMakefile.h
index 08b9428..0c4906b 100644
--- a/Source/cmDSPMakefile.h
+++ b/Source/cmDSPMakefile.h
@@ -86,11 +86,7 @@ private:
std::vector<std::string>& depends);
std::string m_IncludeOptions;
- std::string m_DebugLibraryOptions;
- std::string m_ReleaseLibraryOptions;
- std::string m_ReleaseMinSizeLibraryOptions;
- std::string m_DebugDLLLibraryOptions;
- std::string m_ReleaseDLLLibraryOptions;
+ std::string m_LibraryOptions;
cmMakefile* m_Makefile;
BuildType m_BuildType;
std::vector<std::string> m_Configurations;
diff --git a/Source/cmDSPWriter.cxx b/Source/cmDSPWriter.cxx
index 97359b8..8992f56 100644
--- a/Source/cmDSPWriter.cxx
+++ b/Source/cmDSPWriter.cxx
@@ -54,36 +54,25 @@ void cmDSPMakefile::OutputDSPFile()
std::vector<std::string>& libs = m_Makefile->GetLinkLibraries();
for(i = libs.begin(); i != libs.end(); ++i)
{
- m_DebugLibraryOptions += " ";
- m_DebugLibraryOptions += *i;
- m_DebugLibraryOptions += ".lib ";
+ m_LibraryOptions += " ";
+ m_LibraryOptions += *i;
+ m_LibraryOptions += ".lib ";
}
std::vector<std::string>& libswin32 = m_Makefile->GetLinkLibrariesWin32();
for(i = libswin32.begin(); i != libswin32.end(); ++i)
{
- m_DebugLibraryOptions += " ";
- m_DebugLibraryOptions += *i;
- m_DebugLibraryOptions += ".lib ";
+ m_LibraryOptions += " ";
+ m_LibraryOptions += *i;
+ m_LibraryOptions += ".lib ";
}
std::vector<std::string>& libdirs = m_Makefile->GetLinkDirectories();
for(i = libdirs.begin(); i != libdirs.end(); ++i)
{
- m_DebugLibraryOptions += " /LIBPATH:\"";
- m_DebugLibraryOptions += *i;
- if(i->find("Debug") == std::string::npos)
- {
- if(i->find("Release") == std::string::npos)
- {
- m_DebugLibraryOptions += "/$(OUTDIR)\" ";
- }
- }
+ m_LibraryOptions += " /LIBPATH:\"";
+ m_LibraryOptions += *i;
+ m_LibraryOptions += "/$(OUTDIR)\" ";
}
- m_DebugLibraryOptions += "/STACK:10000000 ";
- // add any extra define flags
- m_ReleaseLibraryOptions = m_DebugLibraryOptions;
- m_DebugDLLLibraryOptions = m_DebugLibraryOptions;
- m_ReleaseDLLLibraryOptions = m_DebugDLLLibraryOptions;
- m_ReleaseMinSizeLibraryOptions = m_ReleaseLibraryOptions;
+ m_LibraryOptions += "/STACK:10000000 ";
// Create the DSP or set of DSP's for libraries and executables
if(strlen(m_Makefile->GetLibraryName()) != 0)
@@ -317,16 +306,8 @@ void cmDSPMakefile::WriteDSPHeader(std::ostream& fout)
{
fin.getline(buffer, 2048);
std::string line = buffer;
- cmSystemTools::ReplaceString(line, "CM_RELEASE_LIBRARIES",
- m_ReleaseLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_RELEASEMINSIZE_LIBRARIES",
- m_ReleaseMinSizeLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_DEBUG_LIBRARIES",
- m_DebugLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_RELEASEDLL_LIBRARIES",
- m_ReleaseDLLLibraryOptions.c_str());
- cmSystemTools::ReplaceString(line, "CM_DEBUGDLL_LIBRARIES",
- m_DebugDLLLibraryOptions.c_str());
+ cmSystemTools::ReplaceString(line, "CM_LIBRARIES",
+ m_LibraryOptions.c_str());
cmSystemTools::ReplaceString(line, "BUILD_INCLUDES",
m_IncludeOptions.c_str());
cmSystemTools::ReplaceString(line, "OUTPUT_LIBNAME",
@@ -418,3 +399,5 @@ void cmDSPMakefile::WriteDSPBuildRule(std::ostream& fout, const char* path)
<< path << "\n";
fout << "# End Source File\n";
}
+
+
diff --git a/Source/cmDSPWriter.h b/Source/cmDSPWriter.h
index 08b9428..0c4906b 100644
--- a/Source/cmDSPWriter.h
+++ b/Source/cmDSPWriter.h
@@ -86,11 +86,7 @@ private:
std::vector<std::string>& depends);
std::string m_IncludeOptions;
- std::string m_DebugLibraryOptions;
- std::string m_ReleaseLibraryOptions;
- std::string m_ReleaseMinSizeLibraryOptions;
- std::string m_DebugDLLLibraryOptions;
- std::string m_ReleaseDLLLibraryOptions;
+ std::string m_LibraryOptions;
cmMakefile* m_Makefile;
BuildType m_BuildType;
std::vector<std::string> m_Configurations;
diff --git a/Source/staticLibHeader.dsptemplate b/Source/staticLibHeader.dsptemplate
index 621ff91..33541a8 100644
--- a/Source/staticLibHeader.dsptemplate
+++ b/Source/staticLibHeader.dsptemplate
@@ -31,7 +31,6 @@ CFG=OUTPUT_LIBNAME - Win32 Debug
!MESSAGE
!MESSAGE "OUTPUT_LIBNAME - Win32 Release" (based on "Win32 (x86) Static Library")
!MESSAGE "OUTPUT_LIBNAME - Win32 Debug" (based on "Win32 (x86) Static Library")
-!MESSAGE
!MESSAGE "OUTPUT_LIBNAME - Win32 Release MinSize" (based on "Win32 (x86) Static Library")
# Begin Project
# PROP AllowPerConfigDependencies 0