Fix generate-emacs-packages.sh when called outside of the directory.

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
Replace dots in attribute names with underscores.

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>