Replace dirname( __FILE__ ) with __DIR__

Change-Id: I8317c2b72048a423a3430812b093ef95ecc90b37