Update cmake build system

Dear Georg,

As mentioned in issue #6, here are my changes to the cmake files, so that they are at the top directory of the project, which makes life a lot easier for some tools like Debian's debhelper.

It would be lovely if you could merge these commits, as it fixes #6. I hope that I didn't miss any of the changes in my tree.

Thanks.

Signed-off-by: Rogério Brito <rbrito@ime.usp.br>