# Unable to compile custom beat based on metricbeat

**URL:** <https://discuss.elastic.co/t/unable-to-compile-custom-beat-based-on-metricbeat/123085>\
**Category:** Beats\
**Tags:** beats-development\
**Created:** [March 8, 2018, 2:05pm UTC](https://discuss.elastic.co/t/unable-to-compile-custom-beat-based-on-metricbeat/123085 "2018-03-08T14:05:40Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![dcroonen](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dcroonen/32/27450_2.png) [@dcroonen](https://discuss.elastic.co/u/dcroonen)\
**Post date:** [March 9, 2018, 7:41am UTC](https://discuss.elastic.co/t/unable-to-compile-custom-beat-based-on-metricbeat/123085/2 "2018-03-09T07:41:16Z")

</div>

Ok I mananged to get this through by commenting out line 50 and 51 in `vendor/github.com/elastic/beats/dev-tools/packer/Makefile` and by running the `make package` command with the options `SNAPSHOT=no CGO=false PACKAGES=${BEAT_NAME}/deb TARGETS="linux/amd64 linux/386"`.

Note: This only builds .deb packages but at the moment this is enough for my purposes.

Anybody any thoughts on this because commenting out lines in Makefiles doesn't feel as the right way to go?

Regards

---

_[View the full topic](https://discuss.elastic.co/t/unable-to-compile-custom-beat-based-on-metricbeat/123085)._
