Lifehack: If you can’t compile old XCode project “There is no SDK with the name or path”

If your old project fails to compile with XCode with error like
error: There is no SDK with the name or path ‘/path/to/my/project/macosx10.6’

even if you changed target in the XCode Build Settings, then you stumbled upon silly bug in the XCode. It’s just unable to change SDKROOT in your pbxproject file. Edit it manually and remove all SDKROOT lines.

How to redirect std C++ streams to Visual Studio debug output

Discovered this trick for the first time. You can use AllocConsole() to redirect ANY std stream to debug console.

In most cases people use either TRACE() statement (but you have include MFC or ATL for that) or Win API OutputDebugString().

With AllocConsole() your code may look like this:

   freopen("CONOUT$", "w", stdout);

That’s it!

Learning something new every day. 😀

Home and End keys remap on Mac

Little hack which will make Home and End buttons work as they’re working in most OS’s except for Mac.

https://apple.stackexchange.com/questions/16135/remap-home-and-end-to-beginning-and-end-of-line

Proudly powered by WordPress
Theme: Esquire by Matthew Buchanan.