Build gdbserver with compiler optimizations

Gdbserver for some reason was built without optimization level, making it
-O0. It is not noticeable in most user scenarious, which are not bound by
performance of gdbserver, however still better to make it optimized, as
there could be some corner cases where it will help.

Another part of this patch is to properly use CFLAGS_FOR_TARGET. For some
reason we've been using values of CFLAGS when building gdbserver, instead of a proper
environment variable. This value also was coming before our forced CFLAGS:
-O3 -static etc. So our flags have been overriding user settings. This patch
moves reference to CFLAGS_FOR_TARGET to the end of CFLAGS definition, so
user can actually override our flags.

Signed-off-by: Anton Kolesov <anton.kolesov@synopsys.com>