From 2971f432b0da0d787507ed098d5bbfd417d6f949 Mon Sep 17 00:00:00 2001 From: ruki Date: Sun, 23 Jun 2019 10:21:53 +0800 Subject: fix tip and warn --- manual/project_target.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'manual/project_target.md') diff --git a/manual/project_target.md b/manual/project_target.md index 3b6bdcbb..04840411 100644 --- a/manual/project_target.md +++ b/manual/project_target.md @@ -318,7 +318,7 @@ target("test") set_options("hello") ``` -

+

Some settings defined in [option](#option) will affect this `target` target only after calling `set_options` for the association to take effect, such as macro definitions, link libraries, compile options, etc.

@@ -465,7 +465,7 @@ The c standard and the c++ standard can be set at the same time, for example: set_languages("c99", "cxx11") ``` -

+

Instead of setting the specified standard, the compiler will compile according to this standard. After all, each compiler supports different strengths, but xmake will try to adapt the support standard of the current compiler tool to the greatest extent possible. . .

E.g: @@ -478,7 +478,7 @@ Users do not need to make any additional modifications. . #### Set output directories for header files -

+

Note that this interface has been deprecated after version 2.2.5, please use [add_headerfiles](#targetadd_headerfiles) instead.

@@ -1091,7 +1091,7 @@ target("test") #### Set auto-generated config header file -

+

After the 2.2.5 version, this interface has been deprecated, please use [add_configfiles](#targetadd_configfiles). After the 2.1.5 version, this interface has been deprecated, please use [set_config_header](#targetset_config_header).

@@ -1142,7 +1142,7 @@ target("test") #### Set macro prefix in auto-generated config header -

+

After the 2.2.5 version, this interface has been deprecated, please use [add_configfiles](#targetadd_configfiles). After the 2.1.5 version, this interface has been deprecated, please use [set_config_header](#targetset_config_header).

@@ -1163,7 +1163,7 @@ Then, the $(prefix) of `add_defines_h("$(prefix)_TYPE_HAVE_WCHAR")` in the optio #### Set macro prefix in auto-generated config header and prefix -

+

After the 2.2.5 version, this interface has been deprecated, please use [add_configfiles](#targetadd_configfiles). After the 2.1.5 version, this interface has been deprecated, please use [set_config_header](#targetset_config_header).

@@ -1492,7 +1492,7 @@ And exclude `src/subdir/xxx.c` (that is, don't delete this file). #### Add installed header files -

+

Note that this interface has been deprecated after version 2.2.5, please use [add_headerfiles](#targetadd_headerfiles) instead.

@@ -1630,7 +1630,7 @@ In the code is equivalent to: `#undef DEBUG` #### Add macro definition to auto-generated config header -

+

After the 2.2.5 version, this interface has been deprecated, please use [add_configfiles](#targetadd_configfiles).

@@ -1640,7 +1640,7 @@ Add macro definitions to the `config.h` configuration file, `config.h` settings, #### Add macro undefinition to auto-generated config header -

+

After the 2.2.5 version, this interface has been deprecated, please use [add_configfiles](#targetadd_configfiles).

@@ -1656,7 +1656,7 @@ Add compilation options only for c code add_cflags("-g", "-O2", "-DDEBUG") ``` -

+

All option values ​​are based on the definition of gcc as standard. If other compilers are not compatible (for example: vc), xmake will automatically convert it internally to the corresponding option values ​​supported by the compiler. Users don't have to worry about compatibility. If other compilers don't have matching values, xmake will automatically ignore the settings.

@@ -1867,7 +1867,7 @@ Similar to [add_cfunc](#targetadd_cfunc), only the function interface detected i #### Add c functions for checking -

+

This interface is the interface shared by `target` and `option`, but the interface behavior is slightly different.

@@ -1891,7 +1891,7 @@ target("test") This option detects if there are some interfaces of `setjmp`. If the test passes, then the `test` target program will add the macro definition of `HAVE_SETJMP`. -

+

Note that using this interface to detect dependencies in `option` requires adding a separate [add_cincludes](#targetadd_cincludes) header file search path and specifying [add_links](#targetadd_links) link library (optional). Otherwise the specified function is not detected.

And some header file interfaces are defined by macro switches, so it is best to pass the dependent macro switch with [add_defines](#targetadd_defines) when detecting. -- cgit v1.2.3