leezu commented on a change in pull request #17448: cmake: staticbuild for
binary distribution
URL: https://github.com/apache/incubator-mxnet/pull/17448#discussion_r376171808
##########
File path: tools/dependencies/opencv.sh
##########
@@ -161,7 +161,7 @@ if [[ ! -f $DEPS_PATH/lib/libopencv_core.a ]] || [[ ! -f
$DEPS_PATH/lib/libopenc
-D BUILD_opencv_gpuoptflow=OFF \
-D BUILD_opencv_gpustereo=OFF \
-D BUILD_opencv_gpuwarping=OFF \
- -D BUILD_opencv_highgui=OFF \
+ -D BUILD_opencv_highgui=ON \
Review comment:
`im2rec` linking fails when removing `highgui`. Need to check the cause
```
[2020-02-07T01:08:50.550Z] /tmp/im2rec-923f97.o: In function `main':
[2020-02-07T01:08:50.550Z] tools/im2rec.cc:(.text+0x222c): undefined
reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.550Z] tools/im2rec.cc:(.text+0x2db8): undefined
reference to `cv::imencode(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&, cv::_InputArray const&,
std::vector<unsigned char, std::allocator<unsigned char> >&, std::vector<int,
std::allocator<int> > const&)'
[2020-02-07T01:08:50.550Z] build/src/io/iter_image_det_recordio.o: In
function
`mxnet::io::ImageDetRecordIOParser<float>::ParseNext(std::vector<mxnet::io::InstVector<float>,
std::allocator<mxnet::io::InstVector<float> > >*)::{lambda()#1}::operator()()
const':
[2020-02-07T01:08:50.550Z]
src/io/iter_image_det_recordio.cc:(.text._ZZN5mxnet2io22ImageDetRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EEENKUlvE_clEv[_ZZN5mxnet2io22ImageDetRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EEENKUlvE_clEv]+0x22f):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.550Z]
src/io/iter_image_det_recordio.cc:(.text._ZZN5mxnet2io22ImageDetRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EEENKUlvE_clEv[_ZZN5mxnet2io22ImageDetRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EEENKUlvE_clEv]+0x311):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.550Z]
src/io/iter_image_det_recordio.cc:(.text._ZZN5mxnet2io22ImageDetRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EEENKUlvE_clEv[_ZZN5mxnet2io22ImageDetRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EEENKUlvE_clEv]+0x3fe):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.550Z] build/src/io/image_io.o: In function
`mxnet::io::ImdecodeImpl(int, bool, void*, unsigned long, mxnet::NDArray*)':
[2020-02-07T01:08:50.550Z] src/io/image_io.cc:(.text+0x728): undefined
reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.550Z] src/io/image_io.cc:(.text+0x839): undefined
reference to `cv::imdecode(cv::_InputArray const&, int, cv::Mat*)'
[2020-02-07T01:08:50.550Z] build/src/io/iter_image_recordio.o: In function
`mxnet::io::ImageRecordIOParser<float>::ParseNext(std::vector<mxnet::io::InstVector<float>,
std::allocator<mxnet::io::InstVector<float> > >*)':
[2020-02-07T01:08:50.551Z]
src/io/iter_image_recordio.cc:(.text._ZN5mxnet2io19ImageRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EE[_ZN5mxnet2io19ImageRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EE]+0x2c0):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.551Z]
src/io/iter_image_recordio.cc:(.text._ZN5mxnet2io19ImageRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EE[_ZN5mxnet2io19ImageRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EE]+0x39e):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.551Z]
src/io/iter_image_recordio.cc:(.text._ZN5mxnet2io19ImageRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EE[_ZN5mxnet2io19ImageRecordIOParserIfE9ParseNextEPSt6vectorINS0_10InstVectorIfEESaIS5_EE]+0x47b):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.551Z] build/src/io/iter_image_recordio.o: In function
`mxnet::io::ImageRecordIOParser<unsigned
char>::ParseNext(std::vector<mxnet::io::InstVector<unsigned char>,
std::allocator<mxnet::io::InstVector<unsigned char> > >*)':
[2020-02-07T01:08:50.551Z]
src/io/iter_image_recordio.cc:(.text._ZN5mxnet2io19ImageRecordIOParserIhE9ParseNextEPSt6vectorINS0_10InstVectorIhEESaIS5_EE[_ZN5mxnet2io19ImageRecordIOParserIhE9ParseNextEPSt6vectorINS0_10InstVectorIhEESaIS5_EE]+0x2bc):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.551Z]
src/io/iter_image_recordio.cc:(.text._ZN5mxnet2io19ImageRecordIOParserIhE9ParseNextEPSt6vectorINS0_10InstVectorIhEESaIS5_EE[_ZN5mxnet2io19ImageRecordIOParserIhE9ParseNextEPSt6vectorINS0_10InstVectorIhEESaIS5_EE]+0x3ae):
undefined reference to `cv::imdecode(cv::_InputArray const&, int)'
[2020-02-07T01:08:50.551Z]
build/src/io/iter_image_recordio.o:src/io/iter_image_recordio.cc:(.text._ZN5mxnet2io19ImageRecordIOParserIhE9ParseNextEPSt6vectorINS0_10InstVectorIhEESaIS5_EE[_ZN5mxnet2io19ImageRecordIOParserIhE9ParseNextEPSt6vectorINS0_10InstVectorIhEESaIS5_EE]+0x49b):
more undefined references to `cv::imdecode(cv::_InputArray const&, int)' follow
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services