Fix issues #26: Ensure __DIR__ is defined.