Synology uses a stripped-down version of Busybox, so some commands are missing. 
It's very well possible `pidof` wasn't available pre-4.1, or in even earlier versions, although I can't tell which. If using `pidof` in itself is acceptable (and I like that heaps better than ps | grep myself), then you could set a minimum firmware version in the Makefile.