facebookarchive / caffe2

Caffe2 is a lightweight, modular, and scalable deep learning framework.
https://caffe2.ai
Apache License 2.0
8.42k stars 1.95k forks source link

Build Issue on Ubuntu 16.04 #1861

Closed samiksome92 closed 6 years ago

samiksome92 commented 6 years ago

Make output

-- Does not need to define long separately.
-- Current compiler supports avx2 extention. Will build perfkernels.
-- The BLAS backend of choice:Eigen
-- Could NOT find NNPACK (missing:  CPUINFO_LIBRARY)
-- Brace yourself, we are building NNPACK
-- Found PythonInterp: /usr/bin/python (found version "2.7.12")
CMake Error at third_party/pthreadpool/CMakeLists.txt:105 (ADD_SUBDIRECTORY):
  add_subdirectory given source "/home/cseiitk/caffe2/third_party/fxdiv"
  which is not an existing directory.

CMake Error at third_party/NNPACK/CMakeLists.txt:456 (ADD_SUBDIRECTORY):
  add_subdirectory given source "/home/cseiitk/caffe2/third_party/fxdiv"
  which is not an existing directory.

CMake Error at third_party/NNPACK/CMakeLists.txt:474 (ADD_SUBDIRECTORY):
  add_subdirectory given source "/home/cseiitk/caffe2/third_party/fp16" which
  is not an existing directory.

CMake Warning at cmake/public/gflags.cmake:2 (find_package):
  By not providing "Findgflags.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "gflags", but
  CMake did not find one.

  Could not find a package configuration file provided by "gflags" with any
  of the following names:

    gflagsConfig.cmake
    gflags-config.cmake

  Add the installation prefix of "gflags" to CMAKE_PREFIX_PATH or set
  "gflags_DIR" to a directory containing one of the above files.  If "gflags"
  provides a separate development package or SDK, be sure it has been
  installed.
Call Stack (most recent call first):
  cmake/Dependencies.cmake:87 (include)
  CMakeLists.txt:88 (include)

-- Cannot find gflags with config files. Using legacy find.
-- Found gflags  (include: /usr/include, library: /usr/lib/x86_64-linux-gnu/libgflags.so)
CMake Warning at cmake/public/glog.cmake:2 (find_package):
  By not providing "Findglog.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "glog", but
  CMake did not find one.

  Could not find a package configuration file provided by "glog" with any of
  the following names:

    glogConfig.cmake
    glog-config.cmake

  Add the installation prefix of "glog" to CMAKE_PREFIX_PATH or set
  "glog_DIR" to a directory containing one of the above files.  If "glog"
  provides a separate development package or SDK, be sure it has been
  installed.
Call Stack (most recent call first):
  cmake/Dependencies.cmake:102 (include)
  CMakeLists.txt:88 (include)

-- Cannot find glog. Using legacy find.
-- git Version: v0.0.0
-- Version: 0.0.0
-- Performing Test HAVE_STD_REGEX
-- Performing Test HAVE_STD_REGEX
-- Performing Test HAVE_STD_REGEX -- success
-- Performing Test HAVE_GNU_POSIX_REGEX
-- Performing Test HAVE_GNU_POSIX_REGEX
-- Performing Test HAVE_GNU_POSIX_REGEX -- failed to compile
-- Performing Test HAVE_POSIX_REGEX
-- Performing Test HAVE_POSIX_REGEX
-- Performing Test HAVE_POSIX_REGEX -- success
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK -- success
-- Found lmdb    (include: /usr/include, library: /usr/lib/x86_64-linux-gnu/liblmdb.so)
-- Found LevelDB (include: /usr/include, library: /usr/lib/x86_64-linux-gnu/libleveldb.so)
-- Found Snappy  (include: /usr/include, library: /usr/lib/x86_64-linux-gnu/libsnappy.so)
-- Could NOT find RocksDB (missing:  RocksDB_INCLUDE_DIR RocksDB_LIBRARIES)
CMake Warning at cmake/Dependencies.cmake:180 (message):
  Not compiling with RocksDB.  Suppress this warning with -DUSE_ROCKSDB=OFF
