g++: add multiple file example (#8468)
This commit is contained in:
@@ -19,3 +19,11 @@
|
||||
- Include libraries located at a different path than the source file:
|
||||
|
||||
`g++ {{path/to/source.cpp}} -o {{path/to/output_executable}} -I{{path/to/header}} -L{{path/to/library}} -l{{library_name}}`
|
||||
|
||||
- Compile and link multiple source code files into an executable binary:
|
||||
|
||||
`g++ -c {{path/to/source_1.cpp path/to/source_2.cpp ...}} && g++ -o {{path/to/output_executable}} {{path/to/source_1.o path/to/source_2.o ...}}`
|
||||
|
||||
- Display version:
|
||||
|
||||
`g++ --version`
|
||||
|
Reference in New Issue
Block a user