Compilation and Makefiles (ITI8510): erinevus redaktsioonide vahel
Mine navigeerimisribale
Mine otsikasti
Uus lehekülg: '{{Iti8510}} ''Here we want to be on the same page regarding some compilation topics.'' ==Task== # Create a program which consists of multiple files, each containing a single fu...' |
Resümee puudub |
||
| (ei näidata sama kasutaja üht vahepealset redaktsiooni) | |||
| 4. rida: | 4. rida: | ||
==Task== | ==Task== | ||
# Create a program which consists of multiple files, each containing a single function. Functions would be as follows: main(), func1() and func2() | # Create a program which consists of multiple files, each containing a single function. Functions would be as follows: main(), func1() and func2(). Main should call these functions. Also add the header files for func1 and func2. | ||
# Compile the program, run it. | # Compile the program, run it. | ||
# Show how the preprocessor affects the compilation of main.c (save the file) | # Show how the preprocessor affects the compilation of main.c (save the file) | ||
| 10. rida: | 10. rida: | ||
# Create a makefile for the compilation. | # Create a makefile for the compilation. | ||
# Modify the makefile so that you compile .o files, then link them together into a working program. | # Modify the makefile so that you compile .o files, then link them together into a working program. | ||
[[Kategooria:RTOS]] | |||
Viimane redaktsioon: 17. november 2017, kell 09:49
| Real-Time Operating Systems and Systems Programming |
| [ @ ] |
Here we want to be on the same page regarding some compilation topics.
Task
- Create a program which consists of multiple files, each containing a single function. Functions would be as follows: main(), func1() and func2(). Main should call these functions. Also add the header files for func1 and func2.
- Compile the program, run it.
- Show how the preprocessor affects the compilation of main.c (save the file)
- Show the assembly code of main.c (save the file before translation to the machine code).
- Create a makefile for the compilation.
- Modify the makefile so that you compile .o files, then link them together into a working program.