Make util.isEmulated return a boolean.

Some places in koreader code were using it as an integer, another places were using it as a boolean.
Make it a boolean. This fixes part of koreader#20.
Merge pull request #55 from thotypous/frontlight-fixes

Make util.isEmulated return a boolean.
Implement util.realpath
Merge pull request #56 from thotypous/realpath

Implement util.realpath