install error linux centos7

lanzhiqishi
Posts: 9
Joined: Fri May 22, 2020 7:00 pm
company / institution: university of maine
Location: maine

install error linux centos7

Post by lanzhiqishi »

Dear anyone who knows the answer



bash        install-anaconda-deps.sh
Make auxdata all

these code all work.

but when i make

the error code:
collect2: error:ld returned 1 exit status
error:command'gcc' failed with exit status 1
make *** [makefile:9 :main] Error 1

Thank you

Best wishes

Binbin
User avatar
fsteinmetz
Site Admin
Posts: 89
Joined: Fri Sep 07, 2018 1:34 pm
company / institution: Hygeos
Location: Lille, France
Contact:

Re: install error linux centos7

Post by fsteinmetz »

Hello,
Could you clarify which is the command that fails ?
lanzhiqishi
Posts: 9
Joined: Fri May 22, 2020 7:00 pm
company / institution: university of maine
Location: maine

Re: install error linux centos7

Post by lanzhiqishi »

when i do 'make ' code
User avatar
fsteinmetz
Site Admin
Posts: 89
Joined: Fri Sep 07, 2018 1:34 pm
company / institution: Hygeos
Location: Lille, France
Contact:

Re: install error linux centos7

Post by fsteinmetz »

Please try 'make rebuild', and if still fails, send me the complete error message.
lanzhiqishi
Posts: 9
Joined: Fri May 22, 2020 7:00 pm
company / institution: university of maine
Location: maine

Re: install error linux centos7

Post by lanzhiqishi »