Call Stack (most recent call first):
  CMakeLists.txt:88 (include)

-- OpenCV found (/usr/share/OpenCV)
CMake Warning at cmake/Dependencies.cmake:244 (find_package):
  By not providing "FindEigen3.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "Eigen3", but
  CMake did not find one.

  Could not find a package configuration file provided by "Eigen3" with any
  of the following names:

    Eigen3Config.cmake
    eigen3-config.cmake

  Add the installation prefix of "Eigen3" to CMAKE_PREFIX_PATH or set
  "Eigen3_DIR" to a directory containing one of the above files.  If "Eigen3"
  provides a separate development package or SDK, be sure it has been
  installed.
Call Stack (most recent call first):
  CMakeLists.txt:88 (include)

-- Did not find system Eigen. Using third party subdirectory.
-- Found PythonInterp: /usr/bin/python (found suitable version "2.7.12", minimum required is "2.7")
-- NumPy ver. 1.14.0 found (include: /usr/local/lib/python2.7/dist-packages/numpy/core/include)
-- Could NOT find pybind11 (missing:  pybind11_INCLUDE_DIR)
-- MPI support found
-- MPI compile flags:
-- MPI include path: /usr/lib/openmpi/include/openmpi/opal/mca/event/libevent2021/libevent/usr/lib/openmpi/include/openmpi/opal/mca/event/libevent2021/libevent/include/usr/lib/openmpi/include/usr/lib/openmpi/include/openmpi
-- MPI LINK flags path:  -Wl,-rpath  -Wl,/usr/lib/openmpi/lib  -Wl,--enable-new-dtags
-- MPI libraries: /usr/lib/openmpi/lib/libmpi_cxx.so/usr/lib/openmpi/lib/libmpi.so
CMake Warning at cmake/Dependencies.cmake:298 (message):
  OpenMPI found, but it is not built with CUDA support.
Call Stack (most recent call first):
  CMakeLists.txt:88 (include)

-- CUDA detected: 8.0
-- Automatic GPU detection returned 6.1 6.1 6.1 6.1.
-- Added CUDA NVCC flags for: sm_61
-- Found libcuda: /usr/local/cuda-8.0/lib64/stubs/libcuda.so
-- Found libnvrtc: /usr/local/cuda-8.0/lib64/libnvrtc.so
-- Found cuDNN: v5.1.10  (include: /usr/local/cuda-8.0/include, library: /usr/local/cuda-8.0/lib64/libcudnn.so)
-- Could NOT find NCCL (missing:  NCCL_INCLUDE_DIRS NCCL_LIBRARIES)
-- NCCL: /home/cseiitk/caffe2/third_party/nccl/build/lib/libnccl_static.a
-- Could NOT find CUB (missing:  CUB_INCLUDE_DIR)
-- Could NOT find Gloo (missing:  Gloo_INCLUDE_DIR Gloo_LIBRARY)
-- MPI include path: /usr/lib/openmpi/include/openmpi/opal/mca/event/libevent2021/libevent/usr/lib/openmpi/include/openmpi/opal/mca/event/libevent2021/libevent/include/usr/lib/openmpi/include/usr/lib/openmpi/include/openmpi
-- MPI libraries: /usr/lib/openmpi/lib/libmpi_cxx.so/usr/lib/openmpi/lib/libmpi.so
-- CUDA detected: 8.0
-- Found libcuda: /usr/local/cuda-8.0/lib64/stubs/libcuda.so
-- Found libnvrtc: /usr/local/cuda-8.0/lib64/libnvrtc.so
CMake Warning at cmake/Dependencies.cmake:476 (message):
  Metal is only used in ios builds.
Call Stack (most recent call first):
  CMakeLists.txt:88 (include)

