Monday, March 3, 2025

Sixth Posting: LAB 4 Building GCC (Part 2)

 Hello There this is the Part two of the Building GCC!

Yes, the build process was quite long.. so i decided to come back later, whoever is running this, please make sure that you have the screen saver off so that our terminal can have no disturbances. 


In the end of the build process we see a time here. I see that it took about 48 mins total.



Now we are going to go ahead and install the build with "make install" command
When the make install command is done we might be able to see some lines that it is all good to go.


So now lets confirm few things again if everything is good to go.

with "which gcc" command as well as "gcc --version" command we are able to see where and what kind of gcc is already there
as well as with command "$HOME/gcc-test-001/bin/gcc --version"
we can know what kind of GCC version we just installed.


Seems like we have a two different version here
-    14.2.1-3 in system
-    15.0.1 what we just installed

Now we are writing simple c program in order to see if the gcc is working correctly!

So we can see the test.c contains a line that saying

"Hello i am testing newly installed GCC!" by the way it should be stdio not stdin so i edited that part behind :)
Lets compile this file with below command and get one excutable from GCC

$HOME/gcc-test-001/bin/gcc test.c -o test


This is great! we are seeing that the file is running good.
Now we try rebuilding it again:


13 seconds total. compare to the 48 mins that we took for the first time this is huge reduce since we already have built it once before.

No comments:

Post a Comment

10th Posting - Project: Stage 3

 Hello All! now we are on the final stage of the project which is project 3. If you remember correctly from my Stage 2 posting, i was able t...