waimifeier / hikvision-spring-boot-starter

海康威视sdk接入
58 stars 22 forks source link

打包后,在ubuntu上运行报错了 #9

Open zolagz opened 1 year ago

zolagz commented 1 year ago

2023-07-02 15:39:06.739 ERROR 813586 --- [ main] c.n.h.config.HikVisionAutoConfiguration : 加载playControl失败} java.io.FileNotFoundException: class path resource [sdk/linux/libPlayCtrl.so] cannot be resolved to absolute file path because it does not reside in the file system: jar:file:/home/user01/hk_dev/hk_rtsp-1.0-SNAPSHOT.jar!/BOOT-INF/classes!/sdk/linux/libPlayCtrl.so

解决方案如下:

根据海康的设备sdk使用手册 --- 动态库环境配置 ,把sdk放在linux系统的/usr/lib文件下即可。 然后再 application.yml 文件里配置如下:

hik: sdk-path: /usr/lib