title: How to fix broken gcc compiler in conda
body: <p>I am trying to compile some software that contains a compile.sh shell script. When I run the script, the software fails to compile due to what it reports as a broken C compiler.</p>
  
  <p>I have tried reinstalling C compilers, both within and outside of conda, to no avail.</p>
  
  <p>Below, please find the output of running the compile shell script</p>
  
  <pre><code>(base) userA@server:~/SPAdes-3.13.0-dev$ ./spades_compile.sh
  -- The C compiler identification is GNU 7.3.0
  -- The CXX compiler identification is GNU 7.3.0
  -- Check for working C compiler: /home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-cc
  -- Check for working C compiler: /home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-cc -- broken
  CMake Error at /home/userA/anaconda3/share/cmake-3.14/Modules/CMakeTestCCompiler.cmake:60 (message):
    The C compiler
  
      "/home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-cc"
  
    is not able to compile a simple test program.
  
    It fails with the following output:
  
      Change Dir: /home/userA/SPAdes-3.13.0-dev/build_spades/CMakeFiles/CMakeTmp
  
      Run Build Command(s):/usr/bin/make cmTC_708f4/fast
      /usr/bin/make -f CMakeFiles/cmTC_708f4.dir/build.make CMakeFiles/cmTC_708f4.dir/build
      make[1]: Entering directory '/home/userA/SPAdes-3.13.0-dev/build_spades/CMakeFiles/CMakeTmp'
      Building C object CMakeFiles/cmTC_708f4.dir/testCCompiler.c.o
      /home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-cc   -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe    -o CMakeFiles/cmTC_708f4.dir/testCCompiler.c.o   -c /home/userA/SPAdes-3.13.0-dev/build_spades/CMakeFiles/CMakeTmp/testCCompiler.c
      Linking C executable cmTC_708f4
      /home/userA/anaconda3/bin/cmake -E cmake_link_script CMakeFiles/cmTC_708f4.dir/link.txt --verbose=1
      /home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-cc -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe   -Wl,-O2 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,--disable-new-dtags -Wl,--gc-sections  -rdynamic CMakeFiles/cmTC_708f4.dir/testCCompiler.c.o  -o cmTC_708f4
      /home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-ld: cannot find crtbeginS.o: No such file or directory
      /home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-ld: cannot find -lgcc
      /home/userA/anaconda3/bin/x86_64-conda_cos6-linux-gnu-ld: cannot find -lgcc
      collect2: error: ld returned 1 exit status
      CMakeFiles/cmTC_708f4.dir/build.make:86: recipe for target 'cmTC_708f4' failed
      make[1]: *** [cmTC_708f4] Error 1
      make[1]: Leaving directory '/home/userA/SPAdes-3.13.0-dev/build_spades/CMakeFiles/CMakeTmp'
      Makefile:121: recipe for target 'cmTC_708f4/fast' failed
      make: *** [cmTC_708f4/fast] Error 2
  
  
  
  
    CMake will not be able to correctly generate this project.
  </code></pre>
  
  <p>Expected result: properly compiled software</p>
  
  <p>Actual result: report of a broken C compiler</p>