Fix building on FreeBSD and install server.pub file to correct

Minor fix to main.c, which corrects building on FreeBSD, and also the location of the server.pub file.

This is what we are doing to the new port I just added for FreeBSD:

http://www.freshports.org/net-im/telegram-cli/