Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Background : If you run mush, you\'ll find that it works for commands like /bin/

ID: 3882054 • Letter: B

Question

Background: If you run mush, you'll find that it works for commands like /bin/echo and /bin/vi but it fails when you try to compile a program. Here's a transcript of what happens:

>/bin/cc -o mush mush.c

collect2: fatal error: cannot find 'ld'

compilation terminated.

The problem is, /bin/cc relies on a search path that's part of the default environment.

A problem: Fix it. Only two lines of code are involved, so give your fix in the form of notes that explain what lines of code to add, delete or change.

Explanation / Answer

Problem is not with your code or you dont have to change anything in your code.
'Id' links to the compilers. Try to change your working directory to directory where you code file is saved.
Check if there is any problem with GCC installation or You might need to reinstall the GCC