Giter VIP home page Giter VIP logo

Comments (14)

chengenbao avatar chengenbao commented on May 18, 2024

from euler.

2shou avatar 2shou commented on May 18, 2024

gcc版本有特定要求吗,我换了7.3.1也有报错

from euler.

chengenbao avatar chengenbao commented on May 18, 2024

from euler.

2shou avatar 2shou commented on May 18, 2024

是的,都是用7.3.1编译的。现在的报错:

/usr/bin/cmake3 -E cmake_link_script CMakeFiles/cmTC_2de9f.dir/link.txt --verbose=1
/opt/rh/devtoolset-7/root/usr/bin/c++   -DCHECK_FUNCTION_EXISTS=pthread_create    CMakeFiles/cmTC_2de9f.dir/CheckFunctionExists.cxx.o  -o cmTC_2de9f -lpthreads
/opt/rh/devtoolset-7/root/usr/libexec/gcc/x86_64-redhat-linux/7/ld: 找不到 -lpthreads
collect2: error: ld returned 1 exit status
gmake[1]: *** [cmTC_2de9f] 错误 1
gmake[1]: 离开目录“/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp”
gmake: *** [cmTC_2de9f/fast] 错误 2

CMakeOutput.log的开头:

The system is: Linux - 3.10.0-693.21.1.el7.x86_64 - x86_64
Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" succeeded.
Compiler: /opt/rh/devtoolset-7/root/usr/bin/c++
Build flags:

from euler.

chengenbao avatar chengenbao commented on May 18, 2024

from euler.

2shou avatar 2shou commented on May 18, 2024

阿里云的云主机。

from euler.

2shou avatar 2shou commented on May 18, 2024

还有其他的报错:

[2shou@iZwz95etseedme89x9zuunZ build]$ grep -i "error" /home/2shou/tmp/euler/build/CMakeFiles/CMakeError.log
collect2: error: ld returned 1 exit status
collect2: error: ld returned 1 exit status
/home/2shou/tmp/euler/build/CMakeFiles/CheckTypeSize/HAVE___UINT16.c:23:31: error: expected ‘)’ before ‘__int16’
/home/2shou/tmp/euler/build/CMakeFiles/CheckTypeSize/HAVE___UINT16.c:23:31: error: expected ‘)’ before ‘__int16’
/home/2shou/tmp/euler/build/CMakeFiles/CheckTypeSize/HAVE___UINT16.c:23:31: error: expected ‘)’ before ‘__int16’
/home/2shou/tmp/euler/build/CMakeFiles/CheckTypeSize/HAVE___UINT16.c:23:31: error: expected ‘)’ before ‘__int16’
/home/2shou/tmp/euler/build/CMakeFiles/CheckTypeSize/HAVE___UINT16.c:23:31: error: expected ‘)’ before ‘__int16’
collect2: error: ld returned 1 exit status
c++: error: unrecognized command line option '-Wunnamed-type-template-args'
gmake[1]: *** [CMakeFiles/cmTC_ac700.dir/src.cxx.o] Error 1
gmake: *** [cmTC_ac700/fast] Error 2
collect2: error: ld returned 1 exit status
collect2: error: ld returned 1 exit status
collect2: error: ld returned 1 exit status
/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp/src.c:3:16: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp/src.c:2:27: error: declaration for parameter ‘a’ but no such parameter
/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp/src.c:3:16: error: expected ‘{’ at end of input
/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp/src.cxx:3:1: error: ‘vector’ does not name a type
/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp/src.cxx:2:11: error: expected constructor, destructor, or type conversion before ‘(’ token

from euler.

chengenbao avatar chengenbao commented on May 18, 2024

from euler.

2shou avatar 2shou commented on May 18, 2024
[2shou@iZwz95etseedme89x9zuunZ build]$ cmake3 ..
-- The CXX compiler identification is GNU 7.3.1
-- Check for working CXX compiler: /opt/rh/devtoolset-7/root/usr/bin/c++
-- Check for working CXX compiler: /opt/rh/devtoolset-7/root/usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for C++ include pthread.h
-- Looking for C++ include pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- The C compiler identification is GNU 7.3.1
-- Check for working C compiler: /opt/rh/devtoolset-7/root/usr/bin/cc
-- Check for working C compiler: /opt/rh/devtoolset-7/root/usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done

from euler.

chengenbao avatar chengenbao commented on May 18, 2024

from euler.

2shou avatar 2shou commented on May 18, 2024

报错是一样的,因为刚才就是清掉再cmake,日志我再截完整点:

Run Build Command:"/usr/bin/gmake" "cmTC_7a1a4/fast"
/usr/bin/gmake -f CMakeFiles/cmTC_7a1a4.dir/build.make CMakeFiles/cmTC_7a1a4.dir/build
gmake[1]: 进入目录“/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp”
Building CXX object CMakeFiles/cmTC_7a1a4.dir/CheckFunctionExists.cxx.o
/opt/rh/devtoolset-7/root/usr/bin/c++    -DCHECK_FUNCTION_EXISTS=pthread_create -fPIE   -o CMakeFiles/cmTC_7a1a4.dir/CheckFunctionExists.cxx.o -c /home/2shou/tmp/euler/build/CMakeFiles/CheckLibraryExists/CheckFunctionExists.cxx
Linking CXX executable cmTC_7a1a4
/usr/bin/cmake3 -E cmake_link_script CMakeFiles/cmTC_7a1a4.dir/link.txt --verbose=1
/opt/rh/devtoolset-7/root/usr/bin/c++   -DCHECK_FUNCTION_EXISTS=pthread_create    CMakeFiles/cmTC_7a1a4.dir/CheckFunctionExists.cxx.o  -o cmTC_7a1a4 -lpthreads
/opt/rh/devtoolset-7/root/usr/libexec/gcc/x86_64-redhat-linux/7/ld: 找不到 -lpthreads
collect2: error: ld returned 1 exit status
gmake[1]: *** [cmTC_7a1a4] 错误 1
gmake[1]: 离开目录“/home/2shou/tmp/euler/build/CMakeFiles/CMakeTmp”
gmake: *** [cmTC_7a1a4/fast] 错误 2

from euler.

chengenbao avatar chengenbao commented on May 18, 2024

from euler.

2shou avatar 2shou commented on May 18, 2024

好的,现在的cmake就是从build_wheel.sh的脚本中安装的:

curl http://mirrors.aliyun.com/repo/Centos-7.repo -o /etc/yum.repos.d/CentOS-Base.repo
curl http://mirrors.aliyun.com/repo/epel-7.repo -o /etc/yum.repos.d/epel.repo
echo "[global]
index-url = https://mirrors.aliyun.com/pypi/simple/" > /etc/pip.conf

yum install -y autoconf ant cmake3 gcc-c++ golang java-1.8.0-openjdk-headless perf python2-pip make

from euler.

2shou avatar 2shou commented on May 18, 2024

能否告知你们当时测试环境的cmake版本?我现在用的是3.13.1

[2shou@iZwz95etseedme89x9zuunZ euler]$ cmake3 --version
cmake3 version 3.13.1

CMake suite maintained and supported by Kitware (kitware.com/cmake).

from euler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.