(binbin) [bjiang@viz3]~/software/pythondepen/polymer-v4.13% make rebuild
rm -rfv build
removed directory: ‘build/lib.linux-x86_64-3.7/polymer’
removed directory: ‘build/lib.linux-x86_64-3.7’
removed ‘build/temp.linux-x86_64-3.7/build/polymer/clut.o’
removed directory: ‘build/temp.linux-x86_64-3.7/build/polymer’
removed directory: ‘build/temp.linux-x86_64-3.7/build’
removed directory: ‘build/temp.linux-x86_64-3.7’
removed ‘build/polymer/neldermead.html’
removed ‘build/polymer/clut.html’
removed ‘build/polymer/polymer_main.c’
removed ‘build/polymer/fresnel.c’
removed ‘build/polymer/water.html’
removed ‘build/polymer/clut.c’
removed ‘build/polymer/neldermead.c’
removed ‘build/polymer/water.c’
removed ‘build/polymer/polymer_main.html’
removed directory: ‘build/polymer’
removed directory: ‘build’
rm -fv polymer/*.so
auxdata/common/no2_climatology.hdf: OK
auxdata/common/trop_f_no2_200m.hdf: OK
auxdata/common/morel_fq.dat: OK
auxdata/common/AboveRrs_gCoef_w0.dat: OK
auxdata/common/AboveRrs_gCoef_w10.dat: OK
auxdata/common/AboveRrs_gCoef_w5.dat: OK
auxdata/common/aph_bricaud_1995.txt: OK
auxdata/common/aph_bricaud_1998.txt: OK
auxdata/common/morel_buiteveld_bsw.txt: OK
auxdata/common/palmer74.dat: OK
auxdata/common/pope97.dat: OK
auxdata/common/raman_westberry13.txt: OK
auxdata/common/astarmin_average_2015_SLSTR.txt: OK
auxdata/common/astarmin_average.txt: OK
auxdata/common/Matsuoka11_aphy_Table1_JGR.csv: OK
auxdata/common/SOLAR_SPECTRUM_WMO_86: OK
auxdata/common/k_oz.csv: OK
auxdata/generic/LUT.hdf: OK
auxdata/meris/smile/v2/sun_spectral_flux_rr.txt: OK
auxdata/meris/smile/v2/central_wavelen_rr.txt: OK
auxdata/meris/smile/v2/sun_spectral_flux_fr.txt: OK
auxdata/meris/smile/v2/central_wavelen_fr.txt: OK
auxdata/modisa/HMODISA_RSRs.txt: OK
auxdata/seawifs/SeaWiFS_RSRs.txt: OK
auxdata/viirs/VIIRSN_IDPSv3_RSRs.txt: OK
auxdata/msi/S2-SRF_COPE-GSEG-EOPG-TN-15-0007_3.0_S2A.csv: OK
auxdata/msi/S2-SRF_COPE-GSEG-EOPG-TN-15-0007_3.0_S2B.csv: OK
auxdata/oli/Ball_BA_RSR.v1.2.xlsx: OK
python setup.py build_ext --inplace
Compiling polymer/clut.pyx because it changed.
Compiling polymer/neldermead.pyx because it changed.
Compiling polymer/polymer_main.pyx because it changed.
Compiling polymer/water.pyx because it changed.
[1/4] Cythonizing polymer/clut.pyx
/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/Cython/Compiler/Main.py:369: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: /nfs3-home/bjiang/software/pythondepen/polymer-v4.13/polymer/clut.pxd
tree = Parsing.p_module(s, pxd, full_module_name)
[2/4] Cythonizing polymer/neldermead.pyx
/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/Cython/Compiler/Main.py:369: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: /nfs3-home/bjiang/software/pythondepen/polymer-v4.13/polymer/neldermead.pxd
tree = Parsing.p_module(s, pxd, full_module_name)
[3/4] Cythonizing polymer/polymer_main.pyx
/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/Cython/Compiler/Main.py:369: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: /nfs3-home/bjiang/software/pythondepen/polymer-v4.13/polymer/polymer_main.pyx
tree = Parsing.p_module(s, pxd, full_module_name)
[4/4] Cythonizing polymer/water.pyx
/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/Cython/Compiler/Main.py:369: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: /nfs3-home/bjiang/software/pythondepen/polymer-v4.13/polymer/water.pxd
tree = Parsing.p_module(s, pxd, full_module_name)
running build_ext
building 'polymer.clut' extension
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/build
creating build/temp.linux-x86_64-3.7/build/polymer
/opt/modules/centos7/gcc/7.3.0/bin/gcc -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include -I/home/bjiang/.conda/envs/binbin/include/python3.7m -c build/polymer/clut.c -o build/temp.linux-x86_64-3.7/build/polymer/clut.o
In file included from /home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1832:0,
from /home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:12,
from /home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/arrayobject.h:4,
from build/polymer/clut.c:619:
/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
#warning "Using deprecated NumPy API, disable it with " \
^~~~~~~
gcc -pthread -shared -B /home/bjiang/.conda/envs/binbin/compiler_compat -L/home/bjiang/.conda/envs/binbin/lib -Wl,-rpath=/home/bjiang/.conda/envs/binbin/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/build/polymer/clut.o -o /nfs3-home/bjiang/software/pythondepen/polymer-v4.13/polymer/clut.cpython-37m-x86_64-linux-gnu.so
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /lib/libpthread.so.0 when searching for /lib/libpthread.so.0
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /lib/libpthread.so.0 when searching for /lib/libpthread.so.0
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: cannot find /lib/libpthread.so.0
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /usr/lib/libpthread_nonshared.a when searching for /usr/lib/libpthread_nonshared.a
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /usr/lib/libpthread_nonshared.a when searching for /usr/lib/libpthread_nonshared.a
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: cannot find /usr/lib/libpthread_nonshared.a
collect2: error: ld returned 1 exit status
error: command 'gcc' failed with exit status 1
make: *** [makefile:9: main] Error 1
(binbin) [bjiang@viz3]~/software/pythondepen/polymer-v4.13% make
python setup.py build_ext --inplace
running build_ext
building 'polymer.clut' extension
/opt/modules/centos7/gcc/7.3.0/bin/gcc -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include -I/home/bjiang/.conda/envs/binbin/include/python3.7m -c build/polymer/clut.c -o build/temp.linux-x86_64-3.7/build/polymer/clut.o
In file included from /home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1832:0,
from /home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:12,
from /home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/arrayobject.h:4,
from build/polymer/clut.c:619:
/home/bjiang/.conda/envs/binbin/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
#warning "Using deprecated NumPy API, disable it with " \
^~~~~~~
gcc -pthread -shared -B /home/bjiang/.conda/envs/binbin/compiler_compat -L/home/bjiang/.conda/envs/binbin/lib -Wl,-rpath=/home/bjiang/.conda/envs/binbin/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/build/polymer/clut.o -o /nfs3-home/bjiang/software/pythondepen/polymer-v4.13/polymer/clut.cpython-37m-x86_64-linux-gnu.so
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /lib/libpthread.so.0 when searching for /lib/libpthread.so.0
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /lib/libpthread.so.0 when searching for /lib/libpthread.so.0
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: cannot find /lib/libpthread.so.0
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /usr/lib/libpthread_nonshared.a when searching for /usr/lib/libpthread_nonshared.a
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: skipping incompatible /usr/lib/libpthread_nonshared.a when searching for /usr/lib/libpthread_nonshared.a
/home/bjiang/.conda/envs/binbin/compiler_compat/ld: cannot find /usr/lib/libpthread_nonshared.a
collect2: error: ld returned 1 exit status
error: command 'gcc' failed with exit status 1
make: *** [makefile:9: main] Error 1
User avatar
LaurentWandrebeck
Site Admin
Posts: 14
Joined: Fri Sep 07, 2018 1:07 pm
company / institution: HYGEOS

Re: install error linux centos7

Post by LaurentWandrebeck »

Hello,

It’s likely that you have something wrong when it comes to glibc. I would say you have glibc installed, but i686 version only. And code is being compiled as x86_64. What is strange is that you should have glibc x86_64 installed by default (which provides /lib64/libpthread.so.0). Unless of course you’re running a 32bits OS, but that’s very unlikely nowadays.

Could you please give me:
  • The operating system and platform you’re compiling on. Most likely

    Code: Select all

    cat /etc/redhat-release
    or

    Code: Select all

    cat /etc/debian-version
    and

    Code: Select all

    uname -a
  • Version(s) of glibc package(s) installed. If you’re running RHEL or derivatives:

    Code: Select all

    yum list installed | grep glibc
    If you’re running Debian or derivatives:

    Code: Select all

    apt list --installed | grep libc
So we can try to help you further.

Thanks,
Laurent Wandrebeck
IT Manager
lanzhiqishi
Posts: 9
Joined: Fri May 22, 2020 7:00 pm
company / institution: university of maine
Location: maine

Re: install error linux centos7

Post by lanzhiqishi »

Dear Laurent Wandrebeck,

Thank you for your help. i follow your code, it still not work.

the code below:

[bjiang@viz3]~/.vnc% cat /etc/redhat-release
CentOS Linux release 7.7.1908 (Core)
[bjiang@viz3]~/.vnc% cat/etc/debian-version
zsh: no such file or directory: cat/etc/debian-version
[bjiang@viz3]~/.vnc% uname -a
Linux viz3.acg.maine.edu 3.10.0-862.9.1.el7.x86_64 #1 SMP Mon Jul 16 16:29:36 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
[bjiang@viz3]~/.vnc% yum list installed | grep glibc
compat-glibc.x86_64 1:2.12-4.el7.centos @anaconda
compat-glibc-headers.x86_64 1:2.12-4.el7.centos @anaconda
glibc.i686 2.17-292.el7 @base
glibc.x86_64 2.17-292.el7 @base
glibc-common.x86_64 2.17-292.el7 @base
glibc-devel.i686 2.17-292.el7 @base
glibc-devel.x86_64 2.17-292.el7 @base
glibc-headers.x86_64 2.17-292.el7 @base
[bjiang@viz3]~/.vnc%


after that run code "make" same problem as before. Thank you again

Best

Binbin
User avatar
LaurentWandrebeck
Site Admin
Posts: 14
Joined: Fri Sep 07, 2018 1:07 pm
company / institution: HYGEOS

Re: install error linux centos7

Post by LaurentWandrebeck »

Dear Binbin,

Things I asked were not meant to solve the problem yet ;) Anyway, it looks like you’re using a non default gcc: /opt/modules/centos7/gcc/7.3.0/bin/gcc (coming from devtoolset probably ?)
That may well be the cause. You probably lack of a glibc package corresponding to that particular version of gcc.
Can you please

Code: Select all

yum install -y gcc
And try to compile Polymer with the default compiler (which is /usr/bin/gcc) ?

Thanks !
Laurent Wandrebeck
IT Manager
lanzhiqishi
Posts: 9
Joined: Fri May 22, 2020 7:00 pm
company / institution: university of maine
Location: maine

Re: install error linux centos7

Post by lanzhiqishi »

Dear Laurent Wandrebeck

Thank you for your help.

when i follow your suggestion, it fails.the code follows:

[bjiang@viz3]~% yum install gcc
Loaded plugins: fastestmirror, langpacks, nvidia
You need to be root to perform this command.
[bjiang@viz3]~% which /usr/bin/gcc
/usr/bin/gcc

Thank you again

Best

Binbin
User avatar
LaurentWandrebeck
Site Admin
Posts: 14
Joined: Fri Sep 07, 2018 1:07 pm
company / institution: HYGEOS

Re: install error linux centos7

Post by LaurentWandrebeck »

Could you please give me the output of

Code: Select all

ll /usr/bin/gcc
If it is a symlink pointing to /opt/modules/centos7/gcc/7.3.0/bin/gcc and you don’t have root access, please ask your system administrator to change default gcc so that system uses by default the system one (not one provided by devtoolset repository or any other).

Thanks
Laurent Wandrebeck
IT Manager
Post Reply