Skip to content

{ Category Archives } Software

Valgrind on Mac OS X merged to trunk!

Nicholas Nethercote just posted about Valgrind on Mac OS X having been merged to the Valgrind’s trunk. Valgrind is an incredible debugging tool, if you aren’t familiar with it already I’d really recommend you take a look. As far as I’m concerned this is one of the most exciting things to happen to Mac OS X […]

So what is /dev/autofs_nowait ?

When examining running processes and logfiles on OS X, it’s quite common to see calls to open ‘/dev/autofs_nowait’, but what’s the file for?? Looking at the on-disk file doesn’t give many clues: ls -al /dev/autofs_nowait crw-rw-rw- 1 root wheel 10, 27 May 4 17:29 /dev/autofs_nowait So just how often is this file getting […] Tagged , , ,

OS X Semaphores

Amongst many others, OS X has the following synchronization primitives: Named POSIX semaphores pthread condition variables Mach Semaphores Unnamed POSIX Semaphores (sem_init()) are not supported (the function is defined in the header but calling it returns ENOSYS). Named POSIX semaphores and condition variables are implemented internally using Mach semaphores which in their own right […]

virtualenv

This looks really useful… (via James Bennet’s article on pip). Python, Software

Fun with duplicity

I was playing around with crontabs and duplicity today on OS X 10.5 Leopard. I’d written a python script that executes duplicity, my script ran just fine from the shell, but churned out the following cryptic error message when run from crontab: … Cleanup of temporary directory /var/folders/7Q/7Qlu3ZqFHeuxCbNgaimO2E+++TI/-Tmp-/duplicity-ben2Y6-tempdir failed - this is probably a bug. Traceback (most recent […]

frustration

It’s a little frustrating when you google for information on something only to find that the top links are things you’ve written. Software

Opt-In?

Yesterday I ordered tickets on Fandango, at the end of the process I was rewarded with a familiar popup window at the bottom of the browser. Turns out, Fandango are nice enough to automagically add a post to your Facebook minifeed when you order movie tickets through them. The sad part is that this is turned on […] Tagged ,

Hidden Gems

Google just released an open source C++ style guide, lots of good solid advice in there. Software

Make

Much to my chagrin, I seem to be finding myself in need of understanding and making fundamental changes to Makefiles for various projects I’m not familiar with, every few months. I’ve found the $(warning “foo”) and $(error “foo”) directives pretty useful in this capacity, the former printing some text during a Makefile’s evaluation, and the latter […] Tagged

Batteries Included

A neat property of Python’s sort function is that it automatically sorts list of tuples by the first value of the tuple, this means that if you have a list, lets say of files and their sizes and you want to sort by filesize, you can do: >>> a = [(200, ‘foo.txt’), (100, ‘bar.txt’)] >>> a.sort() >>> a [(100, […] Tagged ,