command-log: format must be string literal

When using fig_command_log we must make sure that we use a string
literal as format string. Otherwise we might end up with the following
error message:

    format not a string literal and no format arguments
    [-Werror=format-security]

Also we must make sure that fig_command_log takes care of the message
even when program is non-null.
Makefile: make sure the -l flag is in proper place

If the linker place is before the objects we might end up
with a lot of undefined references.