Update find-entries.php to 2013

* Add support for __DIR__ (added in PHP 5.3)
* Support RUN_MAINTENANCE_IF_MAIN define,
renamed from DO_MAINTENANCE in r80205 (26505b17)

Change-Id: I9620ac6371fc2e9016e5d4d97c3c65c2ff4faa75