Skip to content
This repository has been archived by the owner on Jan 25, 2022. It is now read-only.

how Mac to mexopencv #463

Open
baba1587 opened this issue Dec 23, 2020 · 1 comment
Open

how Mac to mexopencv #463

baba1587 opened this issue Dec 23, 2020 · 1 comment

Comments

@baba1587
Copy link

when I use mex here are something wrong .
错误使用 mexOpenCV (line 137)
Undefined symbols for architecture x86_64:
"_mexFunction", referenced from:
-exported_symbol[s_list] command line option
(maybe you meant: _mexFunctionAdapter)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

who can help me? thank you

@baba1587
Copy link
Author

MEX 配置为使用 'Xcode Clang++' 以进行 C++ 语言编译。

mexOpenCV '/Users/shantong/Downloads/mexopencv-master/src/mexopencv_ml.cpp'
使用 'Xcode Clang++' 编译。
错误使用 mexOpenCV (line 137)
Undefined symbols for architecture x86_64:
"MxArray::MxArray(bool)", referenced from:
void MxArray::set(std::__1::basic_string<char,
std::__1::char_traits, std::__1::allocator > const&, bool const&,
unsigned long) in mexopencv_ml.o
"MxArray::MxArray(double)", referenced from:
void MxArray::set(std::__1::basic_string<char,
std::__1::char_traits, std::__1::allocator > const&, double const&,
unsigned long) in mexopencv_ml.o
void MxArray::set(std::__1::basic_string<char,
std::__1::char_traits, std::__1::allocator > const&, float const&,
unsigned long) in mexopencv_ml.o
"MxArray::MxArray(int)", referenced from:
void MxArray::set(std::__1::basic_string<char, std::__1::char_traits,
std::__1::allocator > const&, int const&, unsigned long) in mexopencv_ml.o
"MxArray::toInt() const", referenced from:
createTrainData(cv::Mat const&, cv::Mat const&, std::__1::__wrap_iter<MxArray
const*>, std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
loadTrainData(std::__1::basic_string<char, std::__1::char_traits,
std::__1::allocator > const&, std::__1::__wrap_iter<MxArray const*>,
std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
"MxArray::toMat(int, bool) const", referenced from:
createTrainData(cv::Mat const&, cv::Mat const&, std::__1::__wrap_iter<MxArray
const*>, std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
"MxArray::toBool() const", referenced from:
createTrainData(cv::Mat const&, cv::Mat const&, std::__1::__wrap_iter<MxArray
const*>, std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
loadTrainData(std::__1::basic_string<char, std::__1::char_traits,
std::__1::allocator > const&, std::__1::__wrap_iter<MxArray const*>,
std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
"MxArray::toDouble() const", referenced from:
createTrainData(cv::Mat const&, cv::Mat const&, std::__1::__wrap_iter<MxArray
const*>, std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
loadTrainData(std::__1::basic_string<char, std::__1::char_traits,
std::__1::allocator > const&, std::__1::__wrap_iter<MxArray const*>,
std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
"MxArray::toString() const", referenced from:
createTrainData(cv::Mat const&, cv::Mat const&, std::__1::__wrap_iter<MxArray
const*>, std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
loadTrainData(std::__1::basic_string<char, std::__1::char_traits,
std::__1::allocator > const&, std::__1::__wrap_iter<MxArray const*>,
std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
"std::__1::vector<std::__1::basic_string<char, std::__1::char_traits,
std::__1::allocator >, std::__1::allocator<std::__1::basic_string<char,
std::__1::char_traits, std::__1::allocator > > >
MxArray::toVector<std::__1::basic_string<char, std::__1::char_traits,
std::__1::allocator > >() const", referenced from:
createTrainData(cv::Mat const&, cv::Mat const&, std::__1::__wrap_iter<MxArray
const*>, std::__1::__wrap_iter<MxArray const*>) in mexopencv_ml.o
"_mexFunction", referenced from:
-exported_symbol[s_list] command line option
(maybe you meant: _mexFunctionAdapter)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant