DasGregor | Gentoo Tidbits - "C Compiler Cannot Create Executables" @dasgregor | Uploaded 8 years ago | Updated February 02 2023
Gentoo Tidbits - "C Compiler Cannot Create Executables"
If you try to run emerge after a GCC update and get the above error, this may help you. In my case, creating a simple C program to print Hello World to the screen, and attempting to compile it, pointed me in the proper direction that the GCC profile was bad.
Use "gcc-config -l" to view your profiles, and "gcc-config (number)" to set your profile. Then it is advisable to run ". /etc/profile". Try to recompile a simple C program to verify the fix.
GOOD LUCK!
Gentoo Tidbits - "C Compiler Cannot Create Executables"
If you try to run emerge after a GCC update and get the above error, this may help you. In my case, creating a simple C program to print Hello World to the screen, and attempting to compile it, pointed me in the proper direction that the GCC profile was bad.
Use "gcc-config -l" to view your profiles, and "gcc-config (number)" to set your profile. Then it is advisable to run ". /etc/profile". Try to recompile a simple C program to verify the fix.
GOOD LUCK!