mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-08-04 14:55:56 +02:00
add clang
This commit is contained in:
parent
2e34e66405
commit
3407a4ae65
1 changed files with 15 additions and 0 deletions
15
pages/common/clang.md
Normal file
15
pages/common/clang.md
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
# clang
|
||||||
|
|
||||||
|
> Compiler for C, C++, and Objective-C source files. Can be used as a drop-in replacement for GCC.
|
||||||
|
|
||||||
|
- Compile a source code file into an executable binary
|
||||||
|
|
||||||
|
`clang {{input_source.c}} -o {{output_executable}}`
|
||||||
|
|
||||||
|
- Activate output of all errors and warnings
|
||||||
|
|
||||||
|
`clang {{input_source.c}} -Wall -o {{output_executable}}`
|
||||||
|
|
||||||
|
- Include libraries located at a different path than the source file
|
||||||
|
|
||||||
|
`clang {{input_source.c}} -o {{output_executable}} -I{{header_path}} -L{{library_path}} -l{{library_name}}`
|
Loading…
Add table
Reference in a new issue