-
Notifications
You must be signed in to change notification settings - Fork 693
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Linux Build Error #271
Comments
you need to prepare all the third party deps libs your self, such as opencv with ffmpeg, onnxruntime, also need NCNN/MNN/TNN if you want to build lite.ai.toolkit with NCNN/MNN/TNN support. please check README for more details. In fact, I have already provided some prebuilt libs of lite.ai.toolkit for linux with onnxruntime support. |
Linux and Windows.
and put the libs into lite.ai.toolkit/lib/(linux|windows) directory. Please reference the build-docs1 for third_party.
Note, your also need to install ffmpeg(<=4.2.2) in Linux to support the opencv videoio module. See issue#203. In MacOS, ffmpeg4.2.2 was been package into lite.ai.toolkit, thus, no installation need in OSX. In Windows, ffmpeg was been package into opencv dll prebuilt by the team of opencv. Please make sure -DWITH_FFMPEG=ON and check the configuration info when building opencv.
git clone --depth=1 https://git.ffmpeg.org/ffmpeg.git -b n4.2.2
cd ffmpeg
./configure --enable-shared --disable-x86asm --prefix=/usr/local/opt/ffmpeg --disable-static
make -j8
make install
#!/bin/bash
mkdir build
cd build
cmake .. \
-D CMAKE_BUILD_TYPE=Release \
-D CMAKE_INSTALL_PREFIX=your-path-to-custom-dir \
-D BUILD_TESTS=OFF \
-D BUILD_PERF_TESTS=OFF \
-D BUILD_opencv_python3=OFF \
-D BUILD_opencv_python2=OFF \
-D BUILD_SHARED_LIBS=ON \
-D BUILD_opencv_apps=OFF \
-D WITH_FFMPEG=ON
make -j8
make install
cd .. after built opencv, you can follow the steps to build lite.ai.toolkit.
|
also, you can download the linux prebuilt libs from releases, and, then, reuse the opencv, ffpmeg and onnxruntime prebuilt libs provided by lite.ai.toolkit |
hello, i have already built the minimal dependency like OpenCV and OnnxRuntime, copied all the libs and turned off NCNN/MNN/TNN support in CMAKE (e.g enable ncnn engine), i also have tried copy the prebuult libs and copied them into lite.ai.toolkit libs. Do i also need to build NCNN MNN and TNN even though i turned them off? I dont know why but it seems like CMAKE does not link lite.ai.toolkit/libs when building.. Thank you for the answer! |
hi~ you may need to put the libs into |
Ah i see!! Thank you very much!! I will try to rebuilt it. |
Thank you very much! I was able to successfully build the toolkit!! :D |
Hello, i am sorry for re commenting on closed issue, but can i please ask for help?
My cmake :
|
opencv in windows is a singleton lib, not have split libs like opencv in mac and linux. |
which means, i have to combine all the libs into single folder? |
not sure. opencv lib in windows is named like opencv_worldxxx.dll ? you may need to link this dll. I'm not familiar with Windows OS. |
Ah i see! |
I got this error while building in Linux:
Please help! thanks!
The text was updated successfully, but these errors were encountered: