Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Compiling with CUDA on Ubuntu 16.04 + Solution #4046
Comments
added a commit
to kleinric/caffe
that referenced
this issue
Apr 26, 2016
|
This helped me and several other users on 16.04 as well: EDIT The CUDA 8.0 RC works great. Just use that. |
lukeyeager
referenced this issue
Apr 26, 2016
Closed
Fixes https://github.com/BVLC/caffe/issues/4046 #4047
neouyghur
commented
Apr 27, 2016
•
|
I have same problem, but the solution is not working for me. |
neouyghur
commented
Apr 27, 2016
|
At first this solution does not work, however after I have download the newest Caffe, then compile with this modification it works. But I still got some error at undefined reference to `lzma_index_end@XZ_5.0'. |
macfer
commented
Apr 29, 2016
•
|
It worked for me on 16.04 but I added the flag to Makefile rather then to CMakeLists.txt as I had some other workarounds applied to Makefile.config and wasn't interested in switching to cmake build. If you are compiling with make then edit Makefile and replace the line |
swearos
commented
Apr 29, 2016
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D_FORCE_INLINES"), |
This was referenced May 1, 2016
bipedalBit
commented
May 12, 2016
|
@macfer thanks a lot. It seems Makefile configuring methods really counts. |
prafiles
referenced this issue
in tensorflow/tensorflow
May 14, 2016
Closed
Building from source in Ubuntu 16.04 LTS amd64 #2306
shelhamer
added
build
compatibility
labels
May 25, 2016
This was referenced May 26, 2016
Gwyki
commented
May 27, 2016
•
|
Ubuntu 16.04, GCC 5.3.1 Ok, so I have applied all the workarounds I can find:
The protobuf builds coming from the 16.04 repo would just not link. In the end I had to grab the source and compile manually: cd /usr/lib/X86_64-linux-gnu I was somewhat desperate to get it running ASAP and would prefer to not have to butcher the original protobuf libs but it didn't seem like uninstalling them cleanly was possible. Anyone have comments on why this was necessary? edit: Don't be silly like me. Don't move the original protobuf libs they are of course needed. For whatever reason after moving them back and removing the ones I compiled from source, everything still compiles, with ldd libcaffe.so showing it is linked with the original system protobuf libs... Puzzling. |
eokeeffe
referenced this issue
in opencv/opencv
May 30, 2016
Closed
Error compiling OpenCV Ubuntu 16.04 with CUDA #6606
hikarido
commented
Jun 3, 2016
|
Similar answer described here https://github.com/BVLC/caffe/wiki/Ubuntu-16.04-or-15.10-Installation-Guide |
Kaixhin
referenced this issue
in NVIDIA/nvidia-docker
Jun 14, 2016
Closed
CUDA 8.0 (RC) for Ubuntu 14.04 #110
|
Actually, tweaking
and it works perfectly. |
luitjens
referenced this issue
in NVlabs/xmp
Jun 28, 2016
Closed
error: ‘memcpy’ was not declared in this scope #4
dozyc
commented
Jul 6, 2016
•
|
the CMAKE_CXX_FLAGS fix didn't seem to have an effect, so I ended up adding some lines to cmake/Cuda.cmake around line 260:
|
This was referenced Jul 26, 2016
shelhamer
added
documentation
and removed
compatibility
labels
Sep 9, 2016
shelhamer
referenced this issue
Sep 9, 2016
Closed
Caffe 1.0.0-rc3 make failed on Ubuntu 16.04 / CUDA 8.0 #4492
|
This Ubuntu 16.04 issue is resolved by CUDA 8. |
kleinric commentedApr 26, 2016
•
Edited 1 time
-
kleinric
Apr 26, 2016
Compiling on a clean install of Ubuntu 16.04 with cmake and using CUDA from the repo.
I get the following error:
/usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ /usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ /usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ /usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ /usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ /usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ /usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ CMake Error at cuda_compile_generated_sgd_solver.cu.o.cmake:266 (message): Error generating file /opt/caffe/build/src/caffe/CMakeFiles/cuda_compile.dir/solvers/./cuda_compile_generated_sgd_solver.cu.oSeems TensorFlow has similar issues: fayeshine/tensorflow@6c8c572
By adding that flag to my CMakeLists.txt it fixed the problem and compiles fine. ie. Add this near the front:
set(${CMAKE_CXX_FLAGS} "-D_FORCE_INLINES ${CMAKE_CXX_FLAGS}")
Someone might be able to add this to the cmake file.