--- /dev/null
- if ( importedModule.type == ObjectLibrary )\r
+#include "../../pch.h"\r
+#include <assert.h>\r
+\r
+#include "../../rbuild.h"\r
+#include "mingw.h"\r
+#include "modulehandler.h"\r
+\r
+using std::string;\r
+using std::vector;\r
+\r
+#define CLEAN_FILE(f) clean_files.push_back ( f ); /*if ( module.name == "crt" ) printf ( "%s(%i): clean: %s\n", __FILE__, __LINE__, f.c_str() )*/\r
+\r
+static string ros_temp = "$(TEMPORARY)";\r
+MingwBackend*\r
+MingwModuleHandler::backend = NULL;\r
+FILE*\r
+MingwModuleHandler::fMakefile = NULL;\r
+bool\r
+MingwModuleHandler::use_pch = false;\r
+\r
+string\r
+PrefixFilename (\r
+ const string& filename,\r
+ const string& prefix )\r
+{\r
+ if ( !prefix.length() )\r
+ return filename;\r
+ string out;\r
+ const char* pfilename = filename.c_str();\r
+ const char* p1 = strrchr ( pfilename, '/' );\r
+ const char* p2 = strrchr ( pfilename, '\\' );\r
+ if ( p1 || p2 )\r
+ {\r
+ if ( p2 > p1 )\r
+ p1 = p2;\r
+ out += string(pfilename,p1-pfilename) + CSEP;\r
+ pfilename = p1 + 1;\r
+ }\r
+ out += prefix + pfilename;\r
+ return out;\r
+}\r
+\r
+string\r
+GetTargetMacro ( const Module& module, bool with_dollar )\r
+{\r
+ string s ( module.name );\r
+ strupr ( &s[0] );\r
+ s += "_TARGET";\r
+ if ( with_dollar )\r
+ return ssprintf ( "$(%s)", s.c_str() );\r
+ return s;\r
+}\r
+\r
+MingwModuleHandler::MingwModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : module(module_)\r
+{\r
+}\r
+\r
+MingwModuleHandler::~MingwModuleHandler()\r
+{\r
+}\r
+\r
+/*static*/ void\r
+MingwModuleHandler::SetBackend ( MingwBackend* backend_ )\r
+{\r
+ backend = backend_;\r
+}\r
+\r
+/*static*/ void\r
+MingwModuleHandler::SetMakefile ( FILE* f )\r
+{\r
+ fMakefile = f;\r
+}\r
+\r
+/*static*/ void\r
+MingwModuleHandler::SetUsePch ( bool b )\r
+{\r
+ use_pch = b;\r
+}\r
+\r
+/* static*/ string\r
+MingwModuleHandler::RemoveVariables ( string path)\r
+{\r
+ size_t i = path.find ( '$' );\r
+ if ( i != string::npos )\r
+ {\r
+ size_t j = path.find ( ')', i );\r
+ if ( j != string::npos )\r
+ {\r
+ if ( j + 2 < path.length () && path[j + 1] == CSEP )\r
+ return path.substr ( j + 2);\r
+ else\r
+ return path.substr ( j + 1);\r
+ }\r
+ }\r
+ return path;\r
+}\r
+\r
+/*static*/ string\r
+MingwModuleHandler::PassThruCacheDirectory (\r
+ const string &file,\r
+ Directory* directoryTree )\r
+{\r
+ string directory ( GetDirectory ( RemoveVariables ( file ) ) );\r
+ string generatedFilesDirectory = backend->AddDirectoryTarget ( directory,\r
+ directoryTree );\r
+ if ( directory.find ( generatedFilesDirectory ) != string::npos )\r
+ /* This path already includes the generated files directory variable */\r
+ return file;\r
+ else\r
+ return generatedFilesDirectory + SSEP + file;\r
+}\r
+\r
+/*static*/ string\r
+MingwModuleHandler::GetTargetFilename (\r
+ const Module& module,\r
+ string_list* pclean_files )\r
+{\r
+ string target = PassThruCacheDirectory (\r
+ NormalizeFilename ( module.GetPath () ),\r
+ backend->outputDirectory );\r
+ if ( pclean_files )\r
+ {\r
+ string_list& clean_files = *pclean_files;\r
+ CLEAN_FILE ( target );\r
+ }\r
+ return target;\r
+}\r
+\r
+/*static*/ string\r
+MingwModuleHandler::GetImportLibraryFilename (\r
+ const Module& module,\r
+ string_list* pclean_files )\r
+{\r
+ string target = PassThruCacheDirectory (\r
+ NormalizeFilename ( module.GetDependencyPath () ),\r
+ backend->outputDirectory );\r
+ if ( pclean_files )\r
+ {\r
+ string_list& clean_files = *pclean_files;\r
+ CLEAN_FILE ( target );\r
+ }\r
+ return target;\r
+}\r
+\r
+/*static*/ MingwModuleHandler*\r
+MingwModuleHandler::InstanciateHandler (\r
+ const Module& module,\r
+ MingwBackend* backend )\r
+{\r
+ MingwModuleHandler* handler;\r
+ switch ( module.type )\r
+ {\r
+ case BuildTool:\r
+ handler = new MingwBuildToolModuleHandler ( module );\r
+ break;\r
+ case StaticLibrary:\r
+ handler = new MingwStaticLibraryModuleHandler ( module );\r
+ break;\r
+ case ObjectLibrary:\r
+ handler = new MingwObjectLibraryModuleHandler ( module );\r
+ break;\r
+ case Kernel:\r
+ handler = new MingwKernelModuleHandler ( module );\r
+ break;\r
+ case NativeCUI:\r
+ handler = new MingwNativeCUIModuleHandler ( module );\r
+ break;\r
+ case Win32CUI:\r
+ handler = new MingwWin32CUIModuleHandler ( module );\r
+ break;\r
+ case Win32GUI:\r
+ handler = new MingwWin32GUIModuleHandler ( module );\r
+ break;\r
+ case KernelModeDLL:\r
+ handler = new MingwKernelModeDLLModuleHandler ( module );\r
+ break;\r
+ case NativeDLL:\r
+ handler = new MingwNativeDLLModuleHandler ( module );\r
+ break;\r
+ case Win32DLL:\r
+ handler = new MingwWin32DLLModuleHandler ( module );\r
+ break;\r
+ case KernelModeDriver:\r
+ handler = new MingwKernelModeDriverModuleHandler ( module );\r
+ break;\r
+ case BootLoader:\r
+ handler = new MingwBootLoaderModuleHandler ( module );\r
+ break;\r
+ case BootSector:\r
+ handler = new MingwBootSectorModuleHandler ( module );\r
+ break;\r
+ case Iso:\r
+ handler = new MingwIsoModuleHandler ( module );\r
+ break;\r
+ case Test:\r
+ handler = new MingwTestModuleHandler ( module );\r
+ break;\r
++ case RpcServer:\r
++ handler = new MingwRpcServerModuleHandler ( module );\r
++ break;\r
++ case RpcClient:\r
++ handler = new MingwRpcClientModuleHandler ( module );\r
++ break;\r
+ default:\r
+ throw UnknownModuleTypeException (\r
+ module.node.location,\r
+ module.type );\r
+ break;\r
+ }\r
+ return handler;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetWorkingDirectory () const\r
+{\r
+ return ".";\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetBasename ( const string& filename ) const\r
+{\r
+ size_t index = filename.find_last_of ( '.' );\r
+ if ( index != string::npos )\r
+ return filename.substr ( 0, index );\r
+ return "";\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetActualSourceFilename (\r
+ const string& filename ) const\r
+{\r
+ string extension = GetExtension ( filename );\r
+ if ( extension == ".spec" || extension == ".SPEC" )\r
+ {\r
+ string basename = GetBasename ( filename );\r
+ return PassThruCacheDirectory ( NormalizeFilename ( basename + ".stubs.c" ),\r
+ backend->intermediateDirectory );\r
+ }\r
++ else if ( extension == ".idl" || extension == ".IDL" )\r
++ {\r
++ string basename = GetBasename ( filename );\r
++ string newname;\r
++ if ( module.type == RpcServer )\r
++ newname = basename + "_s.c";\r
++ else\r
++ newname = basename + "_c.c";\r
++ return PassThruCacheDirectory ( NormalizeFilename ( newname ),\r
++ backend->intermediateDirectory );\r
++ }\r
+ else\r
+ return filename;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetModuleArchiveFilename () const\r
+{\r
+ if ( module.type == StaticLibrary )\r
+ return GetTargetFilename ( module, NULL );\r
+ return PassThruCacheDirectory ( ReplaceExtension (\r
+ NormalizeFilename ( module.GetPath () ),\r
+ ".temp.a" ),\r
+ backend->intermediateDirectory );\r
+}\r
+\r
+bool\r
+MingwModuleHandler::IsGeneratedFile ( const File& file ) const\r
+{\r
+ string extension = GetExtension ( file.name );\r
+ return ( extension == ".spec" || extension == ".SPEC" );\r
+}\r
+\r
++/*static*/ bool\r
++MingwModuleHandler::ReferenceObjects (\r
++ const Module& module )\r
++{\r
++ if ( module.type == ObjectLibrary )\r
++ return true;\r
++ if ( module.type == RpcServer )\r
++ return true;\r
++ if ( module.type == RpcClient )\r
++ return true;\r
++ return false;\r
++}\r
++\r
+string\r
+MingwModuleHandler::GetImportLibraryDependency (\r
+ const Module& importedModule )\r
+{\r
+ string dep;\r
- // TODO FIXME - do we *really* not want to call\r
- // GetDefinitionDependencies() if dependencies.size() == 0 ???\r
++ if ( ReferenceObjects ( importedModule ) )\r
+ dep = GetTargetMacro ( importedModule );\r
+ else\r
+ dep = GetImportLibraryFilename ( importedModule, NULL );\r
+ return dep;\r
+}\r
+\r
++void\r
++MingwModuleHandler::GetTargets ( const Module& dependencyModule,\r
++ string_list& targets )\r
++{\r
++ if ( dependencyModule.invocations.size () > 0 )\r
++ {\r
++ for ( size_t i = 0; i < dependencyModule.invocations.size (); i++ )\r
++ {\r
++ Invoke& invoke = *dependencyModule.invocations[i];\r
++ invoke.GetTargets ( targets );\r
++ }\r
++ }\r
++ else\r
++ targets.push_back ( GetImportLibraryDependency ( dependencyModule ) );\r
++}\r
++\r
+void\r
+MingwModuleHandler::GetModuleDependencies (\r
+ string_list& dependencies )\r
+{\r
+ size_t iend = module.dependencies.size ();\r
+\r
- dependencyModule.GetTargets ( dependencies );\r
+ if ( iend == 0 )\r
+ return;\r
+ \r
+ for ( size_t i = 0; i < iend; i++ )\r
+ {\r
+ const Dependency& dependency = *module.dependencies[i];\r
+ const Module& dependencyModule = *dependency.dependencyModule;\r
- fprintf ( fMakefile,\r
- "%s: %s $(WRC_TARGET) | %s\n",\r
- objectFilename.c_str (),\r
- sourceFilename.c_str (),\r
- GetDirectory ( objectFilename ).c_str () );\r
- fprintf ( fMakefile, "\t$(ECHO_WRC)\n" );\r
- fprintf ( fMakefile,\r
- "\t${gcc} -xc -E -DRC_INVOKED ${%s} %s > %s\n",\r
- windresflagsMacro.c_str (),\r
- sourceFilename.c_str (),\r
- rciFilename.c_str () );\r
- fprintf ( fMakefile,\r
- "\t$(Q)$(WRC_TARGET) ${%s} %s %s\n",\r
- windresflagsMacro.c_str (),\r
- rciFilename.c_str (),\r
- resFilename.c_str () );\r
- fprintf ( fMakefile,\r
- "\t-@${rm} %s 2>$(NUL)\n",\r
- rciFilename.c_str () );\r
- fprintf ( fMakefile,\r
- "\t${windres} %s -o $@\n",\r
- resFilename.c_str () );\r
- fprintf ( fMakefile,\r
- "\t-@${rm} %s 2>$(NUL)\n",\r
- resFilename.c_str () );\r
++ GetTargets ( dependencyModule,\r
++ dependencies );\r
+ }\r
+ GetDefinitionDependencies ( dependencies );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GetSourceFilenames (\r
+ string_list& list,\r
+ bool includeGeneratedFiles ) const\r
+{\r
+ size_t i;\r
+\r
+ const vector<File*>& files = module.non_if_data.files;\r
+ for ( i = 0; i < files.size (); i++ )\r
+ {\r
+ if ( includeGeneratedFiles || !IsGeneratedFile ( *files[i] ) )\r
+ {\r
+ list.push_back (\r
+ GetActualSourceFilename ( files[i]->name ) );\r
+ }\r
+ }\r
+ // intentionally make a copy so that we can append more work in\r
+ // the middle of processing without having to go recursive\r
+ vector<If*> v = module.non_if_data.ifs;\r
+ for ( i = 0; i < v.size (); i++ )\r
+ {\r
+ size_t j;\r
+ If& rIf = *v[i];\r
+ // check for sub-ifs to add to list\r
+ const vector<If*>& ifs = rIf.data.ifs;\r
+ for ( j = 0; j < ifs.size (); j++ )\r
+ v.push_back ( ifs[j] );\r
+ const vector<File*>& files = rIf.data.files;\r
+ for ( j = 0; j < files.size (); j++ )\r
+ {\r
+ File& file = *files[j];\r
+ if ( includeGeneratedFiles || !IsGeneratedFile ( file ) )\r
+ {\r
+ list.push_back (\r
+ GetActualSourceFilename ( file.name ) );\r
+ }\r
+ }\r
+ }\r
+}\r
+\r
+void\r
+MingwModuleHandler::GetSourceFilenamesWithoutGeneratedFiles (\r
+ string_list& list ) const\r
+{\r
+ GetSourceFilenames ( list, false );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetObjectFilename (\r
+ const string& sourceFilename,\r
+ string_list* pclean_files ) const\r
+{\r
+ Directory* directoryTree;\r
+\r
+ string newExtension;\r
+ string extension = GetExtension ( sourceFilename );\r
+ if ( extension == ".rc" || extension == ".RC" )\r
+ newExtension = ".coff";\r
+ else if ( extension == ".spec" || extension == ".SPEC" )\r
+ newExtension = ".stubs.o";\r
++ else if ( extension == ".idl" || extension == ".IDL" )\r
++ {\r
++ if ( module.type == RpcServer )\r
++ newExtension = "_s.o";\r
++ else\r
++ newExtension = "_c.o";\r
++ }\r
+ else\r
+ newExtension = ".o";\r
+ \r
+ if ( module.type == BootSector )\r
+ directoryTree = backend->outputDirectory;\r
+ else\r
+ directoryTree = backend->intermediateDirectory;\r
+\r
+ string obj_file = PassThruCacheDirectory (\r
+ NormalizeFilename ( ReplaceExtension (\r
+ RemoveVariables ( sourceFilename ),\r
+ newExtension ) ),\r
+ directoryTree );\r
+ if ( pclean_files )\r
+ {\r
+ string_list& clean_files = *pclean_files;\r
+ CLEAN_FILE ( obj_file );\r
+ }\r
+ return obj_file;\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateCleanTarget () const\r
+{\r
+ if ( 0 == clean_files.size() )\r
+ return;\r
+ fprintf ( fMakefile, ".PHONY: %s_clean\n", module.name.c_str() );\r
+ fprintf ( fMakefile, "%s_clean:\n\t-@$(rm)", module.name.c_str() );\r
+ for ( size_t i = 0; i < clean_files.size(); i++ )\r
+ {\r
+ if ( 9==((i+1)%10) )\r
+ fprintf ( fMakefile, " 2>$(NUL)\n\t-@$(rm)" );\r
+ fprintf ( fMakefile, " %s", clean_files[i].c_str() );\r
+ }\r
+ fprintf ( fMakefile, " 2>$(NUL)\n" );\r
+ fprintf ( fMakefile, "clean: %s_clean\n\n", module.name.c_str() );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetObjectFilenames ()\r
+{\r
+ const vector<File*>& files = module.non_if_data.files;\r
+ if ( files.size () == 0 )\r
+ return "";\r
+ \r
+ string objectFilenames ( "" );\r
+ for ( size_t i = 0; i < files.size (); i++ )\r
+ {\r
+ if ( objectFilenames.size () > 0 )\r
+ objectFilenames += " ";\r
+ objectFilenames +=\r
+ GetObjectFilename ( files[i]->name, NULL );\r
+ }\r
+ return objectFilenames;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateGccDefineParametersFromVector (\r
+ const vector<Define*>& defines ) const\r
+{\r
+ string parameters;\r
+ for ( size_t i = 0; i < defines.size (); i++ )\r
+ {\r
+ Define& define = *defines[i];\r
+ if (parameters.length () > 0)\r
+ parameters += " ";\r
+ parameters += "-D";\r
+ parameters += define.name;\r
+ if (define.value.length () > 0)\r
+ {\r
+ parameters += "=";\r
+ parameters += define.value;\r
+ }\r
+ }\r
+ return parameters;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateGccDefineParameters () const\r
+{\r
+ string parameters = GenerateGccDefineParametersFromVector ( module.project.non_if_data.defines );\r
+ string s = GenerateGccDefineParametersFromVector ( module.non_if_data.defines );\r
+ if ( s.length () > 0 )\r
+ {\r
+ parameters += " ";\r
+ parameters += s;\r
+ }\r
+ return parameters;\r
+}\r
+\r
+string\r
+MingwModuleHandler::ConcatenatePaths (\r
+ const string& path1,\r
+ const string& path2 ) const\r
+{\r
+ if ( ( path1.length () == 0 ) || ( path1 == "." ) || ( path1 == "./" ) )\r
+ return path2;\r
+ if ( path1[path1.length ()] == CSEP )\r
+ return path1 + path2;\r
+ else\r
+ return path1 + CSEP + path2;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateGccIncludeParametersFromVector ( const vector<Include*>& includes ) const\r
+{\r
+ string parameters;\r
+ for ( size_t i = 0; i < includes.size (); i++ )\r
+ {\r
+ Include& include = *includes[i];\r
+ if ( parameters.length () > 0 )\r
+ parameters += " ";\r
+ parameters += "-I" + include.directory;\r
+ }\r
+ return parameters;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateGccIncludeParameters () const\r
+{\r
+ string parameters = GenerateGccIncludeParametersFromVector ( module.non_if_data.includes );\r
+ string s = GenerateGccIncludeParametersFromVector ( module.project.non_if_data.includes );\r
+ if ( s.length () > 0 )\r
+ {\r
+ parameters += " ";\r
+ parameters += s;\r
+ }\r
+ return parameters;\r
+}\r
+\r
+\r
+string\r
+MingwModuleHandler::GenerateCompilerParametersFromVector ( const vector<CompilerFlag*>& compilerFlags ) const\r
+{\r
+ string parameters;\r
+ for ( size_t i = 0; i < compilerFlags.size (); i++ )\r
+ {\r
+ CompilerFlag& compilerFlag = *compilerFlags[i];\r
+ if ( parameters.length () > 0 )\r
+ parameters += " ";\r
+ parameters += compilerFlag.flag;\r
+ }\r
+ return parameters;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateLinkerParametersFromVector ( const vector<LinkerFlag*>& linkerFlags ) const\r
+{\r
+ string parameters;\r
+ for ( size_t i = 0; i < linkerFlags.size (); i++ )\r
+ {\r
+ LinkerFlag& linkerFlag = *linkerFlags[i];\r
+ if ( parameters.length () > 0 )\r
+ parameters += " ";\r
+ parameters += linkerFlag.flag;\r
+ }\r
+ return parameters;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateImportLibraryDependenciesFromVector (\r
+ const vector<Library*>& libraries )\r
+{\r
+ string dependencies ( "" );\r
+ int wrap_count = 0;\r
+ for ( size_t i = 0; i < libraries.size (); i++ )\r
+ {\r
+ if ( wrap_count++ == 5 )\r
+ dependencies += " \\\n\t\t", wrap_count = 0;\r
+ else if ( dependencies.size () > 0 )\r
+ dependencies += " ";\r
+ dependencies += GetImportLibraryDependency ( *libraries[i]->imported_module );\r
+ }\r
+ return dependencies;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateLinkerParameters () const\r
+{\r
+ return GenerateLinkerParametersFromVector ( module.linkerFlags );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateMacro (\r
+ const char* assignmentOperation,\r
+ const string& macro,\r
+ const IfableData& data,\r
+ const vector<CompilerFlag*>* compilerFlags )\r
+{\r
+ size_t i;\r
+\r
+ fprintf (\r
+ fMakefile,\r
+ "%s %s",\r
+ macro.c_str(),\r
+ assignmentOperation );\r
+ \r
+ if ( compilerFlags != NULL )\r
+ {\r
+ string compilerParameters = GenerateCompilerParametersFromVector ( *compilerFlags );\r
+ if ( compilerParameters.size () > 0 )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ " %s",\r
+ compilerParameters.c_str () );\r
+ }\r
+ }\r
+\r
+ for ( i = 0; i < data.includes.size(); i++ )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ " -I%s",\r
+ data.includes[i]->directory.c_str() );\r
+ }\r
+ for ( i = 0; i < data.defines.size(); i++ )\r
+ {\r
+ Define& d = *data.defines[i];\r
+ fprintf (\r
+ fMakefile,\r
+ " -D%s",\r
+ d.name.c_str() );\r
+ if ( d.value.size() )\r
+ fprintf (\r
+ fMakefile,\r
+ "=%s",\r
+ d.value.c_str() );\r
+ }\r
+ fprintf ( fMakefile, "\n" );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateMacros (\r
+ const char* assignmentOperation,\r
+ const IfableData& data,\r
+ const vector<CompilerFlag*>* compilerFlags,\r
+ const vector<LinkerFlag*>* linkerFlags )\r
+{\r
+ size_t i;\r
+\r
+ if ( data.includes.size () > 0 || data.defines.size () > 0 )\r
+ {\r
+ GenerateMacro ( assignmentOperation,\r
+ cflagsMacro,\r
+ data,\r
+ compilerFlags );\r
+ GenerateMacro ( assignmentOperation,\r
+ windresflagsMacro,\r
+ data,\r
+ compilerFlags );\r
+ }\r
+ \r
+ if ( linkerFlags != NULL )\r
+ {\r
+ string linkerParameters = GenerateLinkerParametersFromVector ( *linkerFlags );\r
+ if ( linkerParameters.size () > 0 )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ "%s %s %s\n",\r
+ linkerflagsMacro.c_str (),\r
+ assignmentOperation,\r
+ linkerParameters.c_str() );\r
+ }\r
+ }\r
+\r
+ if ( data.libraries.size () > 0 )\r
+ {\r
+ string deps = GenerateImportLibraryDependenciesFromVector ( data.libraries );\r
+ if ( deps.size () > 0 )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ "%s %s %s\n",\r
+ libsMacro.c_str(),\r
+ assignmentOperation,\r
+ deps.c_str() );\r
+ }\r
+ }\r
+\r
+ const vector<If*>& ifs = data.ifs;\r
+ for ( i = 0; i < ifs.size(); i++ )\r
+ {\r
+ If& rIf = *ifs[i];\r
+ if ( rIf.data.defines.size()\r
+ || rIf.data.includes.size()\r
+ || rIf.data.libraries.size()\r
+ || rIf.data.files.size()\r
+ || rIf.data.ifs.size() )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ "ifeq (\"$(%s)\",\"%s\")\n",\r
+ rIf.property.c_str(),\r
+ rIf.value.c_str() );\r
+ GenerateMacros (\r
+ "+=",\r
+ rIf.data,\r
+ NULL,\r
+ NULL );\r
+ fprintf ( \r
+ fMakefile,\r
+ "endif\n\n" );\r
+ }\r
+ }\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateObjectMacros (\r
+ const char* assignmentOperation,\r
+ const IfableData& data,\r
+ const vector<CompilerFlag*>* compilerFlags,\r
+ const vector<LinkerFlag*>* linkerFlags )\r
+{\r
+ size_t i;\r
+\r
+ const vector<File*>& files = data.files;\r
+ if ( files.size () > 0 )\r
+ {\r
+ for ( i = 0; i < files.size (); i++ )\r
+ {\r
+ File& file = *files[i];\r
+ if ( file.first )\r
+ {\r
+ fprintf ( fMakefile,\r
+ "%s := %s $(%s)\n",\r
+ objectsMacro.c_str(),\r
+ GetObjectFilename (\r
+ file.name, NULL ).c_str (),\r
+ objectsMacro.c_str() );\r
+ }\r
+ }\r
+ fprintf (\r
+ fMakefile,\r
+ "%s %s",\r
+ objectsMacro.c_str (),\r
+ assignmentOperation );\r
+ for ( i = 0; i < files.size(); i++ )\r
+ {\r
+ File& file = *files[i];\r
+ if ( !file.first )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ "%s%s",\r
+ ( i%10 == 9 ? " \\\n\t" : " " ),\r
+ GetObjectFilename (\r
+ file.name, NULL ).c_str () );\r
+ }\r
+ }\r
+ fprintf ( fMakefile, "\n" );\r
+ }\r
+\r
+ const vector<If*>& ifs = data.ifs;\r
+ for ( i = 0; i < ifs.size(); i++ )\r
+ {\r
+ If& rIf = *ifs[i];\r
+ if ( rIf.data.defines.size()\r
+ || rIf.data.includes.size()\r
+ || rIf.data.libraries.size()\r
+ || rIf.data.files.size()\r
+ || rIf.data.ifs.size() )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ "ifeq (\"$(%s)\",\"%s\")\n",\r
+ rIf.property.c_str(),\r
+ rIf.value.c_str() );\r
+ GenerateObjectMacros (\r
+ "+=",\r
+ rIf.data,\r
+ NULL,\r
+ NULL );\r
+ fprintf ( \r
+ fMakefile,\r
+ "endif\n\n" );\r
+ }\r
+ }\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateGccCommand (\r
+ const string& sourceFilename,\r
+ const string& cc,\r
+ const string& cflagsMacro )\r
+{\r
+ string deps = sourceFilename;\r
+ if ( module.pch && use_pch )\r
+ deps += " " + module.pch->header + ".gch";\r
++ \r
++ /* WIDL generated headers may be used */\r
++ deps += " " + GetLinkingDependenciesMacro ();\r
++\r
+ string objectFilename = GetObjectFilename (\r
+ sourceFilename, &clean_files );\r
+ fprintf ( fMakefile,\r
+ "%s: %s | %s\n",\r
+ objectFilename.c_str (),\r
+ deps.c_str (),\r
+ GetDirectory ( objectFilename ).c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_CC)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t%s -c $< -o $@ %s\n",\r
+ cc.c_str (),\r
+ cflagsMacro.c_str () );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateGccAssemblerCommand (\r
+ const string& sourceFilename,\r
+ const string& cc,\r
+ const string& cflagsMacro )\r
+{\r
+ string objectFilename = GetObjectFilename (\r
+ sourceFilename, &clean_files );\r
+ fprintf ( fMakefile,\r
+ "%s: %s | %s\n",\r
+ objectFilename.c_str (),\r
+ sourceFilename.c_str (),\r
+ GetDirectory ( objectFilename ).c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_GAS)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t%s -x assembler-with-cpp -c $< -o $@ -D__ASM__ %s\n",\r
+ cc.c_str (),\r
+ cflagsMacro.c_str () );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateNasmCommand (\r
+ const string& sourceFilename,\r
+ const string& nasmflagsMacro )\r
+{\r
+ string objectFilename = GetObjectFilename (\r
+ sourceFilename, &clean_files );\r
+ fprintf ( fMakefile,\r
+ "%s: %s | %s\n",\r
+ objectFilename.c_str (),\r
+ sourceFilename.c_str (),\r
+ GetDirectory ( objectFilename ).c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_NASM)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t%s -f win32 $< -o $@ %s\n",\r
+ "$(Q)nasm",\r
+ nasmflagsMacro.c_str () );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateWindresCommand (\r
+ const string& sourceFilename,\r
+ const string& windresflagsMacro )\r
+{\r
+ string objectFilename =\r
+ GetObjectFilename ( sourceFilename, &clean_files );\r
+ string rciFilename = ros_temp +\r
+ ReplaceExtension ( sourceFilename, ".rci" );\r
+ string resFilename = ros_temp +\r
+ ReplaceExtension ( sourceFilename, ".res" );\r
- const string& windresflagsMacro )\r
++ if ( module.useWRC )\r
++ {\r
++ fprintf ( fMakefile,\r
++ "%s: %s $(WRC_TARGET) | %s\n",\r
++ objectFilename.c_str (),\r
++ sourceFilename.c_str (),\r
++ GetDirectory ( objectFilename ).c_str () );\r
++ fprintf ( fMakefile, "\t$(ECHO_WRC)\n" );\r
++ fprintf ( fMakefile,\r
++ "\t${gcc} -xc -E -DRC_INVOKED ${%s} %s > %s\n",\r
++ windresflagsMacro.c_str (),\r
++ sourceFilename.c_str (),\r
++ rciFilename.c_str () );\r
++ fprintf ( fMakefile,\r
++ "\t$(Q)$(WRC_TARGET) ${%s} %s %s\n",\r
++ windresflagsMacro.c_str (),\r
++ rciFilename.c_str (),\r
++ resFilename.c_str () );\r
++ fprintf ( fMakefile,\r
++ "\t-@${rm} %s 2>$(NUL)\n",\r
++ rciFilename.c_str () );\r
++ fprintf ( fMakefile,\r
++ "\t${windres} %s -o $@\n",\r
++ resFilename.c_str () );\r
++ fprintf ( fMakefile,\r
++ "\t-@${rm} %s 2>$(NUL)\n",\r
++ resFilename.c_str () );\r
++ }\r
++ else\r
++ {\r
++ fprintf ( fMakefile,\r
++ "%s: %s $(WRC_TARGET) | %s\n",\r
++ objectFilename.c_str (),\r
++ sourceFilename.c_str (),\r
++ GetDirectory ( objectFilename ).c_str () );\r
++ fprintf ( fMakefile, "\t$(ECHO_WRC)\n" );\r
++ fprintf ( fMakefile,\r
++ "\t${windres} $(%s) %s -o $@\n",\r
++ windresflagsMacro.c_str (),\r
++ sourceFilename.c_str () );\r
++ }\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateWinebuildCommands (\r
+ const string& sourceFilename )\r
+{\r
+ string basename = GetBasename ( sourceFilename );\r
+\r
+ string def_file = PassThruCacheDirectory (\r
+ basename + ".spec.def",\r
+ backend->intermediateDirectory );\r
+ CLEAN_FILE(def_file);\r
+\r
+ string stub_file = PassThruCacheDirectory (\r
+ basename + ".stubs.c",\r
+ backend->intermediateDirectory );\r
+ CLEAN_FILE(stub_file)\r
+\r
+ fprintf ( fMakefile,\r
+ "%s: %s $(WINEBUILD_TARGET)\n",\r
+ def_file.c_str (),\r
+ sourceFilename.c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_WINEBLD)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t%s --def=%s -o %s\n",\r
+ "$(Q)$(WINEBUILD_TARGET)",\r
+ sourceFilename.c_str (),\r
+ def_file.c_str () );\r
+\r
+ fprintf ( fMakefile,\r
+ "%s: %s $(WINEBUILD_TARGET)\n",\r
+ stub_file.c_str (),\r
+ sourceFilename.c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_WINEBLD)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t%s --pedll=%s -o %s\n",\r
+ "$(Q)$(WINEBUILD_TARGET)",\r
+ sourceFilename.c_str (),\r
+ stub_file.c_str () );\r
+}\r
+\r
++void\r
++MingwModuleHandler::GenerateWidlCommandsServer (\r
++ const string& sourceFilename,\r
++ const string& widlflagsMacro )\r
++{\r
++ string basename = GetBasename ( sourceFilename );\r
++\r
++ /*string generatedHeaderFilename = PassThruCacheDirectory (\r
++ basename + ".h",\r
++ backend->intermediateDirectory );\r
++ CLEAN_FILE(generatedHeaderFilename);\r
++ */\r
++ string generatedHeaderFilename = basename + "_s.h";\r
++ CLEAN_FILE(generatedHeaderFilename);\r
++\r
++ string generatedServerFilename = PassThruCacheDirectory (\r
++ basename + "_s.c",\r
++ backend->intermediateDirectory );\r
++ CLEAN_FILE(generatedServerFilename);\r
++\r
++ fprintf ( fMakefile,\r
++ "%s %s: %s $(WIDL_TARGET) | %s\n",\r
++ generatedServerFilename.c_str (),\r
++ generatedHeaderFilename.c_str (),\r
++ sourceFilename.c_str (),\r
++ GetDirectory ( generatedServerFilename ).c_str () );\r
++ fprintf ( fMakefile, "\t$(ECHO_WIDL)\n" );\r
++ fprintf ( fMakefile,\r
++ "\t%s %s -h -H %s -s -S %s %s\n",\r
++ "$(Q)$(WIDL_TARGET)",\r
++ widlflagsMacro.c_str (),\r
++ generatedHeaderFilename.c_str (),\r
++ generatedServerFilename.c_str (),\r
++ sourceFilename.c_str () );\r
++}\r
++\r
++void\r
++MingwModuleHandler::GenerateWidlCommandsClient (\r
++ const string& sourceFilename,\r
++ const string& widlflagsMacro )\r
++{\r
++ string basename = GetBasename ( sourceFilename );\r
++\r
++ /*string generatedHeaderFilename = PassThruCacheDirectory (\r
++ basename + ".h",\r
++ backend->intermediateDirectory );\r
++ CLEAN_FILE(generatedHeaderFilename);\r
++ */\r
++ string generatedHeaderFilename = basename + "_c.h";\r
++ CLEAN_FILE(generatedHeaderFilename);\r
++\r
++ string generatedClientFilename = PassThruCacheDirectory (\r
++ basename + "_c.c",\r
++ backend->intermediateDirectory );\r
++ CLEAN_FILE(generatedClientFilename);\r
++\r
++ fprintf ( fMakefile,\r
++ "%s %s: %s $(WIDL_TARGET) | %s\n",\r
++ generatedClientFilename.c_str (),\r
++ generatedHeaderFilename.c_str (),\r
++ sourceFilename.c_str (),\r
++ GetDirectory ( generatedClientFilename ).c_str () );\r
++ fprintf ( fMakefile, "\t$(ECHO_WIDL)\n" );\r
++ fprintf ( fMakefile,\r
++ "\t%s %s -h -H %s -c -C %s %s\n",\r
++ "$(Q)$(WIDL_TARGET)",\r
++ widlflagsMacro.c_str (),\r
++ generatedHeaderFilename.c_str (),\r
++ generatedClientFilename.c_str (),\r
++ sourceFilename.c_str () );\r
++}\r
++\r
++void\r
++MingwModuleHandler::GenerateWidlCommands (\r
++ const string& sourceFilename,\r
++ const string& widlflagsMacro )\r
++{\r
++ if ( module.type == RpcServer )\r
++ GenerateWidlCommandsServer ( sourceFilename,\r
++ widlflagsMacro );\r
++ else\r
++ GenerateWidlCommandsClient ( sourceFilename,\r
++ widlflagsMacro );\r
++}\r
++\r
+void\r
+MingwModuleHandler::GenerateCommands (\r
+ const string& sourceFilename,\r
+ const string& cc,\r
+ const string& cppc,\r
+ const string& cflagsMacro,\r
+ const string& nasmflagsMacro,\r
- const string& windresflagsMacro )\r
++ const string& windresflagsMacro,\r
++ const string& widlflagsMacro )\r
+{\r
+ string extension = GetExtension ( sourceFilename );\r
+ if ( extension == ".c" || extension == ".C" )\r
+ {\r
+ GenerateGccCommand ( sourceFilename,\r
+ cc,\r
+ cflagsMacro );\r
+ return;\r
+ }\r
+ else if ( extension == ".cc" || extension == ".CC" ||\r
+ extension == ".cpp" || extension == ".CPP" ||\r
+ extension == ".cxx" || extension == ".CXX" )\r
+ {\r
+ GenerateGccCommand ( sourceFilename,\r
+ cppc,\r
+ cflagsMacro );\r
+ return;\r
+ }\r
+ else if ( extension == ".s" || extension == ".S" )\r
+ {\r
+ GenerateGccAssemblerCommand ( sourceFilename,\r
+ cc,\r
+ cflagsMacro );\r
+ return;\r
+ }\r
+ else if ( extension == ".asm" || extension == ".ASM" )\r
+ {\r
+ GenerateNasmCommand ( sourceFilename,\r
+ nasmflagsMacro );\r
+ return;\r
+ }\r
+ else if ( extension == ".rc" || extension == ".RC" )\r
+ {\r
+ GenerateWindresCommand ( sourceFilename,\r
+ windresflagsMacro );\r
+ return;\r
+ }\r
+ else if ( extension == ".spec" || extension == ".SPEC" )\r
+ {\r
+ GenerateWinebuildCommands ( sourceFilename );\r
+ GenerateGccCommand ( GetActualSourceFilename ( sourceFilename ),\r
+ cc,\r
+ cflagsMacro );\r
+ return;\r
+ }\r
++ else if ( extension == ".idl" || extension == ".IDL" )\r
++ {\r
++ GenerateWidlCommands ( sourceFilename,\r
++ widlflagsMacro );\r
++ GenerateGccCommand ( GetActualSourceFilename ( sourceFilename ),\r
++ cc,\r
++ cflagsMacro );\r
++ return;\r
++ }\r
+\r
+ throw InvalidOperationException ( __FILE__,\r
+ __LINE__,\r
+ "Unsupported filename extension '%s' in file '%s'",\r
+ extension.c_str (),\r
+ sourceFilename.c_str () );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateBuildMapCode ()\r
+{\r
+ fprintf ( fMakefile,\r
+ "ifeq ($(ROS_BUILDMAP),full)\n" );\r
+\r
+ string mapFilename = PassThruCacheDirectory (\r
+ GetBasename ( module.GetPath () ) + ".map",\r
+ backend->outputDirectory );\r
+ CLEAN_FILE ( mapFilename );\r
+ \r
+ fprintf ( fMakefile,\r
+ "\t$(ECHO_OBJDUMP)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t$(Q)${objdump} -d -S $@ > %s\n",\r
+ mapFilename.c_str () );\r
+\r
+ fprintf ( fMakefile,\r
+ "else\n" );\r
+ fprintf ( fMakefile,\r
+ "ifeq ($(ROS_BUILDMAP),yes)\n" );\r
+\r
+ fprintf ( fMakefile,\r
+ "\t$(ECHO_NM)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t$(Q)${nm} --numeric-sort $@ > %s\n",\r
+ mapFilename.c_str () );\r
+\r
+ fprintf ( fMakefile,\r
+ "endif\n" );\r
+\r
+ fprintf ( fMakefile,\r
+ "endif\n" );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateLinkerCommand (\r
+ const string& dependencies,\r
+ const string& linker,\r
+ const string& linkerParameters,\r
+ const string& objectsMacro,\r
+ const string& libsMacro )\r
+{\r
+ string target ( GetTargetMacro ( module ) );\r
+ string target_folder ( GetDirectory ( GetTargetFilename ( module, NULL ) ) );\r
+\r
+ fprintf ( fMakefile,\r
+ "%s: %s $(RSYM_TARGET) | %s\n",\r
+ target.c_str (),\r
+ dependencies.c_str (),\r
+ target_folder.c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_LD)\n" );\r
+ string targetName ( module.GetTargetName () );\r
+ if ( module.importLibrary != NULL )\r
+ {\r
+ string base_tmp = ros_temp + module.name + ".base.tmp";\r
+ CLEAN_FILE ( base_tmp );\r
+ string junk_tmp = ros_temp + module.name + ".junk.tmp";\r
+ CLEAN_FILE ( junk_tmp );\r
+ string temp_exp = ros_temp + module.name + ".temp.exp";\r
+ CLEAN_FILE ( temp_exp );\r
+ string def_file = GetDefinitionFilename ();\r
+\r
+ fprintf ( fMakefile,\r
+ "\t%s %s -Wl,--base-file,%s -o %s %s %s %s\n",\r
+ linker.c_str (),\r
+ linkerParameters.c_str (),\r
+ base_tmp.c_str (),\r
+ junk_tmp.c_str (),\r
+ objectsMacro.c_str (),\r
+ libsMacro.c_str (),\r
+ GetLinkerMacro ().c_str () );\r
+\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ junk_tmp.c_str () );\r
+\r
+ string killAt = module.mangledSymbols ? "" : "--kill-at";\r
+ fprintf ( fMakefile,\r
+ "\t${dlltool} --dllname %s --base-file %s --def %s --output-exp %s %s\n",\r
+ targetName.c_str (),\r
+ base_tmp.c_str (),\r
+ def_file.c_str (),\r
+ temp_exp.c_str (),\r
+ killAt.c_str () );\r
+\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ base_tmp.c_str () );\r
+\r
+ fprintf ( fMakefile,\r
+ "\t%s %s %s -o %s %s %s %s\n",\r
+ linker.c_str (),\r
+ linkerParameters.c_str (),\r
+ temp_exp.c_str (),\r
+ target.c_str (),\r
+ objectsMacro.c_str (),\r
+ libsMacro.c_str (),\r
+ GetLinkerMacro ().c_str () );\r
+\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ temp_exp.c_str () );\r
+ }\r
+ else\r
+ {\r
+ fprintf ( fMakefile,\r
+ "\t%s %s -o %s %s %s %s\n",\r
+ linker.c_str (),\r
+ linkerParameters.c_str (),\r
+ target.c_str (),\r
+ objectsMacro.c_str (),\r
+ libsMacro.c_str (),\r
+ GetLinkerMacro ().c_str () );\r
+ }\r
+\r
+ GenerateBuildMapCode ();\r
+\r
+ fprintf ( fMakefile,\r
+ "\t$(ECHO_RSYM)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t$(Q)$(RSYM_TARGET) $@ $@\n\n" );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GeneratePhonyTarget() const\r
+{\r
+ string targetMacro ( GetTargetMacro(module) );\r
+ fprintf ( fMakefile, ".PHONY: %s\n\n",\r
+ targetMacro.c_str ());\r
+ fprintf ( fMakefile, "%s: | %s\n",\r
+ targetMacro.c_str (),\r
+ GetDirectory(GetTargetFilename(module,NULL)).c_str () );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateObjectFileTargets (\r
+ const IfableData& data,\r
+ const string& cc,\r
+ const string& cppc,\r
+ const string& cflagsMacro,\r
+ const string& nasmflagsMacro,\r
- windresflagsMacro );\r
++ const string& windresflagsMacro,\r
++ const string& widlflagsMacro )\r
+{\r
+ size_t i;\r
+ \r
+ const vector<File*>& files = data.files;\r
+ for ( i = 0; i < files.size (); i++ )\r
+ {\r
+ string sourceFilename = files[i]->name;\r
+ GenerateCommands ( sourceFilename,\r
+ cc,\r
+ cppc,\r
+ cflagsMacro,\r
+ nasmflagsMacro,\r
- windresflagsMacro );\r
++ windresflagsMacro,\r
++ widlflagsMacro );\r
+ fprintf ( fMakefile,\r
+ "\n" );\r
+ }\r
+\r
+ const vector<If*>& ifs = data.ifs;\r
+ for ( i = 0; i < ifs.size(); i++ )\r
+ {\r
+ GenerateObjectFileTargets ( ifs[i]->data,\r
+ cc,\r
+ cppc,\r
+ cflagsMacro,\r
+ nasmflagsMacro,\r
- const string& windresflagsMacro )\r
++ windresflagsMacro,\r
++ widlflagsMacro );\r
+ }\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateObjectFileTargets (\r
+ const string& cc,\r
+ const string& cppc,\r
+ const string& cflagsMacro,\r
+ const string& nasmflagsMacro,\r
- windresflagsMacro );\r
++ const string& windresflagsMacro,\r
++ const string& widlflagsMacro )\r
+{\r
+ if ( module.pch )\r
+ {\r
+ const string& pch_file = module.pch->header;\r
+ string gch_file = pch_file + ".gch";\r
+ CLEAN_FILE(gch_file);\r
+ if ( use_pch )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ "%s: %s\n",\r
+ gch_file.c_str(),\r
+ pch_file.c_str() );\r
+ fprintf ( fMakefile, "\t$(ECHO_PCH)\n" );\r
+ fprintf (\r
+ fMakefile,\r
+ "\t%s -o %s %s -g %s\n\n",\r
+ ( module.cplusplus ? cppc.c_str() : cc.c_str() ),\r
+ gch_file.c_str(),\r
+ cflagsMacro.c_str(),\r
+ pch_file.c_str() );\r
+ }\r
+ }\r
+\r
+ GenerateObjectFileTargets ( module.non_if_data,\r
+ cc,\r
+ cppc,\r
+ cflagsMacro,\r
+ nasmflagsMacro,\r
- if ( module.type == ObjectLibrary )\r
++ windresflagsMacro,\r
++ widlflagsMacro );\r
+ fprintf ( fMakefile, "\n" );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GenerateArchiveTarget ( const string& ar,\r
+ const string& objs_macro ) const\r
+{\r
+ string archiveFilename ( GetModuleArchiveFilename () );\r
+ \r
+ fprintf ( fMakefile,\r
+ "%s: %s | %s\n",\r
+ archiveFilename.c_str (),\r
+ objs_macro.c_str (),\r
+ GetDirectory(archiveFilename).c_str() );\r
+\r
+ fprintf ( fMakefile, "\t$(ECHO_AR)\n" );\r
+\r
+ fprintf ( fMakefile,\r
+ "\t%s -rc $@ %s\n\n",\r
+ ar.c_str (),\r
+ objs_macro.c_str ());\r
+\r
+ return archiveFilename;\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetCFlagsMacro () const\r
+{\r
+ return ssprintf ( "$(%s_CFLAGS)",\r
+ module.name.c_str () );\r
+}\r
+\r
+/*static*/ string\r
+MingwModuleHandler::GetObjectsMacro ( const Module& module )\r
+{\r
+ return ssprintf ( "$(%s_OBJS)",\r
+ module.name.c_str () );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetLinkingDependenciesMacro () const\r
+{\r
+ return ssprintf ( "$(%s_LINKDEPS)", module.name.c_str () );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetLibsMacro () const\r
+{\r
+ return ssprintf ( "$(%s_LIBS)", module.name.c_str () );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetLinkerMacro () const\r
+{\r
+ return ssprintf ( "$(%s_LFLAGS)",\r
+ module.name.c_str () );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetModuleTargets ( const Module& module )\r
+{\r
- if ( module.type != ObjectLibrary )\r
++ if ( ReferenceObjects ( module ) )\r
+ return GetObjectsMacro ( module );\r
+ else\r
+ return GetTargetFilename ( module, NULL );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateObjectMacro ()\r
+{\r
+ objectsMacro = ssprintf ("%s_OBJS", module.name.c_str ());\r
+\r
+ GenerateObjectMacros (\r
+ "=",\r
+ module.non_if_data,\r
+ &module.compilerFlags,\r
+ &module.linkerFlags );\r
+\r
+ // future references to the macro will be to get its values\r
+ objectsMacro = ssprintf ("$(%s)", objectsMacro.c_str ());\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateTargetMacro ()\r
+{\r
+ fprintf ( fMakefile,\r
+ "%s := %s\n",\r
+ GetTargetMacro ( module, false ).c_str (),\r
+ GetModuleTargets ( module ).c_str () );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateOtherMacros ()\r
+{\r
+ cflagsMacro = ssprintf ("%s_CFLAGS", module.name.c_str ());\r
+ nasmflagsMacro = ssprintf ("%s_NASMFLAGS", module.name.c_str ());\r
+ windresflagsMacro = ssprintf ("%s_RCFLAGS", module.name.c_str ());\r
++ widlflagsMacro = ssprintf ("%s_WIDLFLAGS", module.name.c_str ());\r
+ linkerflagsMacro = ssprintf ("%s_LFLAGS", module.name.c_str ());\r
+ libsMacro = ssprintf("%s_LIBS", module.name.c_str ());\r
+ linkDepsMacro = ssprintf ("%s_LINKDEPS", module.name.c_str ());\r
+\r
+ GenerateMacros (\r
+ "=",\r
+ module.non_if_data,\r
+ &module.compilerFlags,\r
+ &module.linkerFlags );\r
+\r
+ if ( module.importLibrary )\r
+ {\r
+ string_list s;\r
+ const vector<File*>& files = module.non_if_data.files;\r
+ for ( size_t i = 0; i < files.size (); i++ )\r
+ {\r
+ File& file = *files[i];\r
+ string extension = GetExtension ( file.name );\r
+ if ( extension == ".spec" || extension == ".SPEC" )\r
+ GetSpecObjectDependencies ( s, file.name );\r
+ }\r
+ if ( s.size () > 0 )\r
+ {\r
+ fprintf (\r
+ fMakefile,\r
+ "%s +=",\r
+ linkDepsMacro.c_str() );\r
+ for ( size_t i = 0; i < s.size(); i++ )\r
+ fprintf ( fMakefile,\r
+ " %s",\r
+ s[i].c_str () );\r
+ fprintf ( fMakefile, "\n" );\r
+ }\r
+ }\r
+\r
+ string globalCflags = "-g";\r
+ if ( backend->usePipe )\r
+ globalCflags += " -pipe";\r
+ \r
+ fprintf (\r
+ fMakefile,\r
+ "%s += $(PROJECT_CFLAGS) %s\n",\r
+ cflagsMacro.c_str (),\r
+ globalCflags.c_str () );\r
+\r
+ fprintf (\r
+ fMakefile,\r
+ "%s += $(PROJECT_RCFLAGS)\n",\r
+ windresflagsMacro.c_str () );\r
+\r
++ fprintf (\r
++ fMakefile,\r
++ "%s += $(PROJECT_WIDLFLAGS)\n",\r
++ widlflagsMacro.c_str () );\r
++\r
+ fprintf (\r
+ fMakefile,\r
+ "%s_LFLAGS += $(PROJECT_LFLAGS) -g\n",\r
+ module.name.c_str () );\r
+\r
+ fprintf (\r
+ fMakefile,\r
+ "%s += $(%s)\n",\r
+ linkDepsMacro.c_str (),\r
+ libsMacro.c_str () );\r
+\r
+ string cflags = TypeSpecificCFlags();\r
+ if ( cflags.size() > 0 )\r
+ {\r
+ fprintf ( fMakefile,\r
+ "%s += %s\n\n",\r
+ cflagsMacro.c_str (),\r
+ cflags.c_str () );\r
+ }\r
+\r
+ string nasmflags = TypeSpecificNasmFlags();\r
+ if ( nasmflags.size () > 0 )\r
+ {\r
+ fprintf ( fMakefile,\r
+ "%s += %s\n\n",\r
+ nasmflagsMacro.c_str (),\r
+ nasmflags.c_str () );\r
+ }\r
+\r
+ fprintf ( fMakefile, "\n\n" );\r
+\r
+ // future references to the macros will be to get their values\r
+ cflagsMacro = ssprintf ("$(%s)", cflagsMacro.c_str ());\r
+ nasmflagsMacro = ssprintf ("$(%s)", nasmflagsMacro.c_str ());\r
++ widlflagsMacro = ssprintf ("$(%s)", widlflagsMacro.c_str ());\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateRules ()\r
+{\r
+ string cc = ( module.host == HostTrue ? "${host_gcc}" : "${gcc}" );\r
+ string cppc = ( module.host == HostTrue ? "${host_gpp}" : "${gpp}" );\r
+ string ar = ( module.host == HostTrue ? "${host_ar}" : "${ar}" );\r
+\r
+ string targetMacro = GetTargetMacro ( module );\r
+\r
+ CLEAN_FILE ( targetMacro );\r
+\r
+ // generate phony target for module name\r
+ fprintf ( fMakefile, ".PHONY: %s\n",\r
+ module.name.c_str () );\r
+ fprintf ( fMakefile, "%s: %s\n\n",\r
+ module.name.c_str (),\r
+ GetTargetMacro ( module ).c_str () );\r
+\r
- windresflagsMacro );\r
++ if ( !ReferenceObjects ( module ) )\r
+ {\r
+ string ar_target ( GenerateArchiveTarget ( ar, objectsMacro ) );\r
+ if ( targetMacro != ar_target )\r
+ {\r
+ CLEAN_FILE ( ar_target );\r
+ }\r
+ }\r
+\r
+ GenerateObjectFileTargets ( cc,\r
+ cppc,\r
+ cflagsMacro,\r
+ nasmflagsMacro,\r
- string targetMacro ( GetTargetMacro (module) ); // i.e. "$(NTOSKRNL_TARGET)"\r
++ windresflagsMacro,\r
++ widlflagsMacro );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GetInvocationDependencies (\r
+ const Module& module,\r
+ string_list& dependencies )\r
+{\r
+ for ( size_t i = 0; i < module.invocations.size (); i++ )\r
+ {\r
+ Invoke& invoke = *module.invocations[i];\r
+ if ( invoke.invokeModule == &module )\r
+ /* Protect against circular dependencies */\r
+ continue;\r
+ invoke.GetTargets ( dependencies );\r
+ }\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateInvocations () const\r
+{\r
+ if ( module.invocations.size () == 0 )\r
+ return;\r
+ \r
+ size_t iend = module.invocations.size ();\r
+ for ( size_t i = 0; i < iend; i++ )\r
+ {\r
+ const Invoke& invoke = *module.invocations[i];\r
+\r
+ if ( invoke.invokeModule->type != BuildTool )\r
+ {\r
+ throw InvalidBuildFileException ( module.node.location,\r
+ "Only modules of type buildtool can be invoked." );\r
+ }\r
+\r
+ string invokeTarget = module.GetInvocationTarget ( i );\r
+ string_list invoke_targets;\r
+ assert ( invoke_targets.size() );\r
+ invoke.GetTargets ( invoke_targets );\r
+ fprintf ( fMakefile,\r
+ ".PHONY: %s\n\n",\r
+ invokeTarget.c_str () );\r
+ fprintf ( fMakefile,\r
+ "%s:",\r
+ invokeTarget.c_str () );\r
+ size_t j, jend = invoke_targets.size();\r
+ for ( j = 0; j < jend; j++ )\r
+ {\r
+ fprintf ( fMakefile,\r
+ " %s",\r
+ invoke_targets[i].c_str () );\r
+ }\r
+ fprintf ( fMakefile, "\n\n%s", invoke_targets[0].c_str () );\r
+ for ( j = 1; j < jend; j++ )\r
+ fprintf ( fMakefile,\r
+ " %s",\r
+ invoke_targets[i].c_str () );\r
+ fprintf ( fMakefile,\r
+ ": %s\n",\r
+ NormalizeFilename ( invoke.invokeModule->GetPath () ).c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_INVOKE)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t%s %s\n\n",\r
+ NormalizeFilename ( invoke.invokeModule->GetPath () ).c_str (),\r
+ invoke.GetParameters ().c_str () );\r
+ }\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetPreconditionDependenciesName () const\r
+{\r
+ return module.name + "_precondition";\r
+}\r
+\r
+void\r
+MingwModuleHandler::GetDefaultDependencies (\r
+ string_list& dependencies ) const\r
+{\r
+ /* Avoid circular dependency */\r
+ if ( module.type != BuildTool\r
+ && module.name != "zlib"\r
+ && module.name != "hostzlib" )\r
+\r
+ dependencies.push_back ( "$(INIT)" );\r
+}\r
+\r
+void\r
+MingwModuleHandler::GeneratePreconditionDependencies ()\r
+{\r
+ string preconditionDependenciesName = GetPreconditionDependenciesName ();\r
+ string_list sourceFilenames;\r
+ GetSourceFilenamesWithoutGeneratedFiles ( sourceFilenames );\r
+ string_list dependencies;\r
+ GetDefaultDependencies ( dependencies );\r
+ GetModuleDependencies ( dependencies );\r
+\r
+ GetInvocationDependencies ( module, dependencies );\r
+ \r
+ if ( dependencies.size() )\r
+ {\r
+ fprintf ( fMakefile,\r
+ "%s =",\r
+ preconditionDependenciesName.c_str () );\r
+ for ( size_t i = 0; i < dependencies.size(); i++ )\r
+ fprintf ( fMakefile,\r
+ " %s",\r
+ dependencies[i].c_str () );\r
+ fprintf ( fMakefile, "\n\n" );\r
+ }\r
+\r
+ for ( size_t i = 0; i < sourceFilenames.size(); i++ )\r
+ {\r
+ fprintf ( fMakefile,\r
+ "%s: ${%s}\n",\r
+ sourceFilenames[i].c_str(),\r
+ preconditionDependenciesName.c_str ());\r
+ }\r
+ fprintf ( fMakefile, "\n" );\r
+}\r
+\r
+bool\r
+MingwModuleHandler::IsWineModule () const\r
+{\r
+ if ( module.importLibrary == NULL)\r
+ return false;\r
+\r
+ size_t index = module.importLibrary->definition.rfind ( ".spec.def" );\r
+ return ( index != string::npos );\r
+}\r
+\r
+string\r
+MingwModuleHandler::GetDefinitionFilename () const\r
+{\r
+ string defFilename = module.GetBasePath () + SSEP + module.importLibrary->definition;\r
+ if ( IsWineModule () )\r
+ return PassThruCacheDirectory ( NormalizeFilename ( defFilename ),\r
+ backend->intermediateDirectory );\r
+ else\r
+ return defFilename;\r
+}\r
+\r
+void\r
+MingwModuleHandler::GenerateImportLibraryTargetIfNeeded ()\r
+{\r
+ if ( module.importLibrary != NULL )\r
+ {\r
+ string library_target (\r
+ GetImportLibraryFilename ( module, &clean_files ) );\r
+\r
+ string_list deps;\r
+ GetDefinitionDependencies ( deps );\r
+\r
+ fprintf ( fMakefile, "# IMPORT LIBRARY RULE:\n" );\r
+\r
+ fprintf ( fMakefile, "%s:",\r
+ library_target.c_str () );\r
+\r
+ size_t i, iend = deps.size();\r
+ for ( i = 0; i < iend; i++ )\r
+ fprintf ( fMakefile, " %s",\r
+ deps[i].c_str () );\r
+\r
+ fprintf ( fMakefile, " | %s\n",\r
+ GetDirectory ( GetTargetFilename ( module, NULL ) ).c_str () );\r
+\r
+ fprintf ( fMakefile, "\t$(ECHO_DLLTOOL)\n" );\r
+\r
+ string killAt = module.mangledSymbols ? "" : "--kill-at";\r
+ fprintf ( fMakefile,\r
+ "\t${dlltool} --dllname %s --def %s --output-lib %s %s\n\n",\r
+ module.GetTargetName ().c_str (),\r
+ GetDefinitionFilename ().c_str (),\r
+ library_target.c_str (),\r
+ killAt.c_str () );\r
+ }\r
+}\r
+\r
+void\r
+MingwModuleHandler::GetSpecObjectDependencies (\r
+ string_list& dependencies,\r
+ const string& filename ) const\r
+{\r
+ string basename = GetBasename ( filename );\r
+ string defDependency = PassThruCacheDirectory (\r
+ NormalizeFilename ( basename + ".spec.def" ),\r
+ backend->intermediateDirectory );\r
+ dependencies.push_back ( defDependency );\r
+ string stubsDependency = PassThruCacheDirectory (\r
+ NormalizeFilename ( basename + ".stubs.c" ),\r
+ backend->intermediateDirectory );\r
+ dependencies.push_back ( stubsDependency );\r
+}\r
+\r
++void\r
++MingwModuleHandler::GetWidlObjectDependencies (\r
++ string_list& dependencies,\r
++ const string& filename ) const\r
++{\r
++ string basename = GetBasename ( filename );\r
++ string serverDependency = PassThruCacheDirectory (\r
++ NormalizeFilename ( basename + "_s.c" ),\r
++ backend->intermediateDirectory );\r
++ dependencies.push_back ( serverDependency );\r
++}\r
++\r
+void\r
+MingwModuleHandler::GetDefinitionDependencies (\r
+ string_list& dependencies ) const\r
+{\r
+ string dkNkmLibNoFixup = "dk/nkm/lib";\r
+ const vector<File*>& files = module.non_if_data.files;\r
+ for ( size_t i = 0; i < files.size (); i++ )\r
+ {\r
+ File& file = *files[i];\r
+ string extension = GetExtension ( file.name );\r
+ if ( extension == ".spec" || extension == ".SPEC" )\r
+ {\r
+ GetSpecObjectDependencies ( dependencies, file.name );\r
+ }\r
++ if ( extension == ".idl" || extension == ".IDL" )\r
++ {\r
++ GetWidlObjectDependencies ( dependencies, file.name );\r
++ }\r
+ }\r
+}\r
+\r
+\r
+MingwBuildToolModuleHandler::MingwBuildToolModuleHandler ( const Module& module_ )\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwBuildToolModuleHandler::Process ()\r
+{\r
+ GenerateBuildToolModuleTarget ();\r
+}\r
+\r
+void\r
+MingwBuildToolModuleHandler::GenerateBuildToolModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateRules ();\r
+\r
+ string linker;\r
+ if ( module.cplusplus )\r
+ linker = "${host_gpp}";\r
+ else\r
+ linker = "${host_gcc}";\r
+ \r
+ fprintf ( fMakefile, "%s: %s %s | %s\n",\r
+ targetMacro.c_str (),\r
+ objectsMacro.c_str (),\r
+ linkDepsMacro.c_str (),\r
+ GetDirectory(GetTargetFilename(module,NULL)).c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_LD)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t%s %s -o $@ %s %s\n\n",\r
+ linker.c_str (),\r
+ GetLinkerMacro ().c_str (),\r
+ objectsMacro.c_str (),\r
+ libsMacro.c_str () );\r
+}\r
+\r
+\r
+MingwKernelModuleHandler::MingwKernelModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwKernelModuleHandler::Process ()\r
+{\r
+ GenerateKernelModuleTarget ();\r
+}\r
+\r
+void\r
+MingwKernelModuleHandler::GenerateKernelModuleTarget ()\r
+{\r
+ string targetName ( module.GetTargetName () ); // i.e. "ntoskrnl.exe"\r
- string targetMacro ( GetTargetMacro (module) );\r
++ string targetMacro ( GetTargetMacro ( module ) ); // i.e. "$(NTOSKRNL_TARGET)"\r
+ string workingDirectory = GetWorkingDirectory ();\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+ string base_tmp = ros_temp + module.name + ".base.tmp";\r
+ CLEAN_FILE ( base_tmp );\r
+ string junk_tmp = ros_temp + module.name + ".junk.tmp";\r
+ CLEAN_FILE ( junk_tmp );\r
+ string temp_exp = ros_temp + module.name + ".temp.exp";\r
+ CLEAN_FILE ( temp_exp );\r
+ string gccOptions = ssprintf ("-Wl,-T,%s" SSEP "ntoskrnl.lnk -Wl,--subsystem,native -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -nostartfiles -mdll",\r
+ module.GetBasePath ().c_str (),\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+\r
+ GenerateRules ();\r
+\r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ fprintf ( fMakefile, "%s: %s %s $(RSYM_TARGET) | %s\n",\r
+ targetMacro.c_str (),\r
+ objectsMacro.c_str (),\r
+ linkDepsMacro.c_str (),\r
+ GetDirectory(GetTargetFilename(module,NULL)).c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_LD)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t${gcc} %s %s -Wl,--base-file,%s -o %s %s %s\n",\r
+ GetLinkerMacro ().c_str (),\r
+ gccOptions.c_str (),\r
+ base_tmp.c_str (),\r
+ junk_tmp.c_str (),\r
+ objectsMacro.c_str (),\r
+ linkDepsMacro.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ junk_tmp.c_str () );\r
+ string killAt = module.mangledSymbols ? "" : "--kill-at";\r
+ fprintf ( fMakefile,\r
+ "\t${dlltool} --dllname %s --base-file %s --def ntoskrnl/ntoskrnl.def --output-exp %s %s\n",\r
+ targetName.c_str (),\r
+ base_tmp.c_str (),\r
+ temp_exp.c_str (),\r
+ killAt.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ base_tmp.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\t${gcc} %s %s -Wl,%s -o $@ %s %s\n",\r
+ GetLinkerMacro ().c_str (),\r
+ gccOptions.c_str (),\r
+ temp_exp.c_str (),\r
+ objectsMacro.c_str (),\r
+ linkDepsMacro.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ temp_exp.c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_RSYM)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t$(Q)$(RSYM_TARGET) $@ $@\n\n" );\r
+}\r
+\r
+\r
+MingwStaticLibraryModuleHandler::MingwStaticLibraryModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwStaticLibraryModuleHandler::Process ()\r
+{\r
+ GenerateStaticLibraryModuleTarget ();\r
+}\r
+\r
+void\r
+MingwStaticLibraryModuleHandler::GenerateStaticLibraryModuleTarget ()\r
+{\r
+ GenerateRules ();\r
+}\r
+\r
+\r
+MingwObjectLibraryModuleHandler::MingwObjectLibraryModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwObjectLibraryModuleHandler::Process ()\r
+{\r
+ GenerateObjectLibraryModuleTarget ();\r
+}\r
+\r
+void\r
+MingwObjectLibraryModuleHandler::GenerateObjectLibraryModuleTarget ()\r
+{\r
+ GenerateRules ();\r
+}\r
+\r
+\r
+MingwKernelModeDLLModuleHandler::MingwKernelModeDLLModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwKernelModeDLLModuleHandler::Process ()\r
+{\r
+ GenerateKernelModeDLLModuleTarget ();\r
+}\r
+\r
+void\r
+MingwKernelModeDLLModuleHandler::GenerateKernelModeDLLModuleTarget ()\r
+{\r
++ string targetMacro ( GetTargetMacro ( module ) );\r
+ string workingDirectory = GetWorkingDirectory ( );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies =\r
+ objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,native -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -nostartfiles -mdll",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ "${gcc}",\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
+\r
+\r
+MingwKernelModeDriverModuleHandler::MingwKernelModeDriverModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwKernelModeDriverModuleHandler::Process ()\r
+{\r
+ GenerateKernelModeDriverModuleTarget ();\r
+}\r
+\r
+\r
+void\r
+MingwKernelModeDriverModuleHandler::GenerateKernelModeDriverModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string workingDirectory = GetWorkingDirectory ();\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies = objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,native -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -nostartfiles -mdll",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ "${gcc}",\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
+\r
+\r
+MingwNativeDLLModuleHandler::MingwNativeDLLModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwNativeDLLModuleHandler::Process ()\r
+{\r
+ GenerateNativeDLLModuleTarget ();\r
+}\r
+\r
+void\r
+MingwNativeDLLModuleHandler::GenerateNativeDLLModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string workingDirectory = GetWorkingDirectory ( );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+ \r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies =\r
+ objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,native -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -nostartfiles -nostdlib -mdll",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ "${gcc}",\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
+\r
+\r
+MingwNativeCUIModuleHandler::MingwNativeCUIModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwNativeCUIModuleHandler::Process ()\r
+{\r
+ GenerateNativeCUIModuleTarget ();\r
+}\r
+\r
+void\r
+MingwNativeCUIModuleHandler::GenerateNativeCUIModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string workingDirectory = GetWorkingDirectory ( );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+ \r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies =\r
+ objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,native -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -nostartfiles -nostdlib",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ "${gcc}",\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
+\r
+\r
+MingwWin32DLLModuleHandler::MingwWin32DLLModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwWin32DLLModuleHandler::Process ()\r
+{\r
+ GenerateExtractWineDLLResourcesTarget ();\r
+ GenerateWin32DLLModuleTarget ();\r
+}\r
+\r
+void\r
+MingwWin32DLLModuleHandler::GenerateExtractWineDLLResourcesTarget ()\r
+{\r
+ fprintf ( fMakefile, ".PHONY: %s_extractresources\n\n",\r
+ module.name.c_str () );\r
+ fprintf ( fMakefile, "%s_extractresources: $(BIN2RES_TARGET)\n",\r
+ module.name.c_str () );\r
+ const vector<File*>& files = module.non_if_data.files;\r
+ for ( size_t i = 0; i < files.size (); i++ )\r
+ {\r
+ File& file = *files[i];\r
+ string extension = GetExtension ( file.name );\r
+ if ( extension == ".rc" || extension == ".RC" )\r
+ {\r
+ string resource = NormalizeFilename ( file.name );\r
+ fprintf ( fMakefile, "\t$(ECHO_BIN2RES)\n" );\r
+ fprintf ( fMakefile, "\t@:echo ${bin2res} -f -x %s\n",\r
+ resource.c_str () );\r
+ }\r
+ }\r
+ fprintf ( fMakefile, "\n");\r
+}\r
+\r
+void\r
+MingwWin32DLLModuleHandler::GenerateWin32DLLModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string workingDirectory = GetWorkingDirectory ( );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies = objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linker;\r
+ if ( module.cplusplus )\r
+ linker = "${gpp}";\r
+ else\r
+ linker = "${gcc}";\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,console -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -mdll",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ linker,\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
+\r
+\r
+MingwWin32CUIModuleHandler::MingwWin32CUIModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwWin32CUIModuleHandler::Process ()\r
+{\r
+ GenerateWin32CUIModuleTarget ();\r
+}\r
+\r
+void\r
+MingwWin32CUIModuleHandler::GenerateWin32CUIModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string workingDirectory = GetWorkingDirectory ( );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies =\r
+ objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linker;\r
+ if ( module.cplusplus )\r
+ linker = "${gpp}";\r
+ else\r
+ linker = "${gcc}";\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,console -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ linker,\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
+\r
+\r
+MingwWin32GUIModuleHandler::MingwWin32GUIModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwWin32GUIModuleHandler::Process ()\r
+{\r
+ GenerateWin32GUIModuleTarget ();\r
+}\r
+\r
+void\r
+MingwWin32GUIModuleHandler::GenerateWin32GUIModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string workingDirectory = GetWorkingDirectory ( );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies =\r
+ objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linker;\r
+ if ( module.cplusplus )\r
+ linker = "${gpp}";\r
+ else\r
+ linker = "${gcc}";\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,windows -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ linker,\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
+\r
+\r
+MingwBootLoaderModuleHandler::MingwBootLoaderModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwBootLoaderModuleHandler::Process ()\r
+{\r
+ GenerateBootLoaderModuleTarget ();\r
+}\r
+\r
+void\r
+MingwBootLoaderModuleHandler::GenerateBootLoaderModuleTarget ()\r
+{\r
+ string targetName ( module.GetTargetName () );\r
+ string targetMacro ( GetTargetMacro (module) );\r
+ string workingDirectory = GetWorkingDirectory ();\r
+ string junk_tmp = ros_temp + module.name + ".junk.tmp";\r
+ CLEAN_FILE ( junk_tmp );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateRules ();\r
+\r
+ fprintf ( fMakefile, "%s: %s %s | %s\n",\r
+ targetMacro.c_str (),\r
+ objectsMacro.c_str (),\r
+ linkDepsMacro.c_str (),\r
+ GetDirectory(GetTargetFilename(module,NULL)).c_str () );\r
+\r
+ fprintf ( fMakefile, "\t$(ECHO_LD)\n" );\r
+\r
+ fprintf ( fMakefile,\r
+ "\t${ld} %s -N -Ttext=0x8000 -o %s %s %s\n",\r
+ GetLinkerMacro ().c_str (),\r
+ junk_tmp.c_str (),\r
+ objectsMacro.c_str (),\r
+ linkDepsMacro.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\t${objcopy} -O binary %s $@\n",\r
+ junk_tmp.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ junk_tmp.c_str () );\r
+}\r
+\r
+\r
+MingwBootSectorModuleHandler::MingwBootSectorModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwBootSectorModuleHandler::Process ()\r
+{\r
+ GenerateBootSectorModuleTarget ();\r
+}\r
+\r
+void\r
+MingwBootSectorModuleHandler::GenerateBootSectorModuleTarget ()\r
+{\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+\r
+ GenerateRules ();\r
+\r
+ fprintf ( fMakefile, ".PHONY: %s\n\n",\r
+ module.name.c_str ());\r
+ fprintf ( fMakefile,\r
+ "%s: %s\n",\r
+ module.name.c_str (),\r
+ objectsMacro.c_str () );\r
+}\r
+\r
+\r
+MingwIsoModuleHandler::MingwIsoModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwIsoModuleHandler::Process ()\r
+{\r
+ GenerateIsoModuleTarget ();\r
+}\r
+\r
+void\r
+MingwIsoModuleHandler::OutputBootstrapfileCopyCommands (\r
+ const string& bootcdDirectory )\r
+{\r
+ for ( size_t i = 0; i < module.project.modules.size (); i++ )\r
+ {\r
+ const Module& m = *module.project.modules[i];\r
+ if ( m.bootstrap != NULL )\r
+ {\r
+ string sourceFilename = PassThruCacheDirectory (\r
+ NormalizeFilename ( m.GetPath () ),\r
+ backend->outputDirectory );\r
+ string targetFilenameNoFixup ( bootcdDirectory + SSEP + m.bootstrap->base + SSEP + m.bootstrap->nameoncd );\r
+ string targetFilename = MingwModuleHandler::PassThruCacheDirectory (\r
+ NormalizeFilename ( targetFilenameNoFixup ),\r
+ backend->outputDirectory );\r
+ fprintf ( fMakefile,\r
+ "\t$(ECHO_CP)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t${cp} %s %s 1>$(NUL)\n",\r
+ sourceFilename.c_str (),\r
+ targetFilename.c_str () );\r
+ }\r
+ }\r
+}\r
+\r
+void\r
+MingwIsoModuleHandler::OutputCdfileCopyCommands (\r
+ const string& bootcdDirectory )\r
+{\r
+ for ( size_t i = 0; i < module.project.cdfiles.size (); i++ )\r
+ {\r
+ const CDFile& cdfile = *module.project.cdfiles[i];\r
+ string targetFilenameNoFixup = bootcdDirectory + SSEP + cdfile.base + SSEP + cdfile.nameoncd;\r
+ string targetFilename = MingwModuleHandler::PassThruCacheDirectory (\r
+ NormalizeFilename ( targetFilenameNoFixup ),\r
+ backend->outputDirectory );\r
+ fprintf ( fMakefile,\r
+ "\t$(ECHO_CP)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t${cp} %s %s 1>$(NUL)\n",\r
+ cdfile.GetPath ().c_str (),\r
+ targetFilename.c_str () );\r
+ }\r
+}\r
+\r
+string\r
+MingwIsoModuleHandler::GetBootstrapCdDirectories ( const string& bootcdDirectory )\r
+{\r
+ string directories;\r
+ for ( size_t i = 0; i < module.project.modules.size (); i++ )\r
+ {\r
+ const Module& m = *module.project.modules[i];\r
+ if ( m.bootstrap != NULL )\r
+ {\r
+ string targetDirectory ( bootcdDirectory + SSEP + m.bootstrap->base );\r
+ if ( directories.size () > 0 )\r
+ directories += " ";\r
+ directories += PassThruCacheDirectory (\r
+ NormalizeFilename ( targetDirectory ),\r
+ backend->outputDirectory );\r
+ }\r
+ }\r
+ return directories;\r
+}\r
+\r
+string\r
+MingwIsoModuleHandler::GetNonModuleCdDirectories ( const string& bootcdDirectory )\r
+{\r
+ string directories;\r
+ for ( size_t i = 0; i < module.project.cdfiles.size (); i++ )\r
+ {\r
+ const CDFile& cdfile = *module.project.cdfiles[i];\r
+ string targetDirectory ( bootcdDirectory + SSEP + cdfile.base );\r
+ if ( directories.size () > 0 )\r
+ directories += " ";\r
+ directories += PassThruCacheDirectory (\r
+ NormalizeFilename ( targetDirectory ),\r
+ backend->outputDirectory );\r
+ }\r
+ return directories;\r
+}\r
+\r
+string\r
+MingwIsoModuleHandler::GetCdDirectories ( const string& bootcdDirectory )\r
+{\r
+ string directories = GetBootstrapCdDirectories ( bootcdDirectory );\r
+ directories += " " + GetNonModuleCdDirectories ( bootcdDirectory );\r
+ return directories;\r
+}\r
+\r
+void\r
+MingwIsoModuleHandler::GetBootstrapCdFiles (\r
+ vector<string>& out ) const\r
+{\r
+ for ( size_t i = 0; i < module.project.modules.size (); i++ )\r
+ {\r
+ const Module& m = *module.project.modules[i];\r
+ if ( m.bootstrap != NULL )\r
+ {\r
+ string filename = PassThruCacheDirectory (\r
+ NormalizeFilename ( m.GetPath () ),\r
+ backend->outputDirectory );\r
+ out.push_back ( filename );\r
+ }\r
+ }\r
+}\r
+\r
+void\r
+MingwIsoModuleHandler::GetNonModuleCdFiles (\r
+ vector<string>& out ) const\r
+{\r
+ for ( size_t i = 0; i < module.project.cdfiles.size (); i++ )\r
+ {\r
+ const CDFile& cdfile = *module.project.cdfiles[i];\r
+ out.push_back ( cdfile.GetPath () );\r
+ }\r
+}\r
+\r
+void\r
+MingwIsoModuleHandler::GetCdFiles (\r
+ vector<string>& out ) const\r
+{\r
+ GetBootstrapCdFiles ( out );\r
+ GetNonModuleCdFiles ( out );\r
+}\r
+\r
+void\r
+MingwIsoModuleHandler::GenerateIsoModuleTarget ()\r
+{\r
+ string bootcdDirectory = "cd";\r
+ string bootcd = PassThruCacheDirectory (\r
+ NormalizeFilename ( bootcdDirectory + SSEP ),\r
+ backend->outputDirectory );\r
+ string isoboot = PassThruCacheDirectory (\r
+ NormalizeFilename ( "boot" SSEP "freeldr" SSEP "bootsect" SSEP "isoboot.o" ),\r
+ backend->outputDirectory );\r
+ string bootcdReactosNoFixup = bootcdDirectory + SSEP "reactos";\r
+ string bootcdReactos = PassThruCacheDirectory (\r
+ NormalizeFilename ( bootcdReactosNoFixup ),\r
+ backend->outputDirectory );\r
+ CLEAN_FILE ( bootcdReactos );\r
+ string reactosInf = PassThruCacheDirectory (\r
+ NormalizeFilename ( bootcdReactosNoFixup + SSEP "reactos.inf" ),\r
+ backend->outputDirectory );\r
+ string reactosDff = NormalizeFilename ( "bootdata" SSEP "packages" SSEP "reactos.dff" );\r
+ string cdDirectories = GetCdDirectories ( bootcdDirectory );\r
+ vector<string> vCdFiles;\r
+ GetCdFiles ( vCdFiles );\r
+ string cdFiles = v2s ( vCdFiles, 5 );\r
+\r
+ fprintf ( fMakefile, ".PHONY: %s\n\n",\r
+ module.name.c_str ());\r
+ fprintf ( fMakefile,\r
+ "%s: all %s %s %s %s $(CABMAN_TARGET) $(CDMAKE_TARGET)\n",\r
+ module.name.c_str (),\r
+ isoboot.c_str (),\r
+ bootcdReactos.c_str (),\r
+ cdDirectories.c_str (),\r
+ cdFiles.c_str () );\r
+ fprintf ( fMakefile, "\t$(ECHO_CABMAN)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t$(Q)$(CABMAN_TARGET) -C %s -L %s -I -P $(OUTPUT)\n",\r
+ reactosDff.c_str (),\r
+ bootcdReactos.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\t$(Q)$(CABMAN_TARGET) -C %s -RC %s -L %s -N -P $(OUTPUT)\n",\r
+ reactosDff.c_str (),\r
+ reactosInf.c_str (),\r
+ bootcdReactos.c_str ());\r
+ fprintf ( fMakefile,\r
+ "\t-@${rm} %s 2>$(NUL)\n",\r
+ reactosInf.c_str () );\r
+ OutputBootstrapfileCopyCommands ( bootcdDirectory );\r
+ OutputCdfileCopyCommands ( bootcdDirectory );\r
+ fprintf ( fMakefile, "\t$(ECHO_CDMAKE)\n" );\r
+ fprintf ( fMakefile,\r
+ "\t$(Q)$(CDMAKE_TARGET) -v -m -b %s %s REACTOS ReactOS.iso\n",\r
+ isoboot.c_str (),\r
+ bootcd.c_str () );\r
+ fprintf ( fMakefile,\r
+ "\n" );\r
+}\r
+\r
+\r
+MingwTestModuleHandler::MingwTestModuleHandler (\r
+ const Module& module_ )\r
+\r
+ : MingwModuleHandler ( module_ )\r
+{\r
+}\r
+\r
+void\r
+MingwTestModuleHandler::Process ()\r
+{\r
+ GenerateTestModuleTarget ();\r
+}\r
+\r
+void\r
+MingwTestModuleHandler::GenerateTestModuleTarget ()\r
+{\r
+ string targetMacro ( GetTargetMacro ( module ) );\r
+ string workingDirectory = GetWorkingDirectory ( );\r
+ string objectsMacro = GetObjectsMacro ( module );\r
+ string linkDepsMacro = GetLinkingDependenciesMacro ();\r
+ string libsMacro = GetLibsMacro ();\r
+\r
+ GenerateImportLibraryTargetIfNeeded ();\r
+\r
+ if ( module.non_if_data.files.size () > 0 )\r
+ {\r
+ GenerateRules ();\r
+\r
+ string dependencies = objectsMacro + " " + linkDepsMacro;\r
+\r
+ string linker;\r
+ if ( module.cplusplus )\r
+ linker = "${gpp}";\r
+ else\r
+ linker = "${gcc}";\r
+\r
+ string linkerParameters = ssprintf ( "-Wl,--subsystem,console -Wl,--entry,%s -Wl,--image-base,%s -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000",\r
+ module.entrypoint.c_str (),\r
+ module.baseaddress.c_str () );\r
+ GenerateLinkerCommand ( dependencies,\r
+ linker,\r
+ linkerParameters,\r
+ objectsMacro,\r
+ libsMacro );\r
+ }\r
+ else\r
+ {\r
+ GeneratePhonyTarget();\r
+ }\r
+}\r
++\r
++\r
++MingwRpcServerModuleHandler::MingwRpcServerModuleHandler (\r
++ const Module& module_ )\r
++\r
++ : MingwModuleHandler ( module_ )\r
++{\r
++}\r
++\r
++void\r
++MingwRpcServerModuleHandler::Process ()\r
++{\r
++ GenerateRules ();\r
++}\r
++\r
++MingwRpcClientModuleHandler::MingwRpcClientModuleHandler (\r
++ const Module& module_ )\r
++\r
++ : MingwModuleHandler ( module_ )\r
++{\r
++}\r
++\r
++void\r
++MingwRpcClientModuleHandler::Process ()\r
++{\r
++ GenerateRules ();\r
++}\r
/* YYFINAL -- State number of the termination state. */
#define YYFINAL 3
/* YYLAST -- Last index in YYTABLE. */
- #define YYLAST 692
-#define YYLAST 661
++#define YYLAST 696
/* YYNTOKENS -- Number of terminals. */
#define YYNTOKENS 96
/* YYNNTS -- Number of nonterminals. */
- #define YYNNTS 83
+ #define YYNNTS 82
/* YYNRULES -- Number of rules. */
- #define YYNRULES 258
+ #define YYNRULES 256
/* YYNRULES -- Number of states. */
- #define YYNSTATES 572
-#define YYNSTATES 568
++#define YYNSTATES 570
/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
#define YYUNDEFTOK 2
124, -1, 123, 30, 124, -1, 123, 24, 124, -1,
123, 31, 124, -1, 123, 25, 124, -1, 123, 26,
124, -1, 123, 40, 124, -1, 123, 39, 124, -1,
- 123, 38, 124, -1, 123, 23, 103, 155, 176, 93,
- 176, 93, 176, 126, -1, 6, 155, 176, 93, 176,
- 93, 176, 93, 176, 93, 176, 129, -1, 176, 93,
- 176, 93, 176, 93, 176, 93, 176, 129, -1, -1,
- 93, 176, 93, 176, -1, 93, 176, 93, 176, 93,
- 131, -1, 93, 176, 93, 176, 93, 131, 93, 131,
- -1, 103, 155, 176, 93, 132, 93, 131, 93, 176,
- 93, 176, 93, 176, 93, 176, 93, 131, -1, 103,
- 155, 176, 93, 132, 93, 131, 93, 176, 93, 176,
- 93, 176, 93, 176, -1, 21, 176, 93, 6, -1,
- -1, 93, 131, -1, -1, 93, 131, -1, 93, 131,
- 93, 131, -1, 131, 83, 131, -1, 94, 131, 95,
- -1, 177, -1, 91, 177, -1, 176, -1, 6, -1,
- 14, 165, 176, 93, 176, 93, 176, 93, 176, 140,
- 134, 80, 135, 81, -1, -1, 134, 62, 131, -1,
- 134, 61, 131, -1, 134, 59, 6, -1, 134, 128,
- -1, 134, 141, -1, 134, 58, 103, -1, 134, 15,
- 102, -1, 134, 169, -1, 134, 170, -1, 134, 171,
- -1, -1, 135, 36, 136, -1, 135, 37, 138, -1,
- 135, 34, 138, -1, 135, 33, 138, -1, 135, 35,
- 138, -1, 135, 27, 137, -1, 135, 28, 137, -1,
- 135, 32, 137, -1, 135, 29, 137, -1, 135, 30,
- 137, -1, 135, 24, 137, -1, 135, 31, 137, -1,
- 135, 25, 137, -1, 135, 26, 137, -1, 135, 40,
- 137, -1, 135, 39, 137, -1, 135, 38, 137, -1,
- 135, 23, 103, 155, 176, 93, 176, 93, 176, 126,
- -1, 103, 155, 176, 93, 132, 93, 131, 93, 176,
- 93, 176, 93, 176, 93, 176, 93, 131, 140, 139,
- -1, 103, 155, 176, 93, 132, 93, 131, 93, 176,
- 93, 176, 93, 176, 93, 176, 139, -1, 6, 155,
- 176, 93, 176, 93, 176, 93, 176, 93, 176, 130,
- 140, 139, -1, 176, 93, 176, 93, 176, 93, 176,
- 93, 176, 130, 140, 139, -1, -1, 172, -1, -1,
- 93, 176, -1, 21, 176, 93, 6, 93, 176, 93,
- 176, 142, -1, -1, 93, 176, -1, 15, 165, 168,
- 144, -1, 80, 145, 81, -1, -1, 145, 74, 6,
- 155, 176, 146, -1, 145, 74, 76, -1, 145, 75,
- 6, 146, 144, -1, -1, 93, 48, 146, -1, 93,
- 47, 146, -1, 93, 77, 146, -1, 93, 49, 146,
- -1, 93, 72, 146, -1, 93, 73, 146, -1, 16,
- 165, 168, 148, -1, 80, 149, 81, -1, -1, 149,
- 74, 6, 150, -1, 149, 74, 76, -1, 149, 75,
- 6, 151, 148, -1, -1, 93, 176, -1, 93, 175,
- 93, 175, 146, -1, 93, 175, 93, 175, 93, 176,
- -1, -1, 93, 176, -1, 93, 175, 93, 176, -1,
- 93, 175, 93, 175, 93, 176, -1, 93, 175, 93,
- 175, 93, 175, 93, 176, -1, 153, 80, 154, 81,
- -1, 20, 165, 168, -1, -1, 154, 176, 155, 6,
- -1, -1, 93, -1, 19, 165, 157, 80, 158, 81,
- -1, -1, 157, 65, 176, 93, 176, 93, 176, 93,
- 176, -1, 157, 66, 176, 93, 176, 93, 176, 93,
- 176, -1, 157, 70, 176, -1, 157, 67, 176, -1,
- 157, 68, 176, -1, 157, 69, 176, -1, 157, 71,
- 176, -1, -1, 158, 159, -1, 41, 6, 80, 160,
- 81, -1, -1, 160, 161, -1, 159, -1, 42, 6,
- 93, 6, -1, 42, 6, 93, 162, -1, 176, -1,
- 162, 93, 176, -1, 78, 165, 176, 93, 176, 168,
- 80, 164, 81, -1, -1, 164, 79, 176, -1, 164,
- 76, -1, -1, 165, 166, -1, 165, 167, -1, 55,
- -1, 57, -1, 53, -1, 51, -1, 54, -1, 56,
- -1, 52, -1, -1, 168, 169, -1, 168, 170, -1,
- 168, 171, -1, 64, 176, 93, 176, -1, 60, 176,
- -1, 63, 176, -1, 168, 80, 173, 81, -1, 9,
- -1, 4, -1, 87, 4, -1, 5, -1, 87, 5,
- -1, 6, -1, 173, 155, 9, -1, 173, 155, 4,
- -1, 173, 155, 87, 4, -1, 173, 155, 5, -1,
- 173, 155, 87, 5, -1, 173, 155, 6, -1, 105,
- -1, 172, -1, -1, 176, -1, 177, -1, 177, 86,
- 177, -1, 177, 87, 177, -1, 177, 83, 177, -1,
- 177, 85, 177, -1, 177, 88, 177, -1, 177, 89,
- 177, -1, 177, 84, 177, -1, 90, 177, -1, 87,
- 177, -1, 86, 177, -1, 94, 177, 95, -1, 178,
- -1, 91, 178, -1, 4, -1, 5, -1
+ 123, 38, 124, -1, 123, 23, 103, 154, 175, 93,
+ 175, 93, 175, 126, -1, 6, 154, 175, 93, 175,
+ 93, 175, 93, 175, 93, 175, 129, -1, 175, 93,
+ 175, 93, 175, 93, 175, 93, 175, 129, -1, -1,
+ 93, 175, 93, 175, -1, 93, 175, 93, 175, 93,
+ 130, -1, 93, 175, 93, 175, 93, 130, 93, 130,
+ -1, 103, 154, 175, 93, 131, 93, 130, 93, 175,
+ 93, 175, 93, 175, 93, 175, 93, 130, -1, 103,
+ 154, 175, 93, 131, 93, 130, 93, 175, 93, 175,
+ 93, 175, 93, 175, -1, 21, 175, 93, 6, -1,
+ -1, 93, 130, -1, 93, 130, 93, 130, -1, 130,
- 83, 130, -1, 94, 130, 95, -1, 177, -1, 91,
- 177, -1, 175, -1, 6, -1, 14, 164, 175, 93,
++ 83, 130, -1, 94, 130, 95, -1, 176, -1, 91,
++ 176, -1, 175, -1, 6, -1, 14, 164, 175, 93,
+ 175, 93, 175, 93, 175, 139, 133, 80, 134, 81,
+ -1, -1, 133, 62, 130, -1, 133, 61, 130, -1,
+ 133, 59, 6, -1, 133, 128, -1, 133, 140, -1,
+ 133, 58, 103, -1, 133, 15, 102, -1, 133, 168,
+ -1, 133, 169, -1, 133, 170, -1, -1, 134, 36,
+ 135, -1, 134, 37, 137, -1, 134, 34, 137, -1,
+ 134, 33, 137, -1, 134, 35, 137, -1, 134, 27,
+ 136, -1, 134, 28, 136, -1, 134, 32, 136, -1,
+ 134, 29, 136, -1, 134, 30, 136, -1, 134, 24,
+ 136, -1, 134, 31, 136, -1, 134, 25, 136, -1,
+ 134, 26, 136, -1, 134, 40, 136, -1, 134, 39,
+ 136, -1, 134, 38, 136, -1, 134, 23, 103, 154,
+ 175, 93, 175, 93, 175, 126, -1, 103, 154, 175,
+ 93, 131, 93, 130, 93, 175, 93, 175, 93, 175,
+ 93, 175, 93, 130, 139, 138, -1, 103, 154, 175,
+ 93, 131, 93, 130, 93, 175, 93, 175, 93, 175,
+ 93, 175, 138, -1, 6, 154, 175, 93, 175, 93,
+ 175, 93, 175, 93, 175, 129, 139, 138, -1, 175,
+ 93, 175, 93, 175, 93, 175, 93, 175, 129, 139,
+ 138, -1, -1, 171, -1, -1, 93, 175, -1, 21,
+ 175, 93, 6, 93, 175, 93, 175, 141, -1, -1,
+ 93, 175, -1, 15, 164, 167, 143, -1, 80, 144,
+ 81, -1, -1, 144, 74, 6, 154, 175, 145, -1,
+ 144, 74, 76, -1, 144, 75, 6, 145, 143, -1,
+ -1, 93, 48, 145, -1, 93, 47, 145, -1, 93,
+ 77, 145, -1, 93, 49, 145, -1, 93, 72, 145,
+ -1, 93, 73, 145, -1, 16, 164, 167, 147, -1,
+ 80, 148, 81, -1, -1, 148, 74, 6, 149, -1,
+ 148, 74, 76, -1, 148, 75, 6, 150, 147, -1,
+ -1, 93, 175, -1, 93, 174, 93, 174, 145, -1,
+ 93, 174, 93, 174, 93, 175, -1, -1, 93, 175,
+ -1, 93, 174, 93, 175, -1, 93, 174, 93, 174,
+ 93, 175, -1, 93, 174, 93, 174, 93, 174, 93,
+ 175, -1, 152, 80, 153, 81, -1, 20, 164, 167,
+ -1, -1, 153, 175, 154, 6, -1, -1, 93, -1,
+ 19, 164, 156, 80, 157, 81, -1, -1, 156, 65,
+ 175, 93, 175, 93, 175, 93, 175, -1, 156, 66,
+ 175, 93, 175, 93, 175, 93, 175, -1, 156, 70,
+ 175, -1, 156, 67, 175, -1, 156, 68, 175, -1,
+ 156, 69, 175, -1, 156, 71, 175, -1, -1, 157,
+ 158, -1, 41, 6, 80, 159, 81, -1, -1, 159,
+ 160, -1, 158, -1, 42, 6, 93, 6, -1, 42,
+ 6, 93, 161, -1, 175, -1, 161, 93, 175, -1,
+ 78, 164, 175, 93, 175, 167, 80, 163, 81, -1,
+ -1, 163, 79, 175, -1, 163, 76, -1, -1, 164,
+ 165, -1, 164, 166, -1, 55, -1, 57, -1, 53,
+ -1, 51, -1, 54, -1, 56, -1, 52, -1, -1,
+ 167, 168, -1, 167, 169, -1, 167, 170, -1, 64,
+ 175, 93, 175, -1, 60, 175, -1, 63, 175, -1,
+ 167, 80, 172, 81, -1, 9, -1, 4, -1, 87,
+ 4, -1, 5, -1, 87, 5, -1, 6, -1, 172,
+ 154, 9, -1, 172, 154, 4, -1, 172, 154, 87,
+ 4, -1, 172, 154, 5, -1, 172, 154, 87, 5,
+ -1, 172, 154, 6, -1, 105, -1, 171, -1, -1,
+ 175, -1, 176, -1, 176, 86, 176, -1, 176, 87,
+ 176, -1, 176, 83, 176, -1, 176, 85, 176, -1,
+ 176, 88, 176, -1, 176, 89, 176, -1, 176, 84,
+ 176, -1, 90, 176, -1, 87, 176, -1, 86, 176,
+ -1, 94, 176, 95, -1, 177, -1, 91, 177, -1,
+ 4, -1, 5, -1
};
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
means the default is an error. */
static const unsigned short yydefact[] =
{
- 3, 0, 2, 1, 5, 257, 258, 11, 209, 9,
- 0, 0, 0, 0, 0, 4, 8, 0, 11, 243,
- 255, 0, 219, 0, 253, 252, 251, 256, 0, 182,
+ 3, 0, 2, 1, 5, 255, 256, 11, 207, 9,
+ 0, 0, 0, 0, 0, 4, 8, 0, 11, 241,
+ 253, 0, 217, 0, 251, 250, 249, 254, 0, 180,
0, 0, 0, 0, 0, 0, 0, 0, 44, 45,
- 209, 209, 209, 209, 209, 209, 209, 209, 209, 209,
- 209, 209, 209, 209, 209, 7, 17, 18, 24, 22,
- 23, 27, 28, 21, 30, 209, 16, 19, 20, 25,
- 26, 31, 29, 215, 218, 214, 216, 212, 217, 213,
- 210, 211, 181, 0, 254, 0, 6, 246, 250, 247,
- 244, 245, 248, 249, 219, 219, 219, 0, 0, 219,
- 219, 219, 219, 187, 219, 219, 219, 0, 219, 219,
- 0, 0, 0, 220, 221, 222, 0, 180, 184, 0,
- 34, 33, 32, 239, 0, 240, 35, 36, 0, 0,
+ 207, 207, 207, 207, 207, 207, 207, 207, 207, 207,
+ 207, 207, 207, 207, 207, 7, 17, 18, 24, 22,
+ 23, 27, 28, 21, 30, 207, 16, 19, 20, 25,
+ 26, 31, 29, 213, 216, 212, 214, 210, 215, 211,
+ 208, 209, 179, 0, 252, 0, 6, 244, 248, 245,
+ 242, 243, 246, 247, 217, 217, 217, 0, 0, 217,
+ 217, 217, 217, 185, 217, 217, 217, 0, 217, 217,
+ 0, 0, 0, 218, 219, 220, 0, 178, 182, 0,
+ 34, 33, 32, 237, 0, 238, 35, 36, 0, 0,
0, 0, 40, 41, 0, 38, 39, 37, 0, 42,
- 43, 224, 225, 0, 10, 185, 0, 47, 0, 0,
- 0, 154, 152, 167, 165, 0, 0, 0, 0, 0,
- 0, 0, 195, 0, 0, 183, 0, 228, 230, 232,
- 227, 0, 184, 0, 0, 0, 0, 0, 0, 191,
- 192, 193, 190, 194, 0, 219, 223, 0, 46, 0,
- 229, 231, 226, 0, 0, 0, 0, 0, 153, 0,
- 0, 166, 0, 0, 0, 186, 196, 0, 0, 0,
- 234, 236, 238, 233, 0, 0, 0, 184, 156, 158,
- 171, 169, 175, 0, 0, 0, 206, 50, 50, 235,
- 237, 0, 0, 0, 0, 0, 241, 168, 241, 0,
- 0, 0, 198, 0, 0, 48, 49, 61, 147, 158,
- 158, 158, 158, 158, 158, 158, 157, 0, 172, 0,
- 176, 170, 0, 0, 0, 208, 0, 205, 56, 55,
- 57, 58, 59, 54, 51, 52, 0, 0, 111, 155,
- 160, 159, 162, 163, 164, 161, 241, 241, 0, 0,
- 0, 197, 200, 199, 207, 0, 0, 0, 0, 0,
- 0, 0, 71, 65, 68, 69, 70, 148, 0, 158,
- 242, 0, 177, 188, 189, 0, 53, 13, 67, 12,
- 0, 15, 14, 66, 64, 0, 0, 63, 106, 62,
- 0, 0, 0, 0, 0, 0, 0, 122, 115, 116,
- 119, 120, 121, 0, 173, 241, 0, 0, 107, 255,
+ 43, 222, 223, 0, 10, 183, 0, 47, 0, 0,
+ 0, 152, 150, 165, 163, 0, 0, 0, 0, 0,
+ 0, 0, 193, 0, 0, 181, 0, 226, 228, 230,
+ 225, 0, 182, 0, 0, 0, 0, 0, 0, 189,
+ 190, 191, 188, 192, 0, 217, 221, 0, 46, 0,
+ 227, 229, 224, 0, 0, 0, 0, 0, 151, 0,
+ 0, 164, 0, 0, 0, 184, 194, 0, 0, 0,
+ 232, 234, 236, 231, 0, 0, 0, 182, 154, 156,
+ 169, 167, 173, 0, 0, 0, 204, 50, 50, 233,
+ 235, 0, 0, 0, 0, 0, 239, 166, 239, 0,
+ 0, 0, 196, 0, 0, 48, 49, 61, 145, 156,
+ 156, 156, 156, 156, 156, 156, 155, 0, 170, 0,
+ 174, 168, 0, 0, 0, 206, 0, 203, 56, 55,
+ 57, 58, 59, 54, 51, 52, 0, 0, 109, 153,
+ 158, 157, 160, 161, 162, 159, 239, 239, 0, 0,
+ 0, 195, 198, 197, 205, 0, 0, 0, 0, 0,
+ 0, 0, 71, 65, 68, 69, 70, 146, 0, 156,
+ 240, 0, 175, 186, 187, 0, 53, 13, 67, 12,
+ 0, 15, 14, 66, 64, 0, 0, 63, 104, 62,
+ 0, 0, 0, 0, 0, 0, 0, 120, 113, 114,
- 117, 118, 119, 0, 171, 239, 0, 0, 105, 0,
++ 117, 118, 119, 0, 171, 239, 0, 0, 105, 253,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 60,
- 116, 0, 115, 112, 111, 110, 0, 172, 0, 176,
- 199, 200, 201, 98, 103, 102, 182, 182, 82, 84,
- 85, 77, 78, 80, 81, 83, 79, 75, 0, 74,
- 76, 182, 72, 73, 88, 87, 86, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 60, 118, 0, 117, 114, 113, 112, 0, 174,
- 0, 178, 201, 202, 203, 98, 105, 104, 184, 184,
- 0, 0, 0, 0, 0, 0, 108, 0, 0, 0,
- 0, 0, 0, 98, 182, 182, 131, 133, 134, 126,
- 127, 129, 130, 132, 128, 124, 0, 123, 125, 182,
- 121, 122, 137, 136, 135, 177, 202, 0, 0, 0,
++ 0, 60, 116, 0, 115, 112, 111, 110, 0, 172,
++ 0, 176, 199, 200, 201, 98, 103, 102, 182, 182,
+ 82, 84, 85, 77, 78, 80, 81, 83, 79, 75,
- 0, 74, 76, 184, 72, 73, 88, 87, 86, 0,
++ 0, 74, 76, 182, 72, 73, 88, 87, 86, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 110, 0,
- 0, 0, 0, 0, 0, 98, 184, 184, 133, 135,
- 136, 128, 129, 131, 132, 134, 130, 126, 0, 125,
- 127, 184, 123, 124, 139, 138, 137, 179, 204, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 107, 0,
- 106, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 148, 0, 0, 0, 0, 92, 0, 0, 0, 0,
- 147, 0, 0, 0, 0, 0, 89, 0, 0, 0,
- 149, 92, 0, 0, 0, 0, 0, 99, 0, 138,
- 0, 0, 0, 0, 0, 0, 91, 0, 0, 99,
- 0, 93, 99, 100, 0, 0, 145, 0, 0, 90,
- 0, 0, 99, 143, 0, 94, 101, 0, 145, 142,
- 144, 0, 0, 0, 143, 0, 95, 97, 141, 0,
- 0, 143, 96, 0, 140, 145, 143, 139
++ 0, 0, 0, 0, 0, 0, 0, 0, 108, 0,
++ 0, 0, 0, 0, 0, 98, 182, 182, 131, 133,
++ 134, 126, 127, 129, 130, 132, 128, 124, 0, 123,
++ 125, 182, 121, 122, 137, 136, 135, 177, 202, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 109, 0, 108, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 150, 0, 0, 0, 0, 92, 0, 0,
- 0, 0, 149, 0, 0, 0, 0, 0, 89, 0,
- 0, 0, 151, 92, 0, 0, 0, 0, 0, 99,
- 0, 140, 0, 0, 0, 0, 0, 0, 91, 0,
- 0, 101, 0, 93, 99, 100, 0, 0, 0, 147,
- 0, 0, 90, 0, 101, 102, 145, 0, 94, 0,
- 147, 0, 144, 146, 0, 0, 0, 145, 103, 0,
- 95, 97, 143, 0, 0, 145, 96, 0, 142, 147,
- 145, 141
++ 107, 0, 106, 0, 0, 0, 0, 0, 0, 0,
++ 0, 0, 148, 0, 0, 0, 0, 92, 0, 0,
++ 0, 0, 147, 0, 0, 0, 0, 0, 89, 0,
++ 0, 0, 149, 92, 0, 0, 0, 0, 0, 99,
++ 0, 138, 0, 0, 0, 0, 0, 0, 91, 0,
++ 0, 99, 0, 93, 99, 100, 0, 0, 145, 0,
++ 0, 90, 0, 0, 99, 143, 0, 94, 101, 0,
++ 145, 142, 144, 0, 0, 0, 143, 0, 95, 97,
++ 141, 0, 0, 143, 96, 0, 140, 145, 143, 139
};
/* YYDEFGOTO[NTERM-NUM]. */
{
-1, 1, 2, 15, 23, 21, 322, 323, 55, 123,
56, 57, 58, 59, 60, 61, 62, 63, 64, 65,
- 66, 166, 245, 274, 275, 67, 276, 330, 388, 397,
- 506, 402, 303, 526, 327, 479, 68, 308, 376, 450,
- 436, 445, 549, 278, 339, 500, 69, 152, 175, 235,
+ 66, 166, 245, 274, 275, 67, 276, 330, 390, 399,
- 508, 404, 303, 528, 539, 327, 481, 68, 308, 378,
- 452, 438, 447, 552, 278, 339, 502, 69, 152, 175,
- 235, 70, 154, 176, 237, 239, 16, 17, 85, 146,
- 71, 134, 184, 206, 264, 293, 383, 72, 243, 22,
- 80, 81, 124, 113, 114, 115, 125, 172, 126, 257,
- 319, 19, 20
++ 508, 404, 303, 528, 327, 481, 68, 308, 378, 452,
++ 438, 447, 551, 278, 339, 502, 69, 152, 175, 235,
+ 70, 154, 176, 237, 239, 16, 17, 85, 146, 71,
- 134, 184, 206, 264, 293, 381, 72, 243, 22, 80,
++ 134, 184, 206, 264, 293, 383, 72, 243, 22, 80,
+ 81, 124, 113, 114, 115, 125, 172, 126, 257, 319,
+ 19, 20
};
/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
STATE-NUM. */
- #define YYPACT_NINF -435
-#define YYPACT_NINF -524
++#define YYPACT_NINF -523
static const short yypact[] =
{
- -435, 7, 81, -435, -435, -435, -435, -435, -435, -435,
- 93, 93, 93, 39, 93, -435, -435, -58, -435, 596,
- -435, 393, 635, 93, -435, -435, -435, -435, 558, -435,
- 393, 93, 93, 93, 93, 93, 93, 93, -435, -435,
- -435, -435, -435, -435, -435, -435, -435, -435, -435, -435,
- -435, -435, -435, -435, -435, -435, -435, -435, -435, -435,
- -435, -435, -435, -435, -435, -435, -435, -435, -435, -435,
- -435, -435, -435, -435, -435, -435, -435, -435, -435, -435,
- -435, -435, 230, -80, -435, 108, -435, 371, 391, 356,
- -37, -37, -435, -435, 635, 382, 382, 87, 87, 635,
- 635, 382, 382, 635, 382, 382, 382, 87, 382, 382,
- 93, 93, 93, -435, -435, -435, 93, -435, -64, 70,
- -435, -435, -435, -435, 177, -435, -435, -435, -56, -29,
- 251, 296, -435, -435, 477, -435, -435, -435, -27, -435,
- -435, -435, -435, -25, -435, -435, 29, -435, 0, 93,
- 93, -435, -435, -435, -435, 93, 93, 93, 93, 93,
- 93, 93, -435, 93, 93, -435, 13, -435, -435, -435,
- -435, 113, -66, -22, 44, 184, 188, 53, 56, -435,
- -435, -435, -435, -435, -33, -435, -435, 58, -435, 72,
- -435, -435, -435, 19, 93, 93, 14, 68, -435, 40,
- 109, -435, 93, 93, 126, -435, -435, 321, 93, 93,
- -435, -435, -435, -435, 266, 76, 83, -64, -435, 92,
- 95, -435, 103, 110, 118, 144, -435, 142, 142, -435,
- -435, 93, 93, 93, 173, 176, 93, -435, 93, 180,
- 93, 93, -435, 147, 404, -435, -435, -435, 181, 92,
- 92, 92, 92, 92, 92, 92, -435, 185, 190, 204,
- 190, -435, 213, 214, -31, -435, 93, -435, -435, -435,
- -435, -435, -435, -435, 219, -435, 240, 93, -435, -435,
- -435, -435, -435, -435, -435, -435, 93, 93, 93, 93,
- 310, -435, -435, -435, -435, 404, 122, 93, 34, 311,
- 186, 186, -435, -435, -435, -435, -435, -435, 431, 225,
- -435, 226, 190, -435, -435, 228, -435, -435, -435, -435,
- 233, -435, -435, -435, -435, 93, 186, 244, 596, 244,
- 567, 122, 93, 34, 327, 186, 186, -435, -435, -435,
- -435, -435, -435, 305, -435, 93, 238, 330, 371, -435,
- -13, 558, 186, 34, 331, 331, 331, 331, 331, 331,
- 331, 331, 331, 93, 93, 93, 34, 93, 331, 331,
- 331, -435, -435, 247, -435, -435, 244, 244, 585, -435,
- 252, 190, -435, 253, -435, -435, -435, -435, -64, -64,
- -435, -435, -435, -435, -435, -435, -435, -435, -435, -435,
- 256, -435, -435, -64, -435, -435, -435, -435, -435, 344,
- 34, 345, 345, 345, 345, 345, 345, 345, 345, 345,
- 93, 93, 93, 34, 93, 345, 345, 345, -435, 93,
- 93, 93, 93, 93, 93, 262, -64, -64, -435, -435,
- -435, -435, -435, -435, -435, -435, -435, -435, 271, -435,
- -435, -64, -435, -435, -435, -435, -435, -435, -435, 280,
- 282, 286, 287, 93, 93, 93, 93, 93, 93, 93,
- 93, 248, 290, 293, 294, 300, 301, 309, 320, 324,
- -435, 358, -435, 93, 93, 93, 93, 248, 93, 93,
- 93, 186, 360, 377, 379, 380, 381, 403, 405, 407,
- -67, 93, -435, 93, 93, 93, 186, 93, -435, 93,
- 93, 93, -435, 403, 411, 413, 77, 417, 419, 421,
- 422, -435, 93, 93, 93, 93, 93, 186, -435, 93,
- 423, 424, 425, 426, 421, 244, 432, 93, 186, 181,
- 93, 186, -435, 93, 424, 121, 361, 433, 132, 436,
- 181, 186, -435, -435, 93, 186, 93, 361, 244, 437,
- 244, 438, -435, 93, 186, 9, 244, 186, -435, 134,
- 361, -435
- -524, 22, 3, -524, -524, -524, -524, -524, -524, -524,
- 222, 222, 222, 288, 222, -524, -524, -56, -524, 387,
- -524, 361, 459, 222, -524, -524, -524, -524, 407, -524,
- 361, 222, 222, 222, 222, 222, 222, 222, -524, -524,
- -524, -524, -524, -524, -524, -524, -524, -524, -524, -524,
- -524, -524, -524, -524, -524, -524, -524, -524, -524, -524,
- -524, -524, -524, -524, -524, -524, -524, -524, -524, -524,
- -524, -524, -524, -524, -524, -524, -524, -524, -524, -524,
- -524, -524, 341, -67, -524, 82, -524, 442, 455, 335,
- 229, 229, -524, -524, 459, 343, 343, 80, 80, 459,
- 459, 343, 343, 459, 343, 343, 343, 80, 343, 343,
- 222, 222, 222, -524, -524, -524, 222, -524, -44, -45,
- -524, -524, -524, -524, 18, -524, -524, -524, -24, -16,
- 187, 192, -524, -524, 258, -524, -524, -524, 11, -524,
- -524, -524, -524, 28, -524, -524, 85, -524, 41, 222,
- 222, -524, -524, -524, -524, 222, 222, 222, 222, 222,
- 222, 222, -524, 222, 222, -524, 26, -524, -524, -524,
- -524, 388, -52, 56, 59, 283, 328, 91, 93, -524,
- -524, -524, -524, -524, -27, -524, -524, 109, -524, 111,
- -524, -524, -524, 57, 222, 222, -5, 139, -524, -1,
- 169, -524, 222, 222, 207, -524, -524, 198, 222, 222,
- -524, -524, -524, -524, 436, 132, 135, -44, -524, 147,
- 160, -524, 164, 166, 170, -7, -524, 188, 188, -524,
- -524, 222, 222, 222, 242, 8, 222, -524, 222, 35,
- 222, 222, -524, -11, 199, -524, -524, -524, 212, 147,
- 147, 147, 147, 147, 147, 147, -524, 246, 247, 254,
- 247, -524, 259, 261, -30, -524, 222, -524, -524, -524,
- -524, -524, -524, -524, 269, -524, 273, 222, -524, -524,
- -524, -524, -524, -524, -524, -524, 222, 222, 222, 222,
- 270, -524, -524, -524, -524, 199, 183, 222, 32, 316,
- 12, 12, -524, -524, -524, -524, -524, -524, 327, 313,
- -524, 315, 247, -524, -524, 320, -524, -524, -524, -524,
- 322, -524, -524, -524, -524, 288, 12, 298, -524, 298,
- 561, 183, 222, 32, 413, 12, 12, -524, -524, -524,
- -524, -524, -524, 52, -524, 222, 210, 432, -524, -19,
- 12, 32, 462, 462, 462, 462, 462, 462, 462, 462,
- 462, 222, 222, 222, 32, 222, 462, 462, 462, -524,
- -524, 349, -524, -524, 298, 298, 579, -524, 384, 247,
- -524, 385, -524, -524, -524, -524, -44, -44, -524, -524,
- -524, -524, -524, -524, -524, -524, -524, -524, 394, -524,
- -524, -44, -524, -524, -524, -524, -524, 482, 32, 483,
- 483, 483, 483, 483, 483, 483, 483, 483, 222, 222,
- 222, 32, 222, 483, 483, 483, -524, 222, 222, 222,
- 222, 222, 222, 405, -44, -44, -524, -524, -524, -524,
- -524, -524, -524, -524, -524, -524, 411, -524, -524, -44,
- -524, -524, -524, -524, -524, -524, -524, 415, 424, 430,
- 439, 222, 222, 222, 222, 222, 222, 222, 222, 216,
- 441, 443, 444, 445, 453, 460, 461, 463, -524, 466,
- -524, 222, 222, 222, 222, 216, 222, 222, 222, 12,
- 476, 477, 478, 480, 484, 485, 486, 488, 9, 222,
- -524, 222, 222, 222, 12, 222, -524, 222, 222, 222,
- -524, 485, 489, 527, 58, 536, 537, 538, 539, -524,
- 222, 222, 222, 222, 222, 12, -524, 222, 540, 538,
- 544, 546, 538, 67, 547, 222, 212, 222, 12, -524,
- 12, 222, 538, 219, 548, 106, 298, 552, 212, -524,
- -524, 222, 12, 222, 219, 556, 298, 559, -524, 222,
- 12, 131, 298, 12, -524, 126, 219, -524
++ -523, 5, 13, -523, -523, -523, -523, -523, -523, -523,
++ 284, 284, 284, 93, 284, -523, -523, -69, -523, 600,
++ -523, 392, 639, 284, -523, -523, -523, -523, 554, -523,
++ 392, 284, 284, 284, 284, 284, 284, 284, -523, -523,
++ -523, -523, -523, -523, -523, -523, -523, -523, -523, -523,
++ -523, -523, -523, -523, -523, -523, -523, -523, -523, -523,
++ -523, -523, -523, -523, -523, -523, -523, -523, -523, -523,
++ -523, -523, -523, -523, -523, -523, -523, -523, -523, -523,
++ -523, -523, 122, -66, -523, 108, -523, 391, 357, 138,
++ 27, 27, -523, -523, 639, 524, 524, 33, 33, 639,
++ 639, 524, 524, 639, 524, 524, 524, 33, 524, 524,
++ 284, 284, 284, -523, -523, -523, 284, -523, -58, 210,
++ -523, -523, -523, -523, 242, -523, -523, -523, 35, 42,
++ 254, 273, -523, -523, 448, -523, -523, -523, 50, -523,
++ -523, -523, -523, 59, -523, -523, 159, -523, 19, 284,
++ 284, -523, -523, -523, -523, 284, 284, 284, 284, 284,
++ 284, 284, -523, 284, 284, -523, 171, -523, -523, -523,
++ -523, 267, -67, 75, 78, -10, 172, 88, 104, -523,
++ -523, -523, -523, -523, 1, -523, -523, 116, -523, 121,
++ -523, -523, -523, 63, 284, 284, 0, 184, -523, 2,
++ 211, -523, 284, 284, 231, -523, -523, 287, 284, 284,
++ -523, -523, -523, -523, 311, 157, 162, -58, -523, 166,
++ 167, -523, 170, 176, 185, 203, -523, 198, 198, -523,
++ -523, 284, 284, 284, 131, 214, 284, -523, 284, 221,
++ 284, 284, -523, 201, 405, -523, -523, -523, 226, 166,
++ 166, 166, 166, 166, 166, 166, -523, 230, 233, 234,
++ 233, -523, 245, 246, 51, -523, 284, -523, -523, -523,
++ -523, -523, -523, -523, 247, -523, 376, 284, -523, -523,
++ -523, -523, -523, -523, -523, -523, 284, 284, 284, 284,
++ 325, -523, -523, -523, -523, 405, 206, 284, 39, 329,
++ 294, 294, -523, -523, -523, -523, -523, -523, 432, 249,
++ -523, 256, 233, -523, -523, 259, -523, -523, -523, -523,
++ 261, -523, -523, -523, -523, 284, 294, 265, 600, 265,
++ 563, 206, 284, 39, 351, 294, 294, -523, -523, -523,
++ -523, -523, -523, 97, -523, 284, 217, 352, 391, -523,
++ -4, 554, 294, 39, 353, 353, 353, 353, 353, 353,
++ 353, 353, 353, 284, 284, 284, 39, 284, 353, 353,
++ 353, -523, -523, 271, -523, -523, 265, 265, 581, -523,
++ 275, 233, -523, 276, -523, -523, -523, -523, -58, -58,
++ -523, -523, -523, -523, -523, -523, -523, -523, -523, -523,
++ 286, -523, -523, -58, -523, -523, -523, -523, -523, 354,
++ 39, 360, 360, 360, 360, 360, 360, 360, 360, 360,
++ 284, 284, 284, 39, 284, 360, 360, 360, -523, 284,
++ 284, 284, 284, 284, 284, 289, -58, -58, -523, -523,
++ -523, -523, -523, -523, -523, -523, -523, -523, 290, -523,
++ -523, -58, -523, -523, -523, -523, -523, -523, -523, 293,
++ 296, 297, 299, 284, 284, 284, 284, 284, 284, 284,
++ 284, 238, 301, 302, 305, 307, 308, 319, 323, 324,
++ -523, 328, -523, 284, 284, 284, 284, 238, 284, 284,
++ 284, 294, 330, 331, 332, 333, 340, 359, 361, 364,
++ -64, 284, -523, 284, 284, 284, 294, 284, -523, 284,
++ 284, 284, -523, 359, 365, 366, -23, 367, 378, 379,
++ 380, -523, 284, 284, 284, 284, 284, 294, -523, 284,
++ 396, 379, 404, 407, 379, -20, 411, 284, 226, 284,
++ 294, -523, 294, 284, 379, 313, 413, 28, 265, 417,
++ 226, -523, -523, 284, 294, 284, 313, 436, 265, 440,
++ -523, 284, 294, 152, 265, 294, -523, 80, 313, -523
};
/* YYPGOTO[NTERM-NUM]. */
static const short yypgoto[] =
{
- -435, -435, -435, -435, -435, 479, -282, -288, 368, -435,
- -435, -435, -435, -435, -435, -435, -435, -435, -435, -435,
- -435, -435, 195, -435, 237, -435, -435, -435, 210, -116,
- 20, -435, 229, 2, -10, -259, 52, -435, -435, -435,
- -435, 242, -133, -434, -387, -435, -435, -435, 315, -435,
- 117, -435, 312, -435, -435, -435, -435, -435, -435, -170,
- -435, -435, -435, 276, -435, -435, -435, -435, -435, 586,
- -435, -435, -19, -246, -245, -197, -360, -435, 569, -226,
- -2, 22, -12
- -524, -524, -524, -524, -524, 534, -276, -110, 525, -524,
- -524, -524, -524, -524, -524, -524, -524, -524, -524, -524,
- -524, -524, 425, -524, 359, -524, -524, -524, 208, 4,
- 144, -524, 348, -402, -292, 172, -524, -524, -524, -524,
- 211, 128, -356, -523, -524, -524, -524, 423, -524, -72,
- -524, 420, -524, -524, -524, -524, -524, -524, -169, -524,
- -524, -524, 397, -524, -524, -524, -524, -524, 404, -524,
- -524, -20, -249, -248, -236, -358, -524, 542, -234, -2,
- 400, 20
++ -523, -523, -523, -523, -523, 369, -283, -292, 468, -523,
++ -523, -523, -523, -523, -523, -523, -523, -523, -523, -523,
++ -523, -523, 306, -523, 241, -523, -523, -523, 295, -116,
++ 12, -523, 232, -522, -286, 52, -523, -523, -523, -523,
++ 255, -112, -328, -416, -523, -523, -523, 303, -523, -113,
++ -523, 304, -523, -523, -523, -523, -523, -523, -170, -523,
++ -523, -523, 278, -523, -523, -523, -523, -523, 582, -523,
++ -523, -19, -272, -269, -214, -396, -523, 462, -228, -2,
++ 20, -12
};
/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
positive, shift that token. If negative, reduce the rule which
number is the opposite. If zero, do what YYDEFACT says.
If YYTABLE_NINF, syntax error. */
- #define YYTABLE_NINF -243
+ #define YYTABLE_NINF -241
static const short yytable[] =
{
- 18, 27, 193, 82, 167, 168, 169, 3, 204, 170,
- 204, 290, 259, 116, 318, 192, 352, 5, 6, 187,
- 217, 83, 29, 210, 211, 212, 511, 145, 213, 145,
- 304, 305, 24, 25, 26, 165, 28, 149, 5, 6,
- 321, 317, 329, 5, 6, 374, 220, 233, 205, 372,
- 291, 36, 37, 87, 88, 89, 90, 91, 92, 93,
- 309, 311, 340, 341, 150, 388, 163, 350, 164, -219,
- 352, 194, -219, -219, 219, 119, 376, 377, 403, 306,
- 130, 131, 386, 118, 4, 5, 6, 171, 7, -219,
- 218, 5, 6, 387, 188, 128, 129, 5, 6, 10,
- 11, 8, 567, 12, 13, 138, 214, 14, 141, 142,
- 143, 342, 5, 6, 144, 222, 221, 190, 191, 380,
- 10, 11, 436, 562, 12, 13, 5, 6, 14, 317,
- 110, 568, 225, 111, 112, 451, 571, 195, 73, 74,
- 75, 76, 77, 78, 79, 9, 202, 173, 174, 203,
- 147, 208, 546, 177, 178, 179, 180, 181, 182, 183,
- 352, 185, 186, 557, 189, 209, 207, 10, 11, 231,
- 524, 12, 13, 10, 11, 14, 232, 12, 13, 10,
- 11, 14, 570, 12, 13, 234, 553, 14, 236, 117,
- 5, 6, 215, 216, 10, 11, 238, 553, 12, 13,
- 223, 224, 14, 240, 352, 553, 227, 228, 10, 11,
- 553, 241, 12, 13, 551, 352, 14, 352, 431, 432,
- 250, 251, 252, 265, 242, 555, 266, 277, 267, 247,
- 248, 249, 500, 434, 258, 244, 260, 110, 262, 263,
- 111, 112, 5, 6, 382, 253, 254, 516, 401, 402,
- 255, 405, 5, 6, 480, 296, 151, 148, 196, 197,
- 153, 297, 199, 200, 294, 198, 464, 465, 535, 201,
- 229, 230, 10, 11, 277, 307, 12, 325, 286, 545,
- 326, 467, 548, -242, 310, 312, 313, 314, 449, 450,
- 110, 453, 558, 111, 112, 320, 560, 287, 298, 299,
- 110, 300, 301, 111, 112, 566, 288, 289, 569, 5,
- 6, 110, 295, 349, 111, 112, 315, 324, 343, 345,
- 302, 346, 328, 328, 10, 11, 347, 352, 12, 13,
- 373, 151, 14, 375, 10, 11, 385, 389, 12, 13,
- 409, 379, 14, 381, 384, 429, 430, 348, 351, 433,
- 435, 437, 250, 251, 252, 463, 110, 328, 328, 111,
- 112, 400, 400, 400, 466, 400, 279, 280, 281, 282,
- 283, 284, 285, 468, 328, 469, 153, 253, 254, 470,
- 471, 110, 255, 483, 111, 112, 484, 485, 120, 121,
- 122, 10, 11, 486, 487, 12, 13, 38, 86, 14,
- 39, 226, 488, 40, 41, 42, 43, 44, 45, 46,
- 47, 48, 49, 489, 50, 51, 52, 490, 448, 448,
- 448, -219, 448, 246, -219, -219, 344, 457, 458, 459,
- 460, 461, 462, 73, 74, 75, 76, 77, 78, 79,
- 268, -219, 34, 35, 36, 37, 331, 269, 270, 271,
- 272, 491, 332, 501, 273, 32, 33, 34, 35, 36,
- 37, 472, 473, 474, 475, 476, 477, 478, 479, 482,
- 503, 53, 504, 505, 506, 54, 33, 34, 35, 36,
- 37, 492, 493, 494, 495, 482, 497, 498, 499, 333,
- 334, 110, 335, 336, 111, 112, 507, 30, 509, 512,
- 510, 513, 514, 515, 522, 517, 523, 518, 519, 520,
- 525, 337, 526, 328, 527, 529, 537, 538, 540, 541,
- 530, 531, 532, 533, 534, 543, 554, 536, 328, 556,
- 563, 564, 316, 521, 550, 544, 542, 338, 547, 496,
- 292, 549, 155, 156, 157, 158, 159, 160, 161, 328,
- 256, 261, 559, 0, 561, 0, 0, 162, 0, 0,
- 328, 565, 0, 328, 0, 391, 392, 393, 394, 395,
- 396, 397, 398, 328, 0, 0, 0, 328, 406, 407,
- 408, 0, 0, 0, 0, 0, 328, 0, 0, 328,
- 353, 354, 355, 356, 357, 358, 359, 360, 361, 362,
- 363, 364, 365, 366, 367, 368, 369, 370, 410, 411,
- 412, 413, 414, 415, 416, 417, 418, 419, 420, 421,
- 422, 423, 424, 425, 426, 427, 94, 95, 96, 97,
- 98, 99, 100, 101, 102, 103, 104, 105, 106, 107,
- 108, 31, 32, 33, 34, 35, 36, 37, 371, 0,
- 0, 109, 0, 84, 439, 440, 441, 442, 443, 444,
- 445, 446, 0, 0, 0, 127, 428, 454, 455, 456,
- 132, 133, 0, 135, 136, 137, 0, 139, 140, 31,
- 32, 33, 34, 35, 36, 37, 73, 74, 75, 76,
- 77, 78, 79
- 18, 217, 82, 193, 259, 220, 4, 5, 6, 329,
- 7, 204, 290, 543, 204, 110, 5, 6, 111, 112,
- 318, 83, 3, 8, 29, 554, 116, 304, 305, 192,
- 5, 6, 187, 27, 349, 147, 5, 6, 321, 317,
- 306, 145, 566, 374, 375, 167, 168, 169, 233, 145,
- 170, 291, 309, 311, 205, 370, 5, 6, 385, 340,
- 341, 210, 211, 212, 350, 265, 213, 9, 266, 149,
- 267, 218, 342, 242, 119, 221, 384, 150, 110, 130,
- 131, 111, 112, 118, 5, 6, 5, 6, 151, 10,
- 11, 165, 350, 12, 13, 128, 129, 14, 148, 250,
- 251, 252, 509, 325, 163, 138, 326, 188, 141, 142,
- 143, 378, 10, 11, 144, 153, 12, 13, 10, 11,
- 14, 164, 12, 13, 253, 254, 14, 536, 171, 255,
- 539, 73, 74, 75, 76, 77, 78, 79, 10, 11,
- 548, 350, 12, 13, 214, 219, 14, 173, 174, 194,
- 350, 522, 195, 177, 178, 179, 180, 181, 182, 183,
- 540, 185, 186, 117, 189, 207, 10, 11, 10, 11,
- 12, 13, 12, 13, 14, 222, 14, 279, 280, 281,
- 282, 283, 284, 285, 202, 550, 203, 5, 6, 350,
- 317, -217, 215, 216, -217, -217, 550, 498, 558, 552,
- 223, 224, 208, 550, 209, 564, 227, 228, 550, 350,
- 567, -217, 514, 225, 5, 6, 380, 429, 430, 277,
- 5, 6, 478, 372, 563, 231, 5, 6, 232, 247,
- 248, 249, 432, 533, 258, 268, 260, 344, 262, 263,
- 234, 386, 269, 270, 271, 272, 545, 110, 546, 273,
- 111, 112, 110, 236, 401, 111, 112, 238, 110, 240,
- 556, 111, 112, 241, 294, 462, 463, 151, 562, 10,
- 11, 565, 153, 12, 13, 307, 315, 14, 226, -217,
- 465, 244, -217, -217, 310, 312, 313, 314, 296, 250,
- 251, 252, 5, 6, 297, 320, 10, 11, 434, -217,
- 12, 13, 10, 11, 14, 277, 12, 13, 10, 11,
- 14, 449, 12, 13, 253, 254, 14, 36, 37, 255,
- 328, 328, 324, 155, 156, 157, 158, 159, 160, 161,
- 371, 298, 299, 110, 300, 301, 111, 112, 162, 286,
- -240, 377, 331, 379, 382, 348, 328, 287, 332, 120,
- 121, 122, 288, 302, 289, 328, 328, 196, 197, 398,
- 398, 398, 295, 398, 198, 38, 399, 400, 39, 403,
- 328, 40, 41, 42, 43, 44, 45, 46, 47, 48,
- 49, 350, 50, 51, 52, 333, 334, 110, 335, 336,
- 111, 112, 190, 191, 73, 74, 75, 76, 77, 78,
- 79, 110, 199, 200, 111, 112, 343, 337, 345, 201,
- 24, 25, 26, 346, 28, 347, 446, 446, 446, 373,
- 446, 34, 35, 36, 37, 455, 456, 457, 458, 459,
- 460, 87, 88, 89, 90, 91, 92, 93, 383, 53,
- 229, 230, 407, 54, 94, 95, 96, 97, 98, 99,
- 100, 101, 102, 103, 104, 105, 106, 107, 108, 470,
- 471, 472, 473, 474, 475, 476, 477, 480, 387, 109,
- 31, 32, 33, 34, 35, 36, 37, 427, 428, 490,
- 491, 492, 493, 480, 495, 496, 497, 431, 433, 435,
- 31, 32, 33, 34, 35, 36, 37, 510, 461, 511,
- 512, 513, 84, 515, 464, 516, 517, 518, 466, 328,
- 73, 74, 75, 76, 77, 78, 79, 467, 528, 529,
- 530, 531, 532, 468, 328, 534, 32, 33, 34, 35,
- 36, 37, 469, 542, 481, 544, 482, 483, 484, 547,
- 33, 34, 35, 36, 37, 328, 485, 447, 448, 555,
- 451, 557, 30, 486, 487, 86, 488, 561, 328, 489,
- 328, 389, 390, 391, 392, 393, 394, 395, 396, 499,
- 501, 502, 328, 503, 404, 405, 406, 504, 505, 507,
- 328, 508, 520, 328, 351, 352, 353, 354, 355, 356,
++ 18, 27, 193, 82, 304, 3, 217, 305, 220, 538,
++ 259, 29, 541, 318, 192, 329, 4, 5, 6, 352,
++ 7, 83, 550, 167, 168, 169, 145, 116, 170, 511,
++ 24, 25, 26, 8, 28, 145, 340, 5, 6, 341,
++ 350, 374, 204, 5, 6, 321, 317, 233, 372, 376,
++ 377, 87, 88, 89, 90, 91, 92, 93, 309, 311,
++ 352, 388, 306, 352, 196, 197, 387, 210, 211, 212,
++ 524, 198, 213, 542, 403, 119, 218, 9, 221, 352,
++ 130, 131, 205, 118, 73, 74, 75, 76, 77, 78,
++ 79, 386, 204, 290, 342, 128, 129, 5, 6, 10,
++ 11, 5, 6, 12, 13, 138, 171, 14, 141, 142,
++ 143, 352, 5, 6, 144, 36, 37, 380, 436, 10,
++ 11, 554, 545, 12, 13, 10, 11, 14, 149, 12,
++ 13, 451, 291, 14, 556, 150, 279, 280, 281, 282,
++ 283, 284, 285, 163, 250, 251, 252, 173, 174, 552,
++ 214, 568, 164, 177, 178, 179, 180, 181, 182, 183,
++ 552, 185, 186, 352, 189, 165, 207, 552, 194, 253,
++ 254, 195, 552, 277, 255, 5, 6, 187, 250, 251,
++ 252, 202, 110, 10, 11, 111, 112, 12, 13, 117,
++ 219, 14, 215, 216, 10, 11, 344, 203, 12, 13,
++ 223, 224, 14, 253, 254, 500, 227, 228, 255, 208,
++ 5, 6, -217, 317, 209, -217, -217, 222, 431, 432,
++ 516, 5, 6, 382, 34, 35, 36, 37, 560, 247,
++ 248, 249, -217, 434, 258, 566, 260, 225, 262, 263,
++ 569, 535, 5, 6, 480, 565, 199, 200, 401, 402,
++ 231, 405, 188, 201, 547, 232, 548, 10, 11, 234,
++ 236, 12, 13, 238, 294, 14, 464, 465, 558, 240,
++ 110, 190, 191, 111, 112, 307, 564, 265, 241, 567,
++ 266, 467, 267, 242, 310, 312, 313, 314, 5, 6,
++ 147, 244, 10, 11, 151, 320, 12, 13, 5, 6,
++ 14, 153, 110, 10, 11, 111, 112, 12, 13, 449,
++ 450, 14, 453, 349, 110, 229, 230, 111, 112, 277,
++ 328, 328, 148, 286, 10, 11, -240, 287, 12, 13,
++ 373, 315, 14, 110, 151, 324, 111, 112, 288, 289,
++ 295, 379, 343, 381, 384, 348, 351, 110, 352, 345,
++ 111, 112, 346, 153, 347, 328, 328, 375, 385, 389,
++ 435, 400, 400, 400, 409, 400, 437, 226, 429, 430,
++ 10, 11, 328, -217, 12, 13, -217, -217, 14, 433,
++ 10, 11, 463, 466, 12, 325, 468, 30, 326, 469,
++ 470, 296, 471, -217, 483, 484, 38, 297, 485, 39,
++ 486, 487, 40, 41, 42, 43, 44, 45, 46, 47,
++ 48, 49, 488, 50, 51, 52, 489, 490, 448, 448,
++ 448, 491, 448, 501, 503, 504, 505, 457, 458, 459,
++ 460, 461, 462, 506, 298, 299, 110, 300, 301, 111,
++ 112, 268, 33, 34, 35, 36, 37, 331, 269, 270,
++ 271, 272, 507, 332, 509, 273, 302, 510, 522, 523,
++ 525, 472, 473, 474, 475, 476, 477, 478, 479, 482,
++ 53, 526, 527, 529, 54, 32, 33, 34, 35, 36,
++ 37, 492, 493, 494, 495, 482, 497, 498, 499, 537,
++ 333, 334, 110, 335, 336, 111, 112, 539, 86, 512,
++ 540, 513, 514, 515, 543, 517, 553, 518, 519, 520,
++ 555, 328, 337, 155, 156, 157, 158, 159, 160, 161,
++ 530, 531, 532, 533, 534, 521, 328, 536, 162, 561,
++ 120, 121, 122, 562, 246, 544, 316, 546, 256, 496,
++ 338, 549, 292, 261, 0, 0, 0, 328, 0, 0,
++ 0, 557, 0, 559, 0, 0, 0, 0, 127, 563,
++ 328, 0, 328, 132, 133, 0, 135, 136, 137, 0,
++ 139, 140, 0, 0, 328, 73, 74, 75, 76, 77,
++ 78, 79, 328, 0, 0, 328, 353, 354, 355, 356,
+ 357, 358, 359, 360, 361, 362, 363, 364, 365, 366,
- 367, 368, 408, 409, 410, 411, 412, 413, 414, 415,
++ 367, 368, 369, 370, 410, 411, 412, 413, 414, 415,
+ 416, 417, 418, 419, 420, 421, 422, 423, 424, 425,
- 521, 437, 438, 439, 440, 441, 442, 443, 444, 523,
- 524, 525, 527, 535, 452, 453, 454, 537, 127, 538,
- 541, 551, 369, 132, 133, 553, 135, 136, 137, 559,
- 139, 140, 560, 246, 316, 519, 338, 494, 256, 261,
- 426, 292
++ 426, 427, 94, 95, 96, 97, 98, 99, 100, 101,
++ 102, 103, 104, 105, 106, 107, 108, 31, 32, 33,
++ 34, 35, 36, 37, 371, 0, 0, 109, 0, 84,
++ 391, 392, 393, 394, 395, 396, 397, 398, 0, 0,
++ 0, 0, 428, 406, 407, 408, 0, 439, 440, 441,
++ 442, 443, 444, 445, 446, 0, 0, 0, 0, 0,
++ 454, 455, 456, 31, 32, 33, 34, 35, 36, 37,
++ 73, 74, 75, 76, 77, 78, 79
};
-static const unsigned short yycheck[] =
+static const short yycheck[] =
{
- 2, 13, 172, 22, 4, 5, 6, 0, 41, 9,
- 41, 42, 238, 93, 296, 81, 83, 4, 5, 6,
- 6, 23, 80, 4, 5, 6, 93, 93, 9, 93,
- 276, 276, 10, 11, 12, 6, 14, 93, 4, 5,
- 6, 7, 301, 4, 5, 333, 6, 217, 81, 331,
- 81, 88, 89, 31, 32, 33, 34, 35, 36, 37,
- 286, 287, 308, 308, 93, 353, 93, 326, 93, 60,
- 83, 93, 63, 64, 6, 94, 335, 336, 366, 276,
- 99, 100, 95, 85, 3, 4, 5, 87, 7, 80,
- 76, 4, 5, 352, 81, 97, 98, 4, 5, 86,
- 87, 20, 93, 90, 91, 107, 87, 94, 110, 111,
- 112, 308, 4, 5, 116, 6, 76, 4, 5, 345,
- 86, 87, 410, 557, 90, 91, 4, 5, 94, 7,
- 60, 565, 6, 63, 64, 423, 570, 93, 51, 52,
- 53, 54, 55, 56, 57, 64, 93, 149, 150, 93,
- 80, 93, 539, 155, 156, 157, 158, 159, 160, 161,
- 83, 163, 164, 550, 166, 93, 185, 86, 87, 93,
- 93, 90, 91, 86, 87, 94, 93, 90, 91, 86,
- 87, 94, 569, 90, 91, 93, 546, 94, 93, 81,
- 4, 5, 194, 195, 86, 87, 93, 557, 90, 91,
- 202, 203, 94, 93, 83, 565, 208, 209, 86, 87,
- 570, 93, 90, 91, 93, 83, 94, 83, 388, 389,
- 47, 48, 49, 76, 80, 93, 79, 93, 81, 231,
- 232, 233, 491, 403, 236, 93, 238, 60, 240, 241,
- 63, 64, 4, 5, 6, 72, 73, 506, 364, 365,
- 77, 367, 4, 5, 6, 15, 80, 80, 74, 75,
- 80, 21, 74, 75, 266, 81, 436, 437, 527, 81,
- 4, 5, 86, 87, 93, 277, 90, 91, 93, 538,
- 94, 451, 541, 93, 286, 287, 288, 289, 421, 422,
- 60, 424, 551, 63, 64, 297, 555, 93, 58, 59,
- 60, 61, 62, 63, 64, 564, 93, 93, 567, 4,
- 5, 60, 93, 325, 63, 64, 6, 6, 93, 93,
- 80, 93, 300, 301, 86, 87, 93, 83, 90, 91,
- 332, 80, 94, 6, 86, 87, 6, 6, 90, 91,
- 93, 343, 94, 345, 346, 93, 93, 325, 326, 93,
- 6, 6, 47, 48, 49, 93, 60, 335, 336, 63,
- 64, 363, 364, 365, 93, 367, 249, 250, 251, 252,
- 253, 254, 255, 93, 352, 93, 80, 72, 73, 93,
- 93, 60, 77, 93, 63, 64, 93, 93, 6, 7,
- 8, 86, 87, 93, 93, 90, 91, 4, 30, 94,
- 7, 80, 93, 10, 11, 12, 13, 14, 15, 16,
- 17, 18, 19, 93, 21, 22, 23, 93, 420, 421,
- 422, 60, 424, 228, 63, 64, 309, 429, 430, 431,
- 432, 433, 434, 51, 52, 53, 54, 55, 56, 57,
- 36, 80, 86, 87, 88, 89, 15, 43, 44, 45,
- 46, 93, 21, 93, 50, 84, 85, 86, 87, 88,
- 89, 463, 464, 465, 466, 467, 468, 469, 470, 471,
- 93, 78, 93, 93, 93, 82, 85, 86, 87, 88,
- 89, 483, 484, 485, 486, 487, 488, 489, 490, 58,
- 59, 60, 61, 62, 63, 64, 93, 18, 93, 501,
- 2, 6, 22, 172, 238, 6, 3, 4, 5, 301,
- 7, 41, 42, 536, 41, 60, 4, 5, 63, 64,
- 296, 23, 0, 20, 80, 548, 93, 276, 276, 81,
- 4, 5, 6, 13, 326, 80, 4, 5, 6, 7,
- 276, 93, 565, 335, 336, 4, 5, 6, 217, 93,
- 9, 81, 286, 287, 81, 331, 4, 5, 350, 308,
- 308, 4, 5, 6, 83, 76, 9, 64, 79, 93,
- 81, 76, 308, 80, 94, 76, 95, 93, 60, 99,
- 100, 63, 64, 85, 4, 5, 4, 5, 80, 86,
- 87, 6, 83, 90, 91, 97, 98, 94, 80, 47,
- 48, 49, 93, 91, 93, 107, 94, 81, 110, 111,
- 112, 345, 86, 87, 116, 80, 90, 91, 86, 87,
- 94, 93, 90, 91, 72, 73, 94, 529, 87, 77,
- 532, 51, 52, 53, 54, 55, 56, 57, 86, 87,
- 542, 83, 90, 91, 87, 6, 94, 149, 150, 93,
- 83, 93, 93, 155, 156, 157, 158, 159, 160, 161,
- 93, 163, 164, 81, 166, 185, 86, 87, 86, 87,
- 90, 91, 90, 91, 94, 6, 94, 249, 250, 251,
- 252, 253, 254, 255, 93, 543, 93, 4, 5, 83,
- 7, 60, 194, 195, 63, 64, 554, 489, 554, 93,
- 202, 203, 93, 561, 93, 561, 208, 209, 566, 83,
- 566, 80, 504, 6, 4, 5, 6, 386, 387, 93,
- 4, 5, 6, 333, 93, 93, 4, 5, 93, 231,
- 232, 233, 401, 525, 236, 36, 238, 309, 240, 241,
- 93, 351, 43, 44, 45, 46, 538, 60, 540, 50,
- 63, 64, 60, 93, 364, 63, 64, 93, 60, 93,
- 552, 63, 64, 93, 266, 434, 435, 80, 560, 86,
- 87, 563, 80, 90, 91, 277, 6, 94, 80, 60,
- 449, 93, 63, 64, 286, 287, 288, 289, 15, 47,
- 48, 49, 4, 5, 21, 297, 86, 87, 408, 80,
- 90, 91, 86, 87, 94, 93, 90, 91, 86, 87,
- 94, 421, 90, 91, 72, 73, 94, 88, 89, 77,
- 300, 301, 6, 65, 66, 67, 68, 69, 70, 71,
- 332, 58, 59, 60, 61, 62, 63, 64, 80, 93,
- 93, 343, 15, 345, 346, 325, 326, 93, 21, 6,
- 7, 8, 93, 80, 93, 335, 336, 74, 75, 361,
- 362, 363, 93, 365, 81, 4, 362, 363, 7, 365,
- 350, 10, 11, 12, 13, 14, 15, 16, 17, 18,
- 19, 83, 21, 22, 23, 58, 59, 60, 61, 62,
- 63, 64, 4, 5, 51, 52, 53, 54, 55, 56,
- 57, 60, 74, 75, 63, 64, 93, 80, 93, 81,
- 10, 11, 12, 93, 14, 93, 418, 419, 420, 6,
- 422, 86, 87, 88, 89, 427, 428, 429, 430, 431,
- 432, 31, 32, 33, 34, 35, 36, 37, 6, 78,
- 4, 5, 93, 82, 40, 41, 42, 43, 44, 45,
- 46, 47, 48, 49, 50, 51, 52, 53, 54, 461,
- 462, 463, 464, 465, 466, 467, 468, 469, 6, 65,
- 83, 84, 85, 86, 87, 88, 89, 93, 93, 481,
- 482, 483, 484, 485, 486, 487, 488, 93, 6, 6,
- 83, 84, 85, 86, 87, 88, 89, 499, 93, 501,
- 502, 503, 95, 505, 93, 507, 508, 509, 93, 489,
- 51, 52, 53, 54, 55, 56, 57, 93, 520, 521,
- 522, 523, 524, 93, 504, 527, 84, 85, 86, 87,
- 88, 89, 93, 535, 93, 537, 93, 93, 93, 541,
- 85, 86, 87, 88, 89, 525, 93, 419, 420, 551,
- 422, 553, 18, 93, 93, 30, 93, 559, 538, 93,
- 540, 353, 354, 355, 356, 357, 358, 359, 360, 93,
- 93, 93, 552, 93, 366, 367, 368, 93, 93, 93,
- 560, 93, 93, 563, 23, 24, 25, 26, 27, 28,
++ 2, 13, 172, 22, 276, 0, 6, 276, 6, 531,
++ 238, 80, 534, 296, 81, 301, 3, 4, 5, 83,
++ 7, 23, 544, 4, 5, 6, 93, 93, 9, 93,
++ 10, 11, 12, 20, 14, 93, 308, 4, 5, 308,
++ 326, 333, 41, 4, 5, 6, 7, 217, 331, 335,
++ 336, 31, 32, 33, 34, 35, 36, 37, 286, 287,
++ 83, 353, 276, 83, 74, 75, 352, 4, 5, 6,
++ 93, 81, 9, 93, 366, 94, 76, 64, 76, 83,
++ 99, 100, 81, 85, 51, 52, 53, 54, 55, 56,
++ 57, 95, 41, 42, 308, 97, 98, 4, 5, 86,
++ 87, 4, 5, 90, 91, 107, 87, 94, 110, 111,
++ 112, 83, 4, 5, 116, 88, 89, 345, 410, 86,
++ 87, 93, 538, 90, 91, 86, 87, 94, 93, 90,
++ 91, 423, 81, 94, 550, 93, 249, 250, 251, 252,
++ 253, 254, 255, 93, 47, 48, 49, 149, 150, 545,
++ 87, 567, 93, 155, 156, 157, 158, 159, 160, 161,
++ 556, 163, 164, 83, 166, 6, 185, 563, 93, 72,
++ 73, 93, 568, 93, 77, 4, 5, 6, 47, 48,
++ 49, 93, 60, 86, 87, 63, 64, 90, 91, 81,
++ 6, 94, 194, 195, 86, 87, 309, 93, 90, 91,
++ 202, 203, 94, 72, 73, 491, 208, 209, 77, 93,
++ 4, 5, 60, 7, 93, 63, 64, 6, 388, 389,
++ 506, 4, 5, 6, 86, 87, 88, 89, 556, 231,
++ 232, 233, 80, 403, 236, 563, 238, 6, 240, 241,
++ 568, 527, 4, 5, 6, 93, 74, 75, 364, 365,
++ 93, 367, 81, 81, 540, 93, 542, 86, 87, 93,
++ 93, 90, 91, 93, 266, 94, 436, 437, 554, 93,
++ 60, 4, 5, 63, 64, 277, 562, 76, 93, 565,
++ 79, 451, 81, 80, 286, 287, 288, 289, 4, 5,
++ 80, 93, 86, 87, 80, 297, 90, 91, 4, 5,
++ 94, 80, 60, 86, 87, 63, 64, 90, 91, 421,
++ 422, 94, 424, 325, 60, 4, 5, 63, 64, 93,
++ 300, 301, 80, 93, 86, 87, 93, 93, 90, 91,
++ 332, 6, 94, 60, 80, 6, 63, 64, 93, 93,
++ 93, 343, 93, 345, 346, 325, 326, 60, 83, 93,
++ 63, 64, 93, 80, 93, 335, 336, 6, 6, 6,
++ 6, 363, 364, 365, 93, 367, 6, 80, 93, 93,
++ 86, 87, 352, 60, 90, 91, 63, 64, 94, 93,
++ 86, 87, 93, 93, 90, 91, 93, 18, 94, 93,
++ 93, 15, 93, 80, 93, 93, 4, 21, 93, 7,
++ 93, 93, 10, 11, 12, 13, 14, 15, 16, 17,
++ 18, 19, 93, 21, 22, 23, 93, 93, 420, 421,
++ 422, 93, 424, 93, 93, 93, 93, 429, 430, 431,
++ 432, 433, 434, 93, 58, 59, 60, 61, 62, 63,
++ 64, 36, 85, 86, 87, 88, 89, 15, 43, 44,
++ 45, 46, 93, 21, 93, 50, 80, 93, 93, 93,
++ 93, 463, 464, 465, 466, 467, 468, 469, 470, 471,
++ 78, 93, 93, 93, 82, 84, 85, 86, 87, 88,
++ 89, 483, 484, 485, 486, 487, 488, 489, 490, 93,
++ 58, 59, 60, 61, 62, 63, 64, 93, 30, 501,
+ 93, 503, 504, 505, 93, 507, 93, 509, 510, 511,
- 93, 80, 93, 491, 93, 93, 93, 93, 93, 93,
- 522, 523, 524, 525, 526, 93, 93, 529, 506, 93,
- 93, 93, 295, 513, 544, 537, 534, 308, 540, 487,
- 264, 543, 65, 66, 67, 68, 69, 70, 71, 527,
- 235, 239, 554, -1, 556, -1, -1, 80, -1, -1,
- 538, 563, -1, 541, -1, 355, 356, 357, 358, 359,
- 360, 361, 362, 551, -1, -1, -1, 555, 368, 369,
- 370, -1, -1, -1, -1, -1, 564, -1, -1, 567,
- 23, 24, 25, 26, 27, 28, 29, 30, 31, 32,
- 33, 34, 35, 36, 37, 38, 39, 40, 23, 24,
- 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
- 35, 36, 37, 38, 39, 40, 40, 41, 42, 43,
- 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
- 54, 83, 84, 85, 86, 87, 88, 89, 81, -1,
- -1, 65, -1, 95, 412, 413, 414, 415, 416, 417,
- 418, 419, -1, -1, -1, 96, 81, 425, 426, 427,
- 101, 102, -1, 104, 105, 106, -1, 108, 109, 83,
- 84, 85, 86, 87, 88, 89, 51, 52, 53, 54,
- 55, 56, 57
++ 93, 491, 80, 65, 66, 67, 68, 69, 70, 71,
++ 522, 523, 524, 525, 526, 513, 506, 529, 80, 93,
++ 6, 7, 8, 93, 228, 537, 295, 539, 235, 487,
++ 308, 543, 264, 239, -1, -1, -1, 527, -1, -1,
++ -1, 553, -1, 555, -1, -1, -1, -1, 96, 561,
++ 540, -1, 542, 101, 102, -1, 104, 105, 106, -1,
++ 108, 109, -1, -1, 554, 51, 52, 53, 54, 55,
++ 56, 57, 562, -1, -1, 565, 23, 24, 25, 26,
++ 27, 28, 29, 30, 31, 32, 33, 34, 35, 36,
++ 37, 38, 39, 40, 23, 24, 25, 26, 27, 28,
+ 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
- 39, 40, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 35, 36, 37, 38, 39, 40,
- 93, 410, 411, 412, 413, 414, 415, 416, 417, 93,
- 93, 93, 93, 93, 423, 424, 425, 93, 96, 93,
- 93, 93, 81, 101, 102, 93, 104, 105, 106, 93,
- 108, 109, 93, 228, 295, 511, 308, 485, 235, 239,
- 81, 264
++ 39, 40, 40, 41, 42, 43, 44, 45, 46, 47,
++ 48, 49, 50, 51, 52, 53, 54, 83, 84, 85,
++ 86, 87, 88, 89, 81, -1, -1, 65, -1, 95,
++ 355, 356, 357, 358, 359, 360, 361, 362, -1, -1,
++ -1, -1, 81, 368, 369, 370, -1, 412, 413, 414,
++ 415, 416, 417, 418, 419, -1, -1, -1, -1, -1,
++ 425, 426, 427, 83, 84, 85, 86, 87, 88, 89,
++ 51, 52, 53, 54, 55, 56, 57
};
/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
101, 83, 84, 85, 86, 87, 88, 89, 4, 7,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
21, 22, 23, 78, 82, 104, 106, 107, 108, 109,
- 110, 111, 112, 113, 114, 115, 116, 121, 133, 143,
- 147, 156, 163, 51, 52, 53, 54, 55, 56, 57,
- 166, 167, 168, 176, 95, 154, 104, 177, 177, 177,
- 177, 177, 177, 177, 165, 165, 165, 165, 165, 165,
- 165, 165, 165, 165, 165, 165, 165, 165, 165, 165,
- 60, 63, 64, 169, 170, 171, 93, 81, 176, 168,
- 6, 7, 8, 105, 168, 172, 174, 174, 176, 176,
- 168, 168, 174, 174, 157, 174, 174, 174, 176, 174,
- 174, 176, 176, 176, 176, 93, 155, 80, 80, 93,
- 93, 80, 144, 80, 148, 65, 66, 67, 68, 69,
+ 110, 111, 112, 113, 114, 115, 116, 121, 132, 142,
+ 146, 155, 162, 51, 52, 53, 54, 55, 56, 57,
+ 165, 166, 167, 175, 95, 153, 104, 176, 176, 176,
+ 176, 176, 176, 176, 164, 164, 164, 164, 164, 164,
+ 164, 164, 164, 164, 164, 164, 164, 164, 164, 164,
+ 60, 63, 64, 168, 169, 170, 93, 81, 175, 167,
+ 6, 7, 8, 105, 167, 171, 173, 173, 175, 175,
+ 167, 167, 173, 173, 156, 173, 173, 173, 175, 173,
+ 173, 175, 175, 175, 175, 93, 154, 80, 80, 93,
+ 93, 80, 143, 80, 147, 65, 66, 67, 68, 69,
70, 71, 80, 93, 93, 6, 117, 4, 5, 6,
- 9, 87, 173, 176, 176, 145, 149, 176, 176, 176,
- 176, 176, 176, 176, 158, 176, 176, 6, 81, 176,
- 4, 5, 81, 155, 93, 93, 74, 75, 81, 74,
- 75, 81, 93, 93, 41, 81, 159, 168, 93, 93,
- 4, 5, 6, 9, 87, 176, 176, 6, 76, 6,
- 6, 76, 6, 176, 176, 6, 80, 176, 176, 4,
- 5, 93, 93, 155, 93, 146, 93, 150, 93, 151,
- 93, 93, 80, 164, 93, 118, 118, 176, 176, 176,
- 47, 48, 49, 72, 73, 77, 144, 175, 176, 175,
- 176, 148, 176, 176, 160, 76, 79, 81, 36, 43,
- 44, 45, 46, 50, 119, 120, 122, 93, 140, 146,
- 146, 146, 146, 146, 146, 146, 93, 93, 93, 93,
- 42, 81, 159, 161, 176, 93, 15, 21, 58, 59,
- 61, 62, 80, 128, 169, 170, 171, 176, 134, 175,
- 176, 175, 176, 176, 176, 6, 120, 7, 102, 176,
- 176, 6, 102, 103, 6, 91, 94, 131, 177, 131,
- 123, 15, 21, 58, 59, 61, 62, 80, 128, 141,
- 169, 170, 171, 93, 146, 93, 93, 93, 177, 178,
- 131, 177, 83, 23, 24, 25, 26, 27, 28, 29,
+ 9, 87, 172, 175, 175, 144, 148, 175, 175, 175,
+ 175, 175, 175, 175, 157, 175, 175, 6, 81, 175,
+ 4, 5, 81, 154, 93, 93, 74, 75, 81, 74,
+ 75, 81, 93, 93, 41, 81, 158, 167, 93, 93,
+ 4, 5, 6, 9, 87, 175, 175, 6, 76, 6,
+ 6, 76, 6, 175, 175, 6, 80, 175, 175, 4,
+ 5, 93, 93, 154, 93, 145, 93, 149, 93, 150,
+ 93, 93, 80, 163, 93, 118, 118, 175, 175, 175,
+ 47, 48, 49, 72, 73, 77, 143, 174, 175, 174,
+ 175, 147, 175, 175, 159, 76, 79, 81, 36, 43,
+ 44, 45, 46, 50, 119, 120, 122, 93, 139, 145,
+ 145, 145, 145, 145, 145, 145, 93, 93, 93, 93,
+ 42, 81, 158, 160, 175, 93, 15, 21, 58, 59,
+ 61, 62, 80, 128, 168, 169, 170, 175, 133, 174,
+ 175, 174, 175, 175, 175, 6, 120, 7, 102, 175,
- 175, 6, 102, 103, 6, 91, 94, 130, 177, 130,
++ 175, 6, 102, 103, 6, 91, 94, 130, 176, 130,
+ 123, 15, 21, 58, 59, 61, 62, 80, 128, 140,
- 168, 169, 170, 93, 145, 93, 93, 93, 177, 130,
- 83, 23, 24, 25, 26, 27, 28, 29, 30, 31,
- 32, 33, 34, 35, 36, 37, 38, 39, 40, 81,
- 102, 175, 103, 6, 130, 130, 134, 175, 174, 175,
- 6, 161, 175, 6, 95, 130, 103, 6, 124, 124,
- 124, 124, 124, 124, 124, 124, 124, 125, 175, 125,
- 125, 103, 127, 125, 124, 124, 124, 93, 23, 24,
- 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
- 35, 36, 37, 38, 39, 40, 81, 93, 93, 154,
- 154, 93, 154, 6, 103, 6, 136, 136, 136, 136,
- 136, 136, 136, 136, 136, 137, 175, 137, 137, 103,
- 135, 137, 136, 136, 136, 175, 175, 175, 175, 175,
- 175, 93, 154, 154, 93, 154, 93, 93, 93, 93,
- 175, 175, 175, 175, 175, 175, 175, 175, 6, 131,
- 175, 93, 93, 93, 93, 93, 93, 93, 93, 93,
- 175, 175, 175, 175, 131, 175, 175, 175, 130, 93,
- 141, 93, 93, 93, 93, 93, 126, 93, 93, 93,
- 175, 175, 175, 175, 130, 175, 175, 175, 175, 126,
- 93, 93, 93, 93, 93, 93, 129, 93, 175, 175,
- 175, 175, 175, 130, 175, 93, 129, 93, 93, 129,
- 93, 93, 175, 139, 175, 130, 130, 175, 129, 138,
- 171, 93, 93, 93, 139, 175, 130, 175, 138, 93,
- 93, 175, 130, 93, 138, 130, 139, 138
++ 168, 169, 170, 93, 145, 93, 93, 93, 176, 177,
++ 130, 176, 83, 23, 24, 25, 26, 27, 28, 29,
+ 30, 31, 32, 33, 34, 35, 36, 37, 38, 39,
- 40, 81, 102, 176, 103, 6, 131, 131, 135, 176,
- 175, 176, 6, 162, 176, 6, 95, 131, 103, 6,
++ 40, 81, 102, 175, 103, 6, 130, 130, 134, 175,
++ 174, 175, 6, 161, 175, 6, 95, 130, 103, 6,
+ 124, 124, 124, 124, 124, 124, 124, 124, 124, 125,
- 176, 125, 125, 103, 127, 125, 124, 124, 124, 93,
++ 175, 125, 125, 103, 127, 125, 124, 124, 124, 93,
+ 23, 24, 25, 26, 27, 28, 29, 30, 31, 32,
+ 33, 34, 35, 36, 37, 38, 39, 40, 81, 93,
- 93, 155, 155, 93, 155, 6, 103, 6, 137, 137,
- 137, 137, 137, 137, 137, 137, 137, 138, 176, 138,
- 138, 103, 136, 138, 137, 137, 137, 176, 176, 176,
- 176, 176, 176, 93, 155, 155, 93, 155, 93, 93,
- 93, 93, 176, 176, 176, 176, 176, 176, 176, 176,
- 6, 132, 176, 93, 93, 93, 93, 93, 93, 93,
- 93, 93, 176, 176, 176, 176, 132, 176, 176, 176,
- 131, 93, 142, 93, 93, 93, 93, 93, 126, 93,
- 93, 93, 176, 176, 176, 176, 131, 176, 176, 176,
- 176, 126, 93, 93, 93, 93, 93, 93, 129, 93,
- 176, 176, 176, 176, 176, 131, 176, 93, 93, 130,
- 93, 93, 129, 93, 176, 131, 140, 176, 131, 176,
- 130, 93, 139, 172, 93, 93, 93, 140, 131, 176,
- 131, 176, 139, 93, 93, 176, 131, 93, 139, 131,
- 140, 139
++ 93, 154, 154, 93, 154, 6, 103, 6, 136, 136,
++ 136, 136, 136, 136, 136, 136, 136, 137, 175, 137,
++ 137, 103, 135, 137, 136, 136, 136, 175, 175, 175,
++ 175, 175, 175, 93, 154, 154, 93, 154, 93, 93,
++ 93, 93, 175, 175, 175, 175, 175, 175, 175, 175,
++ 6, 131, 175, 93, 93, 93, 93, 93, 93, 93,
++ 93, 93, 175, 175, 175, 175, 131, 175, 175, 175,
++ 130, 93, 141, 93, 93, 93, 93, 93, 126, 93,
++ 93, 93, 175, 175, 175, 175, 130, 175, 175, 175,
++ 175, 126, 93, 93, 93, 93, 93, 93, 129, 93,
++ 175, 175, 175, 175, 175, 130, 175, 93, 129, 93,
++ 93, 129, 93, 93, 175, 139, 175, 130, 130, 175,
++ 129, 138, 171, 93, 93, 93, 139, 175, 130, 175,
++ 138, 93, 93, 175, 130, 93, 138, 130, 139, 138
};
#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
}
/* Line 999 of yacc.c. */
- #line 4136 "y.tab.c"
-#line 4129 "y.tab.c"
++#line 4135 "y.tab.c"
\f
yyvsp -= yylen;
yyssp -= yylen;