Question
I need help with this question please. Computer systems. Note: Solve it using linux terminal. PLEASE Leave this question to anyone who owns the Linux
I need help with this question please.
Computer systems.
Note: Solve it using linux terminal.
PLEASE Leave this question to anyone who owns the Linux platform.
I need the solution of this question as soon as possible.
***********
main.c :
#include "lab02.h"
int main(){ input(); factorial(); fib(); }
***********
factorial.c:
#include "lab02.h"
int factorial(){ int result = 1,i; for(i=1;i
output(result); return result; }
*******
lab02.h
#include //#ifdef LAB2 int N; //#endif void input(); int factorial(); int fib(); void output(int result);
************
I need all the files that will be produced from every step you make (i.e. source file, executable file.....), and I also need you to explain each commands you use.
Modify the "main.c" such that the function "factorial" is linked at run-time. Name the modified source file "main2.c a) Show in the report the modified source file. b) Link the source file "main2." with the shared library to produce the executable file "lab02d". Write in the report the command you have used. c) Run the executable file "lab02d". Write in the report the output of the run. d) Explain the differences between executing the files "lab02b", "lab02c" and "lab02d. e) Draw two figures that summarizes the translation and linking process for each of lab02b and lab02c executable files of the InLab f) At run time, each global variable is referenced indirectly through the GOT i. What "GOT"' stands for? What is its purpose? ii. Show the GOT entries of your code and add the commands and their outputs to your report. iii. Show the assembly code segment that corresponds referencing a global variable via GOT Explain in your own words each line of the assembly code, and trace it. iv
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started