cmd/cgo: undefined reference to OpenCV C++ function call #30800
Labels
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
What version of Go are you using (
go version
)? 1.12What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
I have successfully installed gocv package from https://github.com/hybridgroup/gocv and I am trying to run C++ code which I wrapped in C library inside my Go project. But there seems to be the problem when I try to call
cv::optflow::createOptFlow_DualTVL1()
method. I get undefined reference error. I dont know why, since inoptflow.hpp
file there is a method calledcreateOptFlow_DualTVL1()
Here is my
main.go
:Here is dense_flow.h:
And here is dense_flow.cpp:
#include "dense_flow.h"
What did you expect to see?
For my program to be built.
What did you see instead?
The text was updated successfully, but these errors were encountered: