// Load //------------------------------------------------------------------------------ /*static*/ Node * ObjectListNode::Load( NodeGraph & nodeGraph, IOStream & stream ) { NODE_LOAD( AStackString<>, name ); NODE_LOAD_NODE( CompilerNode, compilerNode ); NODE_LOAD( AStackString<>, compilerArgs ); NODE_LOAD( AStackString<>, compilerArgsDeoptimized ); NODE_LOAD( AStackString<>, compilerOutputPath ); NODE_LOAD_DEPS( 16, staticDeps ); NODE_LOAD_NODE( Node, precompiledHeader ); NODE_LOAD( AStackString<>, objExtensionOverride ); NODE_LOAD( AStackString<>, compilerOutputPrefix ); NODE_LOAD_DEPS( 0, compilerForceUsing ); NODE_LOAD_DEPS( 0, preBuildDependencies ); NODE_LOAD( bool, deoptimizeWritableFiles ); NODE_LOAD( bool, deoptimizeWritableFilesWithToken ); NODE_LOAD( bool, allowDistribution ); NODE_LOAD( bool, allowCaching ); NODE_LOAD_NODE( CompilerNode, preprocessorNode ); NODE_LOAD( AStackString<>, preprocessorArgs ); NODE_LOAD( AStackString<>, baseDirectory ); NODE_LOAD( AStackString<>, extraPDBPath ); NODE_LOAD( AStackString<>, extraASMPath ); ObjectListNode * n = nodeGraph.CreateObjectListNode( name, staticDeps, compilerNode, compilerArgs, compilerArgsDeoptimized, compilerOutputPath, precompiledHeader ? precompiledHeader->CastTo< ObjectNode >() : nullptr, compilerForceUsing, preBuildDependencies, deoptimizeWritableFiles, deoptimizeWritableFilesWithToken, allowDistribution, allowCaching, preprocessorNode, preprocessorArgs, baseDirectory ); n->m_ObjExtensionOverride = objExtensionOverride; n->m_CompilerOutputPrefix = compilerOutputPrefix; n->m_ExtraPDBPath = extraPDBPath; n->m_ExtraASMPath = extraASMPath; // TODO:B Need to save the dynamic deps, for better progress estimates // but we can't right now because we rely on the nodes we depend on // being saved before us which isn't the case for dynamic deps. //if ( Node::LoadDepArray( fileStream, n->m_DynamicDependencies ) == false ) //{ // FDELETE n; // return nullptr; //} return n; }
// Load //------------------------------------------------------------------------------ /*static*/ Node * ExeNode::Load( IOStream & stream ) { // common Linker properties NODE_LOAD( AStackString<>, name ); NODE_LOAD( AStackString<>, linker ); NODE_LOAD( AStackString<>, linkerArgs ); NODE_LOAD_DEPS( 0, inputLibs); NODE_LOAD( uint32_t, flags ); NODE_LOAD_DEPS( 0, assemblyResources ); NODE_LOAD_DEPS( 0, otherLibs ); NODE_LOAD( AStackString<>, importLibName ); NODE_LOAD_NODE( Node, linkerStampExe ); NODE_LOAD( AStackString<>, linkerStampExeArgs ); NodeGraph & ng = FBuild::Get().GetDependencyGraph(); ExeNode * en = ng.CreateExeNode( name, inputLibs, otherLibs, linker, linkerArgs, flags, assemblyResources, importLibName, linkerStampExe, linkerStampExeArgs ); return en; }