There is a similar issue here: Building custom filebeat debian Still trying to figure out why this happens
For the Makefile: We just merged a PR and you need to change BEATNAME to BEAT_NAME and BEAT_DIR to BEAT_PATH. But this should not be related to this issue.