remove obsolete folder tools
git-svn-id: svn://svn.code.sf.net/p/loki-lib/code/trunk@737 7ec92016-0320-0410-acc4-a06ded1c099a
This commit is contained in:
parent
383fab624c
commit
e45296ded3
6 changed files with 0 additions and 331 deletions
|
@ -1,139 +0,0 @@
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
// Generates forwarding headers using the information
|
|
||||||
// in the header.lst & vendor.lst files
|
|
||||||
//
|
|
||||||
// To create a header list from an existing directory of headers
|
|
||||||
// dir *.h /b > headers.lst
|
|
||||||
//
|
|
||||||
// Copyright Shannon Barber 2002.
|
|
||||||
//
|
|
||||||
// Permission to use, copy, modify, distribute and sell this software for any
|
|
||||||
// purpose is hereby granted without fee, provided that the above copyright
|
|
||||||
// notice appear in all copies and that both that copyright notice and this
|
|
||||||
// permission notice appear in supporting documentation. It is provided "as is"
|
|
||||||
// without express or implied warranty.
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
|
|
||||||
#include <iostream>
|
|
||||||
#include <fstream>
|
|
||||||
#include <string>
|
|
||||||
#include <sstream>
|
|
||||||
#include <vector>
|
|
||||||
#include <ctime>
|
|
||||||
|
|
||||||
using namespace std;
|
|
||||||
|
|
||||||
struct Compiler
|
|
||||||
{
|
|
||||||
Compiler() {}
|
|
||||||
Compiler(const string& VersionTest, const string& SubDir) :
|
|
||||||
version_test(VersionTest), subdir(SubDir)
|
|
||||||
{}
|
|
||||||
string version_test;
|
|
||||||
string subdir;
|
|
||||||
};
|
|
||||||
|
|
||||||
int main(int argc, char* argv[])
|
|
||||||
{
|
|
||||||
if(argc != 3)
|
|
||||||
{
|
|
||||||
cout <<"Usage: <Header List> <Version/Vendor List>"<<endl;
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
typedef vector<Compiler> cv_type;
|
|
||||||
|
|
||||||
cv_type vendors;
|
|
||||||
char buf[1024];
|
|
||||||
string check;
|
|
||||||
string subdir;
|
|
||||||
fstream vendor_file;
|
|
||||||
|
|
||||||
vendor_file.open(argv[2], ios::in);
|
|
||||||
if(!vendor_file.is_open())
|
|
||||||
{
|
|
||||||
cout << "Unable to open vendor file: " << argv[2] << endl;
|
|
||||||
return -2;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
vendors.reserve(10);
|
|
||||||
while(!vendor_file.eof())
|
|
||||||
{
|
|
||||||
vendor_file.getline(buf, 1024, '\n');
|
|
||||||
check = buf;
|
|
||||||
vendor_file.getline(buf, 1024, '\n');
|
|
||||||
subdir = buf;
|
|
||||||
vendor_file.getline(buf, 1024, '\n');
|
|
||||||
if(!(check.empty() || subdir.empty()))
|
|
||||||
vendors.push_back(Compiler(check, subdir));
|
|
||||||
else
|
|
||||||
{
|
|
||||||
cout << "Error parsing vendors, check:" << check << "\tsubdir:" << subdir << endl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
fstream header_list(argv[1]);
|
|
||||||
string header;
|
|
||||||
|
|
||||||
if(!header_list.is_open())
|
|
||||||
{
|
|
||||||
cout << "Invalid header list file, " << argv[1] << endl;
|
|
||||||
return -3;
|
|
||||||
}
|
|
||||||
while(!header_list.eof())
|
|
||||||
{
|
|
||||||
header_list >> header;
|
|
||||||
cout << header << endl;
|
|
||||||
fstream header_file(header.c_str(), ios::out);
|
|
||||||
if(!header_file.is_open())
|
|
||||||
{
|
|
||||||
cout << "Unable to open header file for output: " << header << endl;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
string start(string("// Generated header: ")+header+'\n');
|
|
||||||
string line(start.size(),'/');
|
|
||||||
|
|
||||||
header_file << line << '\n';
|
|
||||||
header_file << start;
|
|
||||||
header_file << "// Forwards to the appropriate code\n";
|
|
||||||
header_file << "// that works on the detected compiler\n";
|
|
||||||
time_t rawtime;
|
|
||||||
time(&rawtime);
|
|
||||||
header_file << "// Generated on " << ctime(&rawtime);
|
|
||||||
header_file << line << "\n\n";
|
|
||||||
|
|
||||||
cv_type::iterator it=vendors.begin(), itEnd = vendors.end();
|
|
||||||
|
|
||||||
header_file << "#ifdef LOKI_USE_REFERENCE\n";
|
|
||||||
header_file << "#\tinclude \"Reference/" << header << "\"\n";
|
|
||||||
header_file << "#else\n";
|
|
||||||
|
|
||||||
header_file << "#\tif " << it->version_test << endl;
|
|
||||||
header_file << "#\t\tinclude \"" << it->subdir << "/" << header << "\"\n";
|
|
||||||
++it;
|
|
||||||
for(; it!=itEnd; ++it)
|
|
||||||
{
|
|
||||||
header_file << "#\telif " << it->version_test << endl;
|
|
||||||
header_file << "#\t\tinclude \"" << it->subdir;
|
|
||||||
header_file << "/" << header << "\"\n";
|
|
||||||
}
|
|
||||||
header_file << "#\telse\n";
|
|
||||||
header_file << "#\t\tinclude \"Reference/" << header << "\"\n";
|
|
||||||
header_file << "#\tendif\n";
|
|
||||||
header_file << "#endif\n";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
// Change log:
|
|
||||||
// September 16, 2002: Changed it to only test for compilers where ports exist,
|
|
||||||
// else use the Reference version. It used to give an error if used on a
|
|
||||||
// compiler that wasn't tested for. Also removed "./".
|
|
||||||
// It still needs to test for Intel and Metrowerks, as these define _MSC_VER,
|
|
||||||
// too. T.S.
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
|
@ -1,21 +0,0 @@
|
||||||
Microsoft Visual Studio Solution File, Format Version 7.00
|
|
||||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HeaderGen", "HeaderGen.vcproj", "{402B97D0-B8F8-4B89-97AC-F031849FD94E}"
|
|
||||||
EndProject
|
|
||||||
Global
|
|
||||||
GlobalSection(SolutionConfiguration) = preSolution
|
|
||||||
ConfigName.0 = Debug
|
|
||||||
ConfigName.1 = Release
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(ProjectDependencies) = postSolution
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(ProjectConfiguration) = postSolution
|
|
||||||
{402B97D0-B8F8-4B89-97AC-F031849FD94E}.Debug.ActiveCfg = Debug|Win32
|
|
||||||
{402B97D0-B8F8-4B89-97AC-F031849FD94E}.Debug.Build.0 = Debug|Win32
|
|
||||||
{402B97D0-B8F8-4B89-97AC-F031849FD94E}.Release.ActiveCfg = Release|Win32
|
|
||||||
{402B97D0-B8F8-4B89-97AC-F031849FD94E}.Release.Build.0 = Release|Win32
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
|
||||||
EndGlobalSection
|
|
||||||
GlobalSection(ExtensibilityAddIns) = postSolution
|
|
||||||
EndGlobalSection
|
|
||||||
EndGlobal
|
|
|
@ -1,129 +0,0 @@
|
||||||
<?xml version="1.0" encoding = "Windows-1252"?>
|
|
||||||
<VisualStudioProject
|
|
||||||
ProjectType="Visual C++"
|
|
||||||
Version="7.00"
|
|
||||||
Name="HeaderGen"
|
|
||||||
ProjectGUID="{402B97D0-B8F8-4B89-97AC-F031849FD94E}"
|
|
||||||
Keyword="Win32Proj">
|
|
||||||
<Platforms>
|
|
||||||
<Platform
|
|
||||||
Name="Win32"/>
|
|
||||||
</Platforms>
|
|
||||||
<Configurations>
|
|
||||||
<Configuration
|
|
||||||
Name="Debug|Win32"
|
|
||||||
OutputDirectory="Debug"
|
|
||||||
IntermediateDirectory="Debug"
|
|
||||||
ConfigurationType="1"
|
|
||||||
CharacterSet="2">
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
Optimization="0"
|
|
||||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
|
|
||||||
MinimalRebuild="TRUE"
|
|
||||||
BasicRuntimeChecks="3"
|
|
||||||
RuntimeLibrary="5"
|
|
||||||
UsePrecompiledHeader="0"
|
|
||||||
WarningLevel="3"
|
|
||||||
Detect64BitPortabilityProblems="TRUE"
|
|
||||||
DebugInformationFormat="4"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCCustomBuildTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCLinkerTool"
|
|
||||||
OutputFile="$(OutDir)/HeaderGen.exe"
|
|
||||||
LinkIncremental="2"
|
|
||||||
GenerateDebugInformation="TRUE"
|
|
||||||
ProgramDatabaseFile="$(OutDir)/HeaderGen.pdb"
|
|
||||||
SubSystem="1"
|
|
||||||
TargetMachine="1"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCMIDLTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPostBuildEventTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreBuildEventTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreLinkEventTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCResourceCompilerTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebServiceProxyGeneratorTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebDeploymentTool"/>
|
|
||||||
</Configuration>
|
|
||||||
<Configuration
|
|
||||||
Name="Release|Win32"
|
|
||||||
OutputDirectory="Release"
|
|
||||||
IntermediateDirectory="Release"
|
|
||||||
ConfigurationType="1"
|
|
||||||
CharacterSet="2">
|
|
||||||
<Tool
|
|
||||||
Name="VCCLCompilerTool"
|
|
||||||
Optimization="2"
|
|
||||||
InlineFunctionExpansion="1"
|
|
||||||
OmitFramePointers="TRUE"
|
|
||||||
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
|
|
||||||
StringPooling="TRUE"
|
|
||||||
RuntimeLibrary="4"
|
|
||||||
EnableFunctionLevelLinking="TRUE"
|
|
||||||
UsePrecompiledHeader="0"
|
|
||||||
WarningLevel="3"
|
|
||||||
Detect64BitPortabilityProblems="TRUE"
|
|
||||||
DebugInformationFormat="3"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCCustomBuildTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCLinkerTool"
|
|
||||||
OutputFile="$(OutDir)/HeaderGen.exe"
|
|
||||||
LinkIncremental="1"
|
|
||||||
GenerateDebugInformation="TRUE"
|
|
||||||
SubSystem="1"
|
|
||||||
OptimizeReferences="2"
|
|
||||||
EnableCOMDATFolding="2"
|
|
||||||
TargetMachine="1"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCMIDLTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPostBuildEventTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreBuildEventTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCPreLinkEventTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCResourceCompilerTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebServiceProxyGeneratorTool"/>
|
|
||||||
<Tool
|
|
||||||
Name="VCWebDeploymentTool"/>
|
|
||||||
</Configuration>
|
|
||||||
</Configurations>
|
|
||||||
<Files>
|
|
||||||
<Filter
|
|
||||||
Name="Source Files"
|
|
||||||
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm">
|
|
||||||
<File
|
|
||||||
RelativePath="HeaderGen.cpp">
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Header Files"
|
|
||||||
Filter="h;hpp;hxx;hm;inl;inc">
|
|
||||||
<File
|
|
||||||
RelativePath="C:\Program Files\Microsoft Visual Studio .NET\Vc7\include\fstream">
|
|
||||||
</File>
|
|
||||||
<File
|
|
||||||
RelativePath="C:\Program Files\Microsoft Visual Studio .NET\Vc7\include\iostream">
|
|
||||||
</File>
|
|
||||||
</Filter>
|
|
||||||
<Filter
|
|
||||||
Name="Resource Files"
|
|
||||||
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
|
|
||||||
</Filter>
|
|
||||||
<File
|
|
||||||
RelativePath="ReadMe.txt">
|
|
||||||
</File>
|
|
||||||
</Files>
|
|
||||||
<Globals>
|
|
||||||
</Globals>
|
|
||||||
</VisualStudioProject>
|
|
|
@ -1,22 +0,0 @@
|
||||||
AbstractFactory.h
|
|
||||||
AssocVector.h
|
|
||||||
DataGenerators.h
|
|
||||||
EmptyType.h
|
|
||||||
Factory.h
|
|
||||||
Functor.h
|
|
||||||
HierarchyGenerators.h
|
|
||||||
MultiMethods.h
|
|
||||||
NullType.h
|
|
||||||
Singleton.h
|
|
||||||
SmallObj.h
|
|
||||||
SmartPtr.h
|
|
||||||
static_check.h
|
|
||||||
Threads.h
|
|
||||||
Tuple.h
|
|
||||||
LokiTypeInfo.h
|
|
||||||
Typelist.h
|
|
||||||
TypeManip.h
|
|
||||||
TypeTraits.h
|
|
||||||
Visitor.h
|
|
||||||
Singleton.cpp
|
|
||||||
SmallObj.cpp
|
|
|
@ -1,3 +0,0 @@
|
||||||
Cheesy vector-header generation tool
|
|
||||||
Yes, I'm that lazy
|
|
||||||
MKH
|
|
|
@ -1,17 +0,0 @@
|
||||||
(__INTEL_COMPILER)
|
|
||||||
Reference
|
|
||||||
|
|
||||||
(__MWERKS__)
|
|
||||||
Reference
|
|
||||||
|
|
||||||
(__BORLANDC__ >= 0x560)
|
|
||||||
Borland
|
|
||||||
|
|
||||||
(_MSC_VER >= 1301)
|
|
||||||
Reference
|
|
||||||
|
|
||||||
(_MSC_VER >= 1300)
|
|
||||||
MSVC/1300
|
|
||||||
|
|
||||||
(_MSC_VER >= 1200)
|
|
||||||
MSVC/1200
|
|
Loading…
Add table
Add a link
Reference in a new issue