From: Kevin Locke Date: Thu, 29 Sep 2016 00:44:45 +0000 (-0600) Subject: configurator: Add output cflag option and macro X-Git-Url: http://git.ozlabs.org/?p=ccan;a=commitdiff_plain;h=aacc2cb8e22a369b910816dc41a6a411d29a12bb;hp=aacc2cb8e22a369b910816dc41a6a411d29a12bb configurator: Add output cflag option and macro Unfortunately, not all compilers support -o as a command-line option for specifying the output file. Visual Studio cl.exe issues warning D9035 when -o is given, which is detected as a compile warning by the configurator. To support such compilers, add the command-line option -O to configurator which can be used to specify the cflag for setting the output executable file name. Additionally define the macro CCAN_OUTPUT_EXE_CFLAG in config.h and use it when invoking the compiler (e.g. from ccanlint). For reference, the name CCAN_OUTPUT_EXE_CFLAG was chosen to avoid potential name conflicts in the future due to cl.exe requiring different flags for different types of output[1] (e.g. object files are /Fo:). 1. https://msdn.microsoft.com/en-us/library/f1cb223a.aspx Signed-off-by: Kevin Locke Signed-off-by: David Gibson ---