Compute flycheck command line options properly

This causes flycheck to find the current packages from the buffer-local
packages variable as well as from the local .ipkg file.

Fixes #271.