Tenseg News

Alex Celeste on 23 November 2009 / Comment

One of the key new features in the latest release of Xcode (v. 3.2.1) is the built-in Clang Static Analyzer. For those that don’t know, the Clang Static Analyzer has been around for some time as an extra tool developers can install. The extra layer it provides on top of the normal errors and warnings of Xcode is that it will look at your code, without executing it, and go down every possible path to find memory leaks or any other kind of logic error that may be in your code and easily missed when reading the code as a human. In my personal opinion every developer should regularly use the Clang Static Analyzer, which is why it was so nice when Apple included it as part of Xcode a little while back (I’d used the standalone version of the analyzer once). Only today did I finally get the built-in analyzer to properly function.

It took me so long to figure it out that I thought I should explain it here: With the default settings the “Build and Analyze” menu item in the “Build” menu won’t work (I kept trying this for weeks with no results). Nor will setting the active compiler in project settings to Clang LLVM 1.0 and using the menu item. Instead you can keep the compiler at the default GCC 4.2 and just check the Run Static Analyzer checkbox in project settings. Now each time you build your code (no need to build and go) it will be analyzed and the output embedded in the source code windows the same way that the errors and warnings are.

Alex Celeste on 1 November 2009 / Comment

This afternoon I was looking up any possible ways to automatically start OS X’s Internet Sharing at boot. Given that the feature isn’t designed to be used as a permanent (in this case) airport base station Apple doesn’t provide any method of keeping the service gong across reboots. That is something that many people have given hints as to how to accomplish. Most are in editing system configuration files, and at least one is in creating a StartupItem. Now, the average Mac user doesn’t want to play around with hidden files used by Mac OS X, and StartupItems have been made obsolete by the new (as of 10.4 and first used extensively in 10.5) launchd process that runs all specially formatted plist documents in the root and system library subfolders /LaunchAgents and /LaunchDaemons. So, this afternoon I wrote my own LaunchDaemon plist to accomplish this task and have made it publicly available here on the Tenseg website. This new method of accomplishing the task that many of hinted at uses the new launchd versus the obsolete StartupItems. If you’ve been looking for a way of accomplishing this then look no further and please download this piece of software.

Tenseg Logo