question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

error: command 'gcc' failed with exit status 1

See original GitHub issue

I am not so family with the compiling staff and got an error below when I run the “sh make.sh”. Pls help. Thanks a lot.

(py27) Xiaoke@apollo:~/repos/faster-rcnn/faster-rcnn.pytorch/lib$ sh make.sh
running build_ext
skipping 'model/utils/bbox.c' Cython extension (up-to-date)
building 'model.utils.cython_bbox' extension
creating build
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/model
creating build/temp.linux-x86_64-2.7/model/utils
{'gcc': ['-Wno-cpp', '-Wno-unused-function']}
gcc -pthread -B /data/apollo/a/Xiaoke/miniconda2/envs/py27/compiler_compat -Wl,--sysroot=/ -fno-st
rict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/data/apollo/a/Xiaoke
54/miniconda2/envs/py27/lib/python2.7/site-packages/numpy/core/include -I/data/apollo/a/Xiaoke/miniconda2/envs/py27/include/python2.7 -c model/utils/bbox.c -o build/temp.linux-x86_64-2.7/model/utils/bbox.o -Wno-cpp -Wno-unused-function
gcc -pthread -shared -B /data/apollo/a/Xiaoke/miniconda2/envs/py27/compiler_compat -L/data/apollo/a/Xiaoke/miniconda2/envs/py27/lib -Wl,-rpath=/data/apollo/a/Xiaoke4/miniconda2/envs/py27/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-2.7/model/utils/bbox.o -L/data/apollo/a/Xiaoke/miniconda2/envs/py27/lib -lpython2.7 -o /data/apollo/a/Xiaoke/repos/faster-rcnn/faster-rcnn.pytorch/lib/model/utils/cython_bbox.so
/data/apollo/a/Xiaoke/miniconda2/envs/py27/compiler_compat/ld: cannot find -lpthread
/data/apollo/a/Xiaoke/miniconda2/envs/py27/compiler_compat/ld: cannot find -lc
collect2: error: ld returned 1 exit status
error: command 'gcc' failed with exit status 1
Compiling nms kernels by nvcc...

I am using the conda env: linux 14.04 CUDA 8.0 Python 2.7.14 |Anaconda, Inc.| (default, Mar 12 2018, 12:37:12) [GCC 7.2.0] on linux2

Thanks.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
Bigwodecommented, Mar 28, 2018

But I run this make.sh in anaconda, but I have a same question, I have no idea to deal with this problem

2reactions
jwyangcommented, Mar 24, 2018

@liketheflower hi, you should install anaconda instead of miniconda.

Read more comments on GitHub >

github_iconTop Results From Across the Web

command 'gcc' failed with exit status 1 while installing eventlet ...
Your install is failing because you don't have the python development headers installed. You can do this through apt on ubuntu/debian with:
Read more >
Error Command “gcc” Failed With Exit Status 1 - Linux Hint
The “Error command “gcc” failed with exit status 1” error is caused when attempting to compile Python packages and the required packages.
Read more >
What Should I Do If Error "command ´gcc´ failed with exit ...
Run the following command to install openssl-devel: yum install gcc libffi-devel python-devel openssl-devel -y · Use PIP to install the Python ...
Read more >
error: command 'gcc' failed with exit status 1 - gists · GitHub
ERROR : Command errored out with exit status 1: command: /usr/local/python3/bin/python3.5 -u -c 'import sys, setuptools, tokenize; sys.argv[0] ...
Read more >
The “error command gcc failed with exit status 1 ... - LinuxTect
The most prolific reason for the “error command gcc failed with exit status 1” is the absence of the Python development library or...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found