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.

Can you give me some advises on makefile?

See original GitHub issue

I encounter some difficulties during make makefile, as follow:

make: Circular tf_nndistance.cu <- tf_nndistance.cu.o dependency dropped.
g++ tf_nndistance.cpp tf_nndistance.cu.o -o tf_nndistance_so.so \
-I /usr/local/cuda-10.0/include/ -I /home/machinelearning/.local/lib/python3.6/site-packages/tensorflow_core/include -L /usr/local/cuda-10.0/lib64/ -lcudart -L /home/machinelearning/.local/lib/python3.6/site-packages/tensorflow_core -ltensorflow_framework \
    -shared -D_GLIBCXX_USE_CXX11_ABI=0 -std=c++11 -fPIC -O2
/usr/bin/ld: cannot find -ltensorflow_framework
collect2: error: ld returned 1 exit status
makefile:13: recipe for target 'tf_nndistance_so.so' failed
make: *** [tf_nndistance_so.so] Error 1

The environment is tf.version == 1.15 and cuda == 10.0, and the modified content as follow:

cuda_inc = /usr/local/cuda-10.0/include/
cuda_lib = /usr/local/cuda-10.0/lib64/
nvcc = /usr/local/cuda-10.0/bin/nvcc
tf_inc = /home/machinelearning/.local/lib/python3.6/site-packages/tensorflow_core/include
tf_lib =/home/machinelearning/.local/lib/python3.6/site-packages/tensorflow_core

Thanks a lot.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:3
  • Comments:18 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
TerenceCYJcommented, Jul 2, 2020

Hi. The same problem appears. Have you got the solution?

This can be solved by: cd /home/machinelearning/.local/lib/python3.6/site-packages/tensorflow_core ln -s libtensorflow_framework.so.1 libtensorflow_framework.so

2reactions
GopiRajuMattacommented, Jul 4, 2020

@mihaimorariu, I really appreciate your help. I am getting new errors. I will work around. I will try to resolve those. I will update you.

Thank you so much Gopi

Read more comments on GitHub >

github_iconTop Results From Across the Web

c++ Simple makefile advice - Stack Overflow
1 Answer 1 ... Ok I tried the command "make" and the compiler said "main_J is up to date". ... when i am...
Read more >
Tutorial on writing makefiles
A makefile is the set of instructions that you use to tell makepp how to build your program. Makepp can accept most makefiles...
Read more >
Three tips you should definitely know about gcc and makefile ...
This video presents common knowledge about the gcc and make file, such as the rules of writing makefile, parameters to specify include ...
Read more >
Beginner to OSDev looking for some advice - Reddit
The main point of makefiles is to tell it which file depends on which, and how to produce each target file. This way,...
Read more >
Advice for managing a Makefile generic to many distros [solved]
a makefile can contain include statements and conditional code. So you could include the system specific makefile. http://www.chemie.fu-berlin.
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