Answer the question
In order to leave comments, you need to log in
Is it possible to use string functions in specifying dependencies for targets?
There was such a question.
Let's say there is a file src/Test/Test.cpp. After compilation, I want to get src_Test_Test.o.
Previously, in the makefile, I get the final name of the objects.
To return to the full name (with directory names) I write the following thing:
%.o : $(subst _,/,%.cpp)
<...>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question