Skip to content

Commit 5b6789c

Browse files
committed
Removed the compiler-flags property
This updates the documentation in accordance with lf-lang/lingua-franca#2233
1 parent 40ed6c4 commit 5b6789c

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

docs/reference/target-declaration.mdx

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ A target specification may have optional parameters, the names and values of whi
3030
- [**cargo-features**](#cargo-features): (Rust only) List of string names of features to include.
3131
- [**cmake-include**](#cmake): List of paths to cmake files to guide compilation.
3232
- [**compiler**](#compiler): A string giving the name of the target language compiler to use.
33-
- [**compiler-flags**](#compiler-flags): An arrays of strings giving options to be passed to the target compiler.
3433
- [**docker**](#docker): A boolean to generate a Dockerfile.
3534
- [**external-runtime-path**](#external-runtime-path): Specify a pre-compiled external runtime library located to link to instead of the default.
3635
- [**export-dependency-graph**](#export-dependency-graph): To export the reaction dependency graph as a dot graph (for debugging).
@@ -58,7 +57,6 @@ c={
5857
build-type: <Release, Debug, RelWithDebInfo, or MinSizeRel>,
5958
cmake-include: <string or list of strings>,
6059
compiler: <string>,
61-
compiler-flags: <string or list of strings>,
6260
docker: <true or false>,
6361
fast: <true or false>,
6462
files: <string or list of strings>,
@@ -128,7 +126,6 @@ For example:
128126
target C {
129127
cmake: false,
130128
compiler: "cc",
131-
flags: "-O3",
132129
fast: true,
133130
logging: log,
134131
timeout: 1 secs,
@@ -349,27 +346,6 @@ to point to your preferred compiler. Possible values are, for instance, `gcc`,
349346
</ShowIf>
350347
</ShowIfs>
351348

352-
## compiler-flags
353-
354-
<ShowIfs>
355-
<ShowIf cpp py ts rs>
356-
This target does not support the `compiler-flags` parameter.
357-
</ShowIf>
358-
<ShowIf c>
359-
This parameter is a list of strings giving additional arguments to pass to the target language compiler. For example:
360-
361-
```lf-c
362-
target C {
363-
compiler-flags: ["-g", "-I/usr/local/include", "-L/usr/local/lib", "-lpaho-mqtt3c"],
364-
};
365-
```
366-
367-
The `compiler-flags` option specifies to include debug information in the compiled code (`-g`); a directory to search for include files (`-I/usr/local/include`); a directory to search for library files (`-L/usr/local/lib`); a library to link with (`-lpaho-mqtt3c`, which will link with file `libpaho-mqtt3c.so`).
368-
369-
**Note**: Using the `compiler-flags` parameter is strongly discouraged, although supported. Flags are compiler-specific, and thus interfere with CMake's ability to find the most suitable compiler for each platform. In a similar fashion, we recommend against the use of the `compiler` standard parameter for the same reason. A better solution is to provide a `cmake-include` file.
370-
</ShowIf>
371-
</ShowIfs>
372-
373349
## docker
374350

375351
<ShowIfs>

0 commit comments

Comments
 (0)