Page 1 of 2
cc1: error: unrecognized command-line option ‘-quiet’
Posted: Mon Jan 02, 2023 2:08 pm
by JoeBox9
Hello, I am following the bare bones tutorial. I installed i686 GNU Cross Compilation Tool-Chains and it said that cc1 does not exist. After a bit of searching, I found that, I should make a link to cc, so I did and running
Code: Select all
i686-elf-gcc -c kernel.c -o kernel.o -std=gnu99 -ffreestanding -O2 -Wall -Wextra
gives this error:
Code: Select all
cc1: error: unrecognized command-line option ‘-quiet’
cc1: error: unrecognized command-line option ‘-quiet’
A simple search leads me no where.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Tue Jan 03, 2023 9:58 pm
by Octocontrabass
JoeBox9 wrote:it said that cc1 does not exist. After a bit of searching, I found that, I should make a link to cc
That's not the correct fix for the problem.
How exactly did you install your cross-compiler?
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Tue Jan 03, 2023 11:39 pm
by JoeBox9
Octocontrabass wrote:JoeBox9 wrote:it said that cc1 does not exist. After a bit of searching, I found that, I should make a link to cc
That's not the correct fix for the problem.
How exactly did you install your cross-compiler?
Through this Github Repo (
https://github.com/alessandromrc/i686-e ... s/releases). I copied everything to root. Then found out that /i686-elf has bin/ and lib/, so I opened Midnight Commander with root and moved them, still the same problem.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 12:03 am
by Octocontrabass
I extracted it to its own directory, ran it from there, and had no problems. Did you check to make sure libexec/gcc/i686-elf/11.1.0/cc1 did exist and was marked executable?
Copying it to the root directory sounds like a good way to break your system.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 12:23 am
by JoeBox9
Octocontrabass wrote:I extracted it to its own directory, ran it from there, and had no problems. Did you check to make sure libexec/gcc/i686-elf/11.1.0/cc1 did exist and was marked executable?
Copying it to the root directory sounds like a good way to break your system.
Yes it does and Nautilus says it is executable.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 5:27 am
by JoeBox9
Do I have to set path? How do I do that?
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 11:50 am
by Octocontrabass
I'm not sure if you need to set the path, but you can temporarily set the path like this:
Code: Select all
export PATH=/your/compiler/bin:$PATH
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 12:17 pm
by JoeBox9
Octocontrabass wrote:I'm not sure if you need to set the path, but you can temporarily set the path like this:
Code: Select all
export PATH=/your/compiler/bin:$PATH
Before you replied, I tried copying everything to the /bin folder, as it would have the same effect as $PATH, I then get this:
Code: Select all
i686-elf-gcc: fatal error: '-fuse-linker-plugin', but liblto_plugin.so not found
After you replied I tried setting the path to /libexec/gcc/i686-elf//11.1.0/, same error, I tried reverting the changes I made in /bin myself, by checking names of file in /libexec and comparing and deleting. I still get the same message, Did it magically fix itself. What do I do now? Also, I tried going further in the tutorial by ignoring compilation and just coding. I get the same error in the Meaty Skeleton Project.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 12:34 pm
by Octocontrabass
JoeBox9 wrote:After you replied I tried setting the path to /libexec/gcc/i686-elf//11.1.0/,
That's not going to work; you should only add the "bin" directory to PATH.
JoeBox9 wrote:What do I do now?
What do you see when you run "which i686-elf-gcc"?
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 12:58 pm
by JoeBox9
Octocontrabass wrote:JoeBox9 wrote:After you replied I tried setting the path to /libexec/gcc/i686-elf//11.1.0/,
That's not going to work; you should only add the "bin" directory to PATH.
JoeBox9 wrote:What do I do now?
What do you see when you run "which i686-elf-gcc"?
I see this:
Code: Select all
i686-elf-gcc: fatal error: no input files
compilation terminated.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 1:12 pm
by Octocontrabass
You didn't run the command I asked you to run.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 1:19 pm
by JoeBox9
Octocontrabass wrote:You didn't run the command I asked you to run.
Here is the correct one:
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 1:27 pm
by Octocontrabass
Did you extract the zip file into /usr? If not, the reason why you're having problems is because you have another i686-elf-gcc already installed.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 1:39 pm
by JoeBox9
Octocontrabass wrote:Did you extract the zip file into /usr? If not, the reason why you're having problems is because you have another i686-elf-gcc already installed.
Yeah, I was installing from the AUR but it was taking too long to compile, so I cancelled it in the middle and got the GitHub one. So, after pressing TAB in yay -r i686, it gave i686-elf-binutils, it said there was 16mb of stuff, it removed it, still the same compilation errors.
Re: cc1: error: unrecognized command-line option ‘-quiet’
Posted: Wed Jan 04, 2023 1:50 pm
by Octocontrabass
JoeBox9 wrote:Yeah, I was installing from the AUR but it was taking too long to compile, so I cancelled it in the middle
If you had let it finish, you wouldn't be having these problems.
Run "ls /usr/bin/i686-elf-*" and see if anything is listed.