Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ TheIDE » U++ TheIDE: Installation, Compiling and Running of theide » build_info.h last line not terminated
build_info.h last line not terminated [message #51918] Thu, 20 June 2019 13:59
Alboni is currently offline  Alboni
Messages: 214
Registered: January 2012
Location: Deventer, Netherlands
Experienced Member
UPP version 13389 + Visual C++ 19 + windows 7

Issue:
The last line of build_info.h doesn't always end with \r\n
This gives compiling issues when using it in certain tools like windows resource compiler.
index.php?t=getfile&id=5859&private=0

The working fix I applied to TheIde

void CppBuilder::SaveBuildInfo(const String& package)
{
	String path = AppendFileName(outdir, "build_info.h");
	RealizePath(path);
	FileOut info(path);
	Time t = GetSysTime();
	info << "#define bmYEAR   " << (int)t.year << "\r\n";
	info << "#define bmMONTH  " << (int)t.month << "\r\n";
	info << "#define bmDAY    " << (int)t.day << "\r\n";
	info << "#define bmHOUR   " << (int)t.hour << "\r\n";
	info << "#define bmMINUTE " << (int)t.minute << "\r\n";
	info << "#define bmSECOND " << (int)t.second << "\r\n";
	info << Format("#define bmTIME   Time(%d, %d, %d, %d, %d, %d)\r\n",
	        (int)t.year, (int)t.month, (int)t.day, (int)t.hour, (int)t.minute, (int)t.second);
	info << "#define bmMACHINE " << AsCString(GetComputerName()) << "\r\n";
	info << "#define bmUSER    " << AsCString(GetUserName()) << "\r\n";

	if(package == mainpackage)
		info << Join(SvnInfo(package), "\r\n") << "\r\n";
}

Note: I added
<< "\r\n"
after
info << Join(SvnInfo(package), "\r\n")

[Updated on: Thu, 20 June 2019 14:35]

Report message to a moderator

Previous Topic: Postgresql libpq-fe.h compilation error in windows
Next Topic: TheIDE for Windows doesn't run
Goto Forum:
  


Current Time: Thu Mar 28 12:37:55 CET 2024

Total time taken to generate the page: 0.01364 seconds