-- GCC 5.4.0: Adding gcc and gcc_s libs to link line
-- Include NCCL operators
-- Including image processing operators
-- Excluding video processing operators due to no opencv
-- Excluding mkl operators as we are not using mkl
-- Include Observer library
-- Automatically generating missing __init__.py files.
--
-- ******** Summary ********
-- General:
--   CMake version         : 3.5.1
--   CMake command         : /usr/bin/cmake
--   Git version           : v0.8.1-1031-gcce2a8d
--   System                : Linux
--   C++ compiler          : /usr/bin/c++
--   C++ compiler version  : 5.4.0
--   Protobuf compiler     : /usr/bin/protoc
--   Protobuf include path : /usr/include
--   Protobuf libraries    : optimized;/usr/lib/x86_64-linux-gnu/libprotobuf.so;debug;/usr/lib/x86_64-linux-gnu/libprotobuf.so;-pthread
--   CXX flags             :  -std=c++11 -O2 -fPIC -Wno-narrowing -Wno-invalid-partial-specialization
--   Build type            : Release
--   Compile definitions   :
--
--   BUILD_BINARY          : ON
--   BUILD_DOCS            : OFF
--   BUILD_PYTHON          : ON
--     Python version      : 2.7.12
--     Python library      : /usr/lib/x86_64-linux-gnu/libpython2.7.so
--   BUILD_SHARED_LIBS     : ON
--   BUILD_TEST            : ON
--   USE_ATEN              : OFF
--   USE_ASAN              : OFF
--   USE_CUDA              : ON
--     CUDA version        : 8.0
--     CuDNN version       : 5.1.10
--   USE_EIGEN_FOR_BLAS    : 1
--   USE_FFMPEG            : OFF
--   USE_GFLAGS            : ON
--   USE_GLOG              : ON
--   USE_GLOO              : ON
--   USE_LEVELDB           : ON
--     LevelDB version     : 1.18
--     Snappy version      : 1.1.3
--   USE_LITE_PROTO        : OFF
--   USE_LMDB              : ON
--     LMDB version        : 0.9.17
--   USE_METAL             : OFF
--   USE_MKL               :
--   USE_MOBILE_OPENGL     : OFF
--   USE_MPI               : ON
--   USE_NCCL              : ON
--   USE_NERVANA_GPU       : OFF
--   USE_NNPACK            : ON
--   USE_OBSERVERS         : ON
--   USE_OPENCV            : ON
--     OpenCV version      : 2.4.9.1
--   USE_OPENMP            : OFF
--   USE_PROF              : OFF
--   USE_REDIS             : OFF
--   USE_ROCKSDB           : OFF
--   USE_THREADS           : ON
--   USE_ZMQ               : OFF
-- Configuring incomplete, errors occurred!
See also "/home/cseiitk/caffe2/build/CMakeFiles/CMakeOutput.log".
See also "/home/cseiitk/caffe2/build/CMakeFiles/CMakeError.log".
Makefile:4: recipe for target 'all' failed
make: *** [all] Error 1
RoyHe commented 6 years ago

I meet the same error... rename the FXdiv folder to fxdiv and Fp16 to fp16...

panovr commented 6 years ago

I renamed these two directories, but got another compile error:

$ make
[  1%] Built target nccl_external
[  1%] Built target pthreadpool
[  4%] Built target cpuinfo
[  4%] Generating src/x86_64-fma/2d-fourier-8x8.py.o
/usr/bin/python: No module named peachpy
confu-deps/CMakeFiles/nnpack.dir/build.make:61: recipe for target 'confu-deps/src/x86_64-fma/2d-fourier-8x8.py.o' failed
make[2]: *** [confu-deps/src/x86_64-fma/2d-fourier-8x8.py.o] Error 1
CMakeFiles/Makefile2:168: recipe for target 'confu-deps/CMakeFiles/nnpack.dir/all' failed
make[1]: *** [confu-deps/CMakeFiles/nnpack.dir/all] Error 2
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2
RoyHe commented 6 years ago

@panovr yo can try install Peachpy https://github.com/Maratyszcza/PeachPy

panovr commented 6 years ago

@RoyHe I confirm installing Peachpy can fix No module peachpy error. Thanks!

Maratyszcza commented 6 years ago

There is currently a build breakage affecting nearly all platforms. A fix is coming in https://github.com/caffe2/caffe2/pull/1858

pjh5 commented 6 years ago

Closing this since that PR has merged.