->Read(prj.get(), prj->GetThisTypeInfo());
65 voidSaveToXmlFile(
const string& file_path,
const CSerialObject& project)
70 CDirproject_dir(dir);
71 if( !project_dir.Exists() ) {
82xs.SetReferenceSchema();
83xs.SetUseSchemaLocation(
false);
85xs.SetReferenceDTD(
false);
93 voidSaveIfNewer(
const string& file_path,
const CSerialObject& project)
97SaveToXmlFile(file_path, project);
105 stringcandidate_file_path = file_path +
".candidate";
106SaveToXmlFile(candidate_file_path, project);
111 PTB_TRACE(
"Left intact: "<< file_path);
115 voidSaveIfNewer (
const string& file_path,
117 const string& ignore)
119 stringcandidate_file_path = file_path +
".candidate";
120SaveToXmlFile(candidate_file_path, project);
122 PTB_TRACE(
"Left intact: "<< file_path);
129 const string& candidate_path,
130 const string& ignore)
134 if(ifs_present.is_open()) {
140 stringstr_present, str_new;
141 booleol_present=
false, eol_new =
false;
165 if(!eol_present && !eol_new) {
184 const string& candidate_path)
189 if( !ifs_present ) {
197ifs_present.seekg(0, ios::end);
198 size_tfile_length_present = ifs_present.tellg() - streampos(0);
200ifs_present.seekg(0, ios::beg);
208ifs_new.seekg(0, ios::end);
209 size_tfile_length_new = ifs_new.tellg() - streampos(0);
210ifs_new.seekg(0, ios::beg);
212 if(file_length_present != file_length_new) {
224TAutoArray buf_present = TAutoArray(
new char[file_length_present]);
225TAutoArray buf_new = TAutoArray(
new char[file_length_new]);
227ifs_present.read(buf_present.get(), file_length_present);
228ifs_new.read (buf_new.get(), file_length_new);
234 if(memcmp(buf_present.get(), buf_new.get(), file_length_present) != 0) {
255 bool Insert(
const string& guid,
const string& path);
256 const string&
GetGuidUser(
const string& guid)
const;
282 GetApp().GetRegSettings().m_CompilersSubdir);
284 GetApp().GetBuildType().GetTypeStr());
286 GetApp().GetRegSettings().m_ProjectsSubdir);
289 GetApp().GetProjectTreeInfo().m_Src, source_dir));
299 while( !is.eof() ) {
300is.getline(
buf,
sizeof(
buf));
301 buf[
sizeof(
buf)-1] =
char(0);
303string::size_type start, end;
304start =
data.find(
"ProjectGUID");
305 if(start == string::npos) {
306start =
data.find(
"ProjectGuid");
308 if(start != string::npos) {
309start =
data.find(
'{',start);
310 if(start != string::npos) {
311end =
data.find(
'}',++start);
312 if(end != string::npos) {
313guid =
data.substr(start,end-start);
323 "MSVC Project GUID already in use by " 330 return "{"+ guid +
"}";
337:root_guid(
"8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942"),
338guid_base(
"8BC9CEB8-8B4A-11D0-8D11-"),
352ost.unsetf(ios::showbase);
353ost.setf (ios::uppercase);
354ost <<
hex<< setw(12) << setfill(
'A') <<
m_Seed++ << ends << flush;
360 if(!guid.empty() && guid !=
root_guid) {
386 #if NCBI_COMPILER_MSVC 388 if(SUCCEEDED(CoCreateGuid(&guid))) {
392 out<< setw(8) << guid.Data1 <<
'-' 393<< setw(4) << guid.Data2 <<
'-' 394<< setw(4) << guid.Data3 <<
'-' 395<< setw(2) << (
unsigned int)guid.Data4[0]
396<< setw(2) << (
unsigned int)guid.Data4[1] <<
'-' 397<< setw(2) << (
unsigned int)guid.Data4[2]
398<< setw(2) << (
unsigned int)guid.Data4[3]
399<< setw(2) << (
unsigned int)guid.Data4[4]
400<< setw(2) << (
unsigned int)guid.Data4[5]
401<< setw(2) << (
unsigned int)guid.Data4[6]
402<< setw(2) << (
unsigned int)guid.Data4[7];
411 return "{"+ proto +
"}";
423 if(explicit_c &&
CFile(file_path).Exists()) {
429 if(explicit_cpp &&
CFile(file_path).Exists()) {
432 string file= file_path +
".cpp";
440 file= file_path +
".c";
458:m_Debug(
false), m_VTuneAddon(
false), m_Unicode(
false), m_rtType(rtUnknown)
464 const string& runtime_library)
466m_RuntimeLibrary(runtime_library),
468m_VTuneAddon(
false),
527 constlist<string>& config_names,
528list<SConfigInfo>* configs)
530 ITERATE(list<string>, p, config_names) {
532 const string& config_name = *p;
534 config.m_Name = config_name;
537 "FALSE") !=
"FALSE";
539 "runtimeLibraryOption",
"0"));
540configs->push_back(
config);
546 config.m_VTuneAddon =
true;
547configs->push_back(
config);
548 config.m_VTuneAddon =
false;
551 if(
GetApp().m_AddUnicode) {
552 config.m_Unicode =
true;
553configs->push_back(
config);
555 if(
GetApp().m_TweakVTuneR) {
558 config.m_Unicode =
false;
559 config.m_VTuneAddon =
true;
560configs->push_back(
config);
561 if(
GetApp().m_AddUnicode) {
562 config.m_Unicode =
true;
563configs->push_back(
config);
574 #if defined(NCBI_XCODE_BUILD) || defined(PSEUDO_XCODE) 583 #elif defined(NCBI_COMPILER_MSVC) 589 #elif _MSC_VER >= 1800 593 #elif _MSC_VER >= 1700 597 #elif _MSC_VER >= 1600 601 #elif _MSC_VER >= 1500 605 #elif _MSC_VER >= 1400 640 #if defined(NCBI_XCODE_BUILD) || defined(PSEUDO_XCODE) 665 if(!
GetApp().m_Arch.empty()) {
672 #elif defined(NCBI_COMPILER_MSVC) 712 if(!
GetApp().m_Arch.empty()) {
714 if(
a==
"Win32") {
717}
else if(
a==
"x64") {
745 if(arch !=
"i386") {
777 return "10.0.30319.1";
788 return "10.00\n# Visual Studio 2008";
790 return "11.00\n# Visual Studio 2010";
792 return "12.00\n# Visual Studio 2012";
794 return "12.00\n# Visual Studio 2013";
807 return "$(Configuration)";
824 return ".xcodeproj";
832 stringtop(
GetApp().GetConfig().GetString(section,
"TopBuilddir",
""));
835 if(!
CFile(top).Exists()) {
843 bool IsSubdir(
const string& abs_parent_dir,
const string& abs_dir)
850 const string& section,
854 stringsection_spec = section +
'.'+
config;
855 stringval_spec =
registry.
Get(section_spec, opt);
856 if( !val_spec.empty() )
864 const string& section,
871 stringspec =
config.m_Debug ?
"debug":
"release";
872 stringcfgName(
config.m_Name), cfgFullName(
config.GetConfigFullName());
875 if(cfgName != cfgFullName) {
876s.assign(section).append(1,
'.').append(build).append(1,
'.').append(spec).append(1,
'.').append(cfgFullName);
879s.assign(section).append(1,
'.').append(spec).append(1,
'.').append(cfgFullName);
882s.assign(section).append(1,
'.').append(build).append(1,
'.').append(spec).append(1,
'.').append(cfgName);
885s.assign(section).append(1,
'.').append(spec).append(1,
'.').append(cfgName);
888s.assign(section).append(1,
'.').append(build).append(1,
'.').append(spec);
891s.assign(section).append(1,
'.').append(
version).append(1,
'.').append(spec);
894s.assign(section).append(1,
'.').append(spec);
897s.assign(section).append(1,
'.').append(build);
900s.assign(section).append(1,
'.').append(platform);
903s.assign(section).append(1,
'.').append(
version);
920 #if NCBI_COMPILER_MSVC 922CSrcToFilterInserterWithPch::CSrcToFilterInserterWithPch
923(
const string& project_id,
924 constlist<SConfigInfo>& configs,
925 const string& project_dir)
926: m_ProjectId (project_id),
930m_AllConfigs (
GetApp().GetRegSettings().m_ConfigInfo),
932m_AllConfigs (configs),
934m_ProjectDir (project_dir)
939CSrcToFilterInserterWithPch::~CSrcToFilterInserterWithPch(
void)
944 voidCSrcToFilterInserterWithPch::InsertFile(
CRef<CFilter>& filter,
945 const string& rel_source_file,
946 const string& pch_default,
947 const string& enable_cfg)
950 file->SetAttlist().SetRelativePath(rel_source_file);
952TPch pch_usage = DefinePchUsage(m_ProjectDir, rel_source_file, pch_default);
955 ITERATE(list<SConfigInfo>, iconfig, m_AllConfigs) {
956 const string&
config= (*iconfig).GetConfigFullName();
960 if(m_Configs.size() != m_AllConfigs.size() &&
961find(m_Configs.begin(), m_Configs.end(), *iconfig) == m_Configs.end()) {
962file_config->SetAttlist().SetExcludedFromBuild(
"true");
964 else if( !enable_cfg.empty() && enable_cfg !=
config) {
965file_config->SetAttlist().SetExcludedFromBuild(
"true");
969compilerl_tool->SetAttlist().SetName(
"VCCLCompilerTool");
971 if(pch_usage.first == eCreate) {
972compilerl_tool->SetAttlist().SetPreprocessorDefinitions
973(
GetApp().GetMetaMakefile().GetPchUsageDefine());
974compilerl_tool->SetAttlist().SetUsePrecompiledHeader(
"1");
975compilerl_tool->SetAttlist().SetPrecompiledHeaderThrough
977}
else if(pch_usage.first == eUse) {
978compilerl_tool->SetAttlist().SetPreprocessorDefinitions
979(
GetApp().GetMetaMakefile().GetPchUsageDefine());
983compilerl_tool->SetAttlist().SetUsePrecompiledHeader(
"2");
985compilerl_tool->SetAttlist().SetUsePrecompiledHeader(
"3");
988 if(pch_usage.second != pch_default) {
989compilerl_tool->SetAttlist().SetPrecompiledHeaderThrough
994compilerl_tool->SetAttlist().SetUsePrecompiledHeader(
"0");
997file_config->SetTool(*compilerl_tool);
998 file->SetFileConfiguration().push_back(file_config);
1001ce->SetFile(*
file);
1002filter->SetFF().SetFF().push_back(ce);
1008CSrcToFilterInserterWithPch::operator()(
CRef<CFilter>& filter,
1009 const string& rel_source_file,
1010 const string& pch_default)
1014InsertFile(filter, rel_source_file, pch_default);
1020 ITERATE(list<SConfigInfo>, icfg, m_AllConfigs) {
1021 const string& cfg = (*icfg).GetConfigFullName();
1023 ".@config@",
"."+ cfg);
1024InsertFile(filter, source_file, pch_default, cfg);
1029CSrcToFilterInserterWithPch::TPch
1030CSrcToFilterInserterWithPch::DefinePchUsage(
const string& project_dir,
1031 const string& rel_source_file,
1032 const string& pch_file)
1034 if( pch_file.empty() )
1035 returnTPch(eNotUse,
"");
1037 stringabs_source_file =
1045 returnTPch(eNotUse,
"");
1054 if(m_PchHeaders.find(pch_file) == m_PchHeaders.end()) {
1056m_PchHeaders.insert(pch_file);
1057 returnTPch(eCreate, pch_file);
1060 returnTPch(eUse, pch_file);
1067CBasicProjectsFilesInserter::CBasicProjectsFilesInserter
1069 const string& project_id,
1070 constlist<SConfigInfo>& configs,
1071 const string& project_dir)
1072: m_Vcproj (vcproj),
1073m_SrcInserter(project_id, configs, project_dir),
1074m_Filters (project_dir)
1076m_Filters.Initilize();
1080CBasicProjectsFilesInserter::~CBasicProjectsFilesInserter(
void)
1084 voidCBasicProjectsFilesInserter::AddSourceFile(
1085 const string& rel_file_path,
const string& pch_default)
1087m_Filters.AddSourceFile(m_SrcInserter, rel_file_path, pch_default);
1090 voidCBasicProjectsFilesInserter::AddHeaderFile(
const string& rel_file_path)
1092m_Filters.AddHeaderFile(rel_file_path);
1095 voidCBasicProjectsFilesInserter::AddInlineFile(
const string& rel_file_path)
1097m_Filters.AddInlineFile(rel_file_path);
1100 voidCBasicProjectsFilesInserter::Finalize(
void)
1102 if(m_Filters.m_SourceFiles->IsSetFF()) {
1103m_Vcproj->SetFiles().SetFilter().push_back(m_Filters.m_SourceFiles);
1105 if( m_Filters.m_HeaderFilesPrivate->IsSetFF() ) {
1107ce->SetFilter(*m_Filters.m_HeaderFilesPrivate);
1108m_Filters.m_HeaderFiles->SetFF().SetFF().push_back(ce);
1110 if( m_Filters.m_HeaderFilesImpl->IsSetFF() ) {
1112ce->SetFilter(*m_Filters.m_HeaderFilesImpl);
1113m_Filters.m_HeaderFiles->SetFF().SetFF().push_back(ce);
1115 if(m_Filters.m_HeaderFiles->IsSetFF()) {
1116m_Vcproj->SetFiles().SetFilter().push_back(m_Filters.m_HeaderFiles);
1118 if(m_Filters.m_InlineFiles->IsSetFF()) {
1119m_Vcproj->SetFiles().SetFilter().push_back(m_Filters.m_InlineFiles);
1125 static bools_IsPrivateHeader(
const string& header_abs_path)
1128 returnheader_abs_path.find(src_dir) !=
NPOS;
1132 static bools_IsImplHeader(
const string& header_abs_path)
1137 returnheader_abs_path.find(src_trait) !=
NPOS;
1142CBasicProjectsFilesInserter::SFiltersItem::SFiltersItem(
void)
1145CBasicProjectsFilesInserter::SFiltersItem::SFiltersItem
1146(
const string& project_dir)
1147:m_ProjectDir(project_dir)
1151 voidCBasicProjectsFilesInserter::SFiltersItem::Initilize(
void)
1153m_SourceFiles.Reset(
new CFilter());
1154m_SourceFiles->SetAttlist().SetName(
"Source Files");
1155m_SourceFiles->SetAttlist().SetFilter
1156(
"cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx");
1158m_HeaderFiles.Reset(
new CFilter());
1159m_HeaderFiles->SetAttlist().SetName(
"Header Files");
1160m_HeaderFiles->SetAttlist().SetFilter(
"h;hpp;hxx;hm;inc");
1162m_HeaderFilesPrivate.Reset(
new CFilter());
1163m_HeaderFilesPrivate->SetAttlist().SetName(
"Private");
1164m_HeaderFilesPrivate->SetAttlist().SetFilter(
"h;hpp;hxx;hm;inc");
1166m_HeaderFilesImpl.Reset(
new CFilter());
1167m_HeaderFilesImpl->SetAttlist().SetName(
"Impl");
1168m_HeaderFilesImpl->SetAttlist().SetFilter(
"h;hpp;hxx;hm;inc");
1170m_InlineFiles.Reset(
new CFilter());
1171m_InlineFiles->SetAttlist().SetName(
"Inline Files");
1172m_InlineFiles->SetAttlist().SetFilter(
"inl");
1176 voidCBasicProjectsFilesInserter::SFiltersItem::AddSourceFile
1177(CSrcToFilterInserterWithPch& inserter_w_pch,
1178 const string& rel_file_path,
1179 const string& pch_default)
1181inserter_w_pch(m_SourceFiles, rel_file_path, pch_default);
1184 voidCBasicProjectsFilesInserter::SFiltersItem::AddHeaderFile
1185(
const string& rel_file_path)
1188 file->SetAttlist().SetRelativePath(rel_file_path);
1191ce->SetFile(*
file);
1193 stringabs_header_path =
1196 if( s_IsPrivateHeader(abs_header_path) ) {
1197m_HeaderFilesPrivate->SetFF().SetFF().push_back(ce);
1198}
else if( s_IsImplHeader(abs_header_path) ) {
1199m_HeaderFilesImpl->SetFF().SetFF().push_back(ce);
1201m_HeaderFiles->SetFF().SetFF().push_back(ce);
1206 voidCBasicProjectsFilesInserter::SFiltersItem::AddInlineFile
1207(
const string& rel_file_path)
1210 file->SetAttlist().SetRelativePath(rel_file_path);
1213ce->SetFile(*
file);
1214m_InlineFiles->SetFF().SetFF().push_back(ce);
1220CDllProjectFilesInserter::CDllProjectFilesInserter
1223 constlist<SConfigInfo>& configs,
1224 const string& project_dir)
1226m_DllProjectKey (dll_project_key),
1227m_SrcInserter (dll_project_key.Id(),
1230m_ProjectDir (project_dir),
1231m_PrivateFilters(project_dir)
1234m_PrivateFilters.m_SourceFiles.Reset(
new CFilter());
1235m_PrivateFilters.m_SourceFiles->SetAttlist().SetName(
"Source Files");
1236m_PrivateFilters.m_SourceFiles->SetAttlist().SetFilter
1237(
"cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx");
1239m_PrivateFilters.m_HeaderFiles.Reset(
new CFilter());
1240m_PrivateFilters.m_HeaderFiles->SetAttlist().SetName(
"Header Files");
1241m_PrivateFilters.m_HeaderFiles->SetAttlist().SetFilter(
"h;hpp;hxx;hm;inc");
1243m_PrivateFilters.m_HeaderFilesPrivate.Reset(
new CFilter());
1244m_PrivateFilters.m_HeaderFilesPrivate->SetAttlist().SetName(
"Private");
1245m_PrivateFilters.m_HeaderFilesPrivate->SetAttlist().SetFilter(
"h;hpp;hxx;hm;inc");
1247m_PrivateFilters.m_HeaderFilesImpl.Reset(
new CFilter());
1248m_PrivateFilters.m_HeaderFilesImpl->SetAttlist().SetName(
"Impl");
1249m_PrivateFilters.m_HeaderFilesImpl->SetAttlist().SetFilter(
"h;hpp;hxx;hm;inc");
1251m_PrivateFilters.m_InlineFiles.Reset(
new CFilter());
1252m_PrivateFilters.m_InlineFiles->SetAttlist().SetName(
"Inline Files");
1253m_PrivateFilters.m_InlineFiles->SetAttlist().SetFilter(
"inl");
1256m_HostedLibrariesRootFilter.Reset(
new CFilter());
1257m_HostedLibrariesRootFilter->SetAttlist().SetName(
"Hosted Libraries");
1258m_HostedLibrariesRootFilter->SetAttlist().SetFilter(
"");
1262CDllProjectFilesInserter::~CDllProjectFilesInserter(
void)
1267 voidCDllProjectFilesInserter::AddSourceFile (
1268 const string& rel_file_path,
const string& pch_default)
1276m_PrivateFilters.AddSourceFile(m_SrcInserter, rel_file_path, pch_default);
1280THostedLibs::iterator p = m_HostedLibs.find(proj_key);
1281 if(p != m_HostedLibs.end()) {
1282TFiltersItem& filters_item = p->second;
1283filters_item.AddSourceFile(m_SrcInserter, rel_file_path, pch_default);
1287TFiltersItem new_item(m_ProjectDir);
1288new_item.Initilize();
1289new_item.AddSourceFile(m_SrcInserter, rel_file_path, pch_default);
1290m_HostedLibs[proj_key] = new_item;
1293 voidCDllProjectFilesInserter::AddHeaderFile(
const string& rel_file_path)
1303 if(p !=
GetApp().GetWholeTree().m_Projects.end()) {
1304 const CProjItem& proj_item = p->second;
1306m_PrivateFilters.AddHeaderFile(rel_file_path);
1312THostedLibs::iterator p = m_HostedLibs.find(proj_key);
1313 if(p != m_HostedLibs.end()) {
1314TFiltersItem& filters_item = p->second;
1315filters_item.AddHeaderFile(rel_file_path);
1319TFiltersItem new_item(m_ProjectDir);
1320new_item.Initilize();
1321new_item.AddHeaderFile(rel_file_path);
1322m_HostedLibs[proj_key] = new_item;
1325 voidCDllProjectFilesInserter::AddInlineFile(
const string& rel_file_path)
1333m_PrivateFilters.AddInlineFile(rel_file_path);
1337THostedLibs::iterator p = m_HostedLibs.find(proj_key);
1338 if(p != m_HostedLibs.end()) {
1339TFiltersItem& filters_item = p->second;
1340filters_item.AddInlineFile(rel_file_path);
1344TFiltersItem new_item(m_ProjectDir);
1345new_item.Initilize();
1346new_item.AddInlineFile(rel_file_path);
1347m_HostedLibs[proj_key] = new_item;
1351 voidCDllProjectFilesInserter::Finalize(
void)
1353m_Vcproj->SetFiles().SetFilter().push_back(m_PrivateFilters.m_SourceFiles);
1355 if( !m_PrivateFilters.m_HeaderFilesPrivate->IsSetFF() ) {
1357ce->SetFilter(*m_PrivateFilters.m_HeaderFilesPrivate);
1358m_PrivateFilters.m_HeaderFiles->SetFF().SetFF().push_back(ce);
1360 if( !m_PrivateFilters.m_HeaderFilesImpl->IsSetFF() ) {
1362ce->SetFilter(*m_PrivateFilters.m_HeaderFilesImpl);
1363m_PrivateFilters.m_HeaderFiles->SetFF().SetFF().push_back(ce);
1365m_Vcproj->SetFiles().SetFilter().push_back(m_PrivateFilters.m_HeaderFiles);
1367m_Vcproj->SetFiles().SetFilter().push_back(m_PrivateFilters.m_InlineFiles);
1371 const CProjKey& proj_key = p->first;
1372TFiltersItem& filters_item = p->second;
1376hosted_lib_filter->SetAttlist().SetFilter(
"");
1380ce->SetFilter(*(filters_item.m_SourceFiles));
1381hosted_lib_filter->SetFF().SetFF().push_back(ce);
1384 if( filters_item.m_HeaderFilesPrivate->IsSetFF() ) {
1386ce->SetFilter(*filters_item.m_HeaderFilesPrivate);
1387filters_item.m_HeaderFiles->SetFF().SetFF().push_back(ce);
1389 if( filters_item.m_HeaderFilesImpl->IsSetFF() ) {
1391ce->SetFilter(*filters_item.m_HeaderFilesImpl);
1392filters_item.m_HeaderFiles->SetFF().SetFF().push_back(ce);
1396ce->SetFilter(*(filters_item.m_HeaderFiles));
1397hosted_lib_filter->SetFF().SetFF().push_back(ce);
1401ce->SetFilter(*(filters_item.m_InlineFiles));
1402hosted_lib_filter->SetFF().SetFF().push_back(ce);
1406ce->SetFilter(*hosted_lib_filter);
1407m_HostedLibrariesRootFilter->SetFF().SetFF().push_back(ce);
1410m_Vcproj->SetFiles().SetFilter().push_back(m_HostedLibrariesRootFilter);
1417 constlist<SConfigInfo> configs,
1418 const string& project_dir,
1422 file->SetAttlist().SetRelativePath
1426 ITERATE(list<SConfigInfo>,
n, configs) {
1428 const string&
config= (*n).GetConfigFullName();
1434custom_build->SetAttlist().SetName(
"VCCustomBuildTool");
1435custom_build->SetAttlist().SetDescription(build_info.
m_Description);
1436custom_build->SetAttlist().SetCommandLine(build_info.
m_CommandLine);
1437custom_build->SetAttlist().SetOutputs(build_info.
m_Outputs);
1438custom_build->SetAttlist().SetAdditionalDependencies
1440file_config->SetTool(*custom_build);
1442 file->SetFileConfiguration().push_back(file_config);
1445ce->SetFile(*
file);
1446filter->SetFF().SetFF().push_back(ce);
1458 #if NCBI_COMPILER_MSVC 1459 return tolower((
unsigned char)(dir1[0])) ==
tolower((
unsigned char)(dir2[0]));
1462 if(dir1[0] ==
'/'&& dir2[0] ==
'/') {
1463string::size_type n1= dir1.find_first_of(
'/', 1);
1464string::size_type n2= dir2.find_first_of(
'/', 1);
1465 if(n1 != string::npos && n1 == n2) {
1466 returndir1.compare(0,n1,dir2,0,n2) == 0;
1476 switch(project_id.
Type()) {
1478 returnproject_id.
Id() +
".exe";
1480 returnproject_id.
Id() +
".lib";
1482 returnproject_id.
Id() +
".dll";
1485 returnproject_id.
Id() +
".unix";
1487 returnproject_id.
Id();
1489 returnproject_id.
Id() +
".dataspec";
1491 returnproject_id.
Id();
1502 stringext(d.
GetExt());
1504 if(ext ==
".exe") {
1506}
else if(ext ==
".lib") {
1508}
else if(ext ==
".dll") {
1510}
else if(ext ==
".dataspec") {
1522:m_Type(dll_flag? eDll: eStatic)
1584 const CProjKey& dll_project_id)
const 1589 const CProjKey& lib_id = p->second;
1597 const CProjKey& dll_project_id)
const 1602 const CProjKey& lib_id = p->second;
1609 const CProjKey& dll_project_id)
const 1614 const CProjKey& lib_id = p->second;
1621 const CProjKey& dll_project_id)
const 1626 const CProjKey& lib_id = p->second;
1633 const CProjKey& dll_project_id)
const 1669 if(
n!=
GetApp().GetWholeTree().m_Projects.end()) {
1687asn_base = src_base.substr(0, src_base.length() -3);
1689asn_base = src_base.substr(0, src_base.length() -2);
1693 stringasn_name = asn_base +
".asn";
1694 stringdtd_name = asn_base +
".dtd";
1695 stringxsd_name = asn_base +
".xsd";
1696 stringwsdl_name = asn_base +
".wsdl";
1697 stringjsd_name = asn_base +
".jsd";
1702 if((
asn.m_SourceFile == asn_name) ||
1703(
asn.m_SourceFile == dtd_name) ||
1704(
asn.m_SourceFile == xsd_name) ||
1705(
asn.m_SourceFile == wsdl_name) ||
1706(
asn.m_SourceFile == jsd_name)
1716 if(
CFile(def).Exists()) {
1719 if(reg.
GetString(
"-",
"-oc",
"") == asn_base) {
string GetTypeStr(void) const
EBuildType GetType(void) const
void RegisterExtraFile(const string &inl_file_path, const CProjKey &dll_project_id, const CProjKey &lib_project_id)
pair< string, CProjKey > TDllSrcKey
CProjKey GetHeaderLib(const string &hdr_file_path, const CProjKey &dll_project_id) const
void RegisterSource(const string &src_file_path, const CProjKey &dll_project_id, const CProjKey &lib_project_id)
CProjKey GetFileLib(const string &file_path, const CProjKey &dll_project_id) const
CProjKey GetSourceLib(const string &src_file_path, const CProjKey &dll_project_id) const
CProjKey GetExtraFileLib(const string &ex_file_path, const CProjKey &dll_project_id) const
void RegisterInline(const string &inl_file_path, const CProjKey &dll_project_id, const CProjKey &lib_project_id)
CProjKey GetInlineLib(const string &inl_file_path, const CProjKey &dll_project_id) const
void RegisterHeader(const string &hrd_file_path, const CProjKey &dll_project_id, const CProjKey &lib_project_id)
map< string, string > m_Trace
const string & GetGuidUser(const string &guid) const
string Generate12Chars(void)
string DoGenerateSlnGUID()
bool Insert(const string &guid, const string &path)
static string GetVcprojExt(void)
static EMsvcPlatform GetMsvcPlatform(void)
static string sm_MsvcPlatformName
static string GetMsvcSection(void)
static string sm_RequestedArchs
static string sm_MsvcVersionName
static const string & GetMsvcVersionName(void)
static string GetProjectFileFormatVersion(void)
static const string & GetMsvcPlatformName(void)
static EMsvcVersion sm_MsvcVersion
static void IdentifyPlatform(void)
static string GetTopBuilddir(void)
static string GetSolutionFileFormatVersion(void)
static string GetConfigNameKeyword(void)
static const string & GetRequestedArchs(void)
static EMsvcPlatform sm_MsvcPlatform
static EMsvcVersion GetMsvcVersion(void)
static string GetMsvcRegSection(void)
CNcbiOstrstreamToString class helps convert CNcbiOstrstream to a string Sample usage:
CProjBulderAppException â.
const CBuildType & GetBuildType(void)
CDllSrcFilesDistr & GetDllFilesDistr(void)
void RegisterGeneratedFile(const string &file)
const SProjectTreeInfo & GetProjectTreeInfo(void)
const CProjectItemsTree & GetWholeTree(void)
const CMsvc7RegSettings & GetRegSettings(void)
list< CProjKey > m_Depends
What projects this project is depend upon (IDs).
list< CDataToolGeneratedSrc > m_DatatoolSources
Source files *.asn , *.dtd to be processed by datatool app.
string m_SourcesBaseDir
Base directory of source files (....c++/src/a/ )
const string & Id(void) const
TProjType Type(void) const
Base class for all serializable objects.
CVisualStudioProject â.
container_type::const_iterator const_iterator
const_iterator end() const
const_iterator find(const key_type &key) const
std::ofstream out("events_result.xml")
main entry point for tests
#define test(a, b, c, d, e)
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
#define NON_CONST_ITERATE(Type, Var, Cont)
Non constant version of ITERATE macro.
@ eNoOwnership
No ownership is assumed.
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
static string NormalizePath(const string &path, EFollowLinks follow_links=eIgnoreLinks)
Normalize a path.
string GetBase(void) const
Get the base entry name without extension.
bool CreatePath(TCreateFlags flags=fCreate_Default) const
Create the directory path recursively possibly more than one at a time.
bool Rename(const string &new_path, TRenameFlags flags=fRF_Default)
Rename entry.
virtual bool Remove(TRemoveFlags flags=eRecursive) const
Remove a directory entry.
static string AddTrailingPathSeparator(const string &path)
Add trailing path separator, if needed.
static string CreateRelativePath(const string &path_from, const string &path_to)
Create a relative path between two points in the file system specified by their absolute paths.
static char GetPathSeparator(void)
Get path separator symbol specific for the current platform.
static string ConcatPath(const string &first, const string &second)
Concatenate two parts of the path for the current OS.
string GetExt(void) const
Get extension name.
static void SplitPath(const string &path, string *dir=0, string *base=0, string *ext=0)
Split a path string into its basic components.
static CObjectIStream * Open(ESerialDataFormat format, CNcbiIstream &inStream, bool deleteInStream)
Create serial object reader and attach it to an input stream.
virtual const string & Get(const string §ion, const string &name, TFlags flags=0) const
Get the parameter value.
virtual string GetString(const string §ion, const string &name, const string &default_value, TFlags flags=0) const
Get the parameter string value.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
CNcbiIstream & NcbiGetlineEOL(CNcbiIstream &is, string &str, string::size_type *count=NULL)
Read from "is" to "str" the next line (taking into account platform specifics of End-of-Line)
IO_PREFIX::ofstream CNcbiOfstream
Portable alias for ofstream.
IO_PREFIX::ifstream CNcbiIfstream
Portable alias for ifstream.
static int CompareNocase(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2)
Case-insensitive compare of a substring with another string.
static list< string > & Split(const CTempString str, const CTempString delim, list< string > &arr, TSplitFlags flags=0, vector< SIZE_TYPE > *token_pos=NULL)
Split a string using specified delimiters.
static bool EndsWith(const CTempString str, const CTempString end, ECase use_case=eCase)
Check if a string ends with a specified suffix value.
static void TruncateSpacesInPlace(string &str, ETrunc where=eTrunc_Both)
Truncate whitespace in a string (in-place)
static string IntToString(int value, TNumToStringFlags flags=0, int base=10)
Convert int to string.
static SIZE_TYPE Find(const CTempString str, const CTempString pattern, ECase use_case=eCase, EDirection direction=eForwardSearch, SIZE_TYPE occurrence=0)
Find the pattern in the string.
static string Join(const TContainer &arr, const CTempString &delim)
Join strings using the specified delimiter.
static string & Replace(const string &src, const string &search, const string &replace, string &dst, SIZE_TYPE start_pos=0, SIZE_TYPE max_replace=0, SIZE_TYPE *num_replace=0)
Replace occurrences of a substring within a string.
static bool StartsWith(const CTempString str, const CTempString start, ECase use_case=eCase)
Check if a string starts with a specified prefix value.
static bool SplitInTwo(const CTempString str, const CTempString delim, string &str1, string &str2, TSplitFlags flags=0)
Split a string into two pieces using the specified delimiters.
static enable_if< is_arithmetic< TNumeric >::value||is_convertible< TNumeric, Int8 >::value, string >::type NumericToString(TNumeric value, TNumToStringFlags flags=0, int base=10)
Convert numeric value to string.
static string & ReplaceInPlace(string &src, const string &search, const string &replace, SIZE_TYPE start_pos=0, SIZE_TYPE max_replace=0, SIZE_TYPE *num_replace=0)
Replace occurrences of a substring within a string.
static int CompareCase(const CTempString s1, SIZE_TYPE pos, SIZE_TYPE n, const char *s2)
Case-sensitive compare of a substring with another string.
@ fSplit_MergeDelimiters
Merge adjacent delimiters.
@ eNocase
Case insensitive compare.
unsigned int
A callback function used to compare two keys in a database.
if(yy_accept[yy_current_state])
static void hex(unsigned char c)
#define MSVC_PROJECT_FILE_EXT
MSVC 7.10 project defines.
#define XCODE_REG_SECTION
string GenerateSlnGUID(void)
Generate pseudo-GUID.
string ConfigName(const string &config)
return <config>|Win32 as needed by MSVC compiler
string SourceFileExt(const string &file_path)
Get extension for source file without extension.
bool s_Config_less(const SConfigInfo &x, const SConfigInfo &y)
const CDataToolGeneratedSrc * IsProducedByDatatool(const string &src_path_abs, const CProjItem &project)
bool SameRootDirs(const string &dir1, const string &dir2)
Checks if 2 dirs has the same root.
string GetOpt(const CPtbRegistry ®istry, const string §ion, const string &opt, const string &config)
void LoadConfigInfoByNames(const CNcbiRegistry ®istry, const list< string > &config_names, list< SConfigInfo > *configs)
bool PromoteIfDifferent(const string &present_path, const string &candidate_path, const string &ignore)
CProjKey CreateProjKey(const string &project_name)
string IdentifySlnGUID(const string &source_dir, const CProjKey &proj)
string CreateProjectName(const CProjKey &project_id)
Project naming schema.
bool IsSubdir(const string &abs_parent_dir, const string &abs_dir)
Is abs_dir a parent of abs_parent_dir.
constexpr bool empty(list< Ts... >) noexcept
const string version
version string
const struct ncbi::grid::netcache::search::fields::KEY key
const GenericPointer< typename T::ValueType > T2 value
void SleepSec(unsigned long sec, EInterruptOnSignal onsignal=eRestartOnSignal)
Sleep.
std::istream & in(std::istream &in_, double &x_)
CProjBulderApp & GetApp(void)
access to App singleton
#define PTB_INFO_EX(file, err_code, msg)
@ ePTB_ConfigurationError
#define PTB_WARNING_EX(file, err_code, msg)
enum SConfigInfo::@976 m_rtType
bool operator==(const SConfigInfo &cfg) const
@ rtMultiThreadedDebugDLL
string GetConfigFullName(void) const
void SetRuntimeLibrary(const string &lib)
string m_AdditionalDependencies
string m_Compilers
<compilers> branch of tree
string m_Src
<src> branch of tree
string m_Impl
<impl> sub-branch of include/* project path
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4