使用C语言和C++封装海康威视网络SDK库,使用Golang调用C库

王帅锟 a52e1a27fc 1. 修复 Go 不同架构下 getSystemLibrary 获取的 dll 名 hai 10 meses
include 1c13ef429c 1. 增加 Readme.md hai 10 meses
src 8d55048f7b git init hai 10 meses
.dockerignore 1c13ef429c 1. 增加 Readme.md hai 10 meses
.gitignore 1c13ef429c 1. 增加 Readme.md hai 10 meses
CMakeLists.txt 1c13ef429c 1. 增加 Readme.md hai 10 meses
Dockerfile 1c13ef429c 1. 增加 Readme.md hai 10 meses
Hikvision.go a52e1a27fc 1. 修复 Go 不同架构下 getSystemLibrary 获取的 dll 名 hai 10 meses
README.md 1c13ef429c 1. 增加 Readme.md hai 10 meses
go.mod 167dd8be77 1. 修复 go.mod module 为 gitea.com/kunmeng/HikNetSDKPkg hai 10 meses
go.sum 8d55048f7b git init hai 10 meses
library.cpp 1c13ef429c 1. 增加 Readme.md hai 10 meses
openLibary_unix.go 4fa9ce6131 1. 修复 包名为 HikNetSDK hai 10 meses
openLibrary_windows.go 4fa9ce6131 1. 修复 包名为 HikNetSDK hai 10 meses

README.md

已验证系统环境

架构 系统 使用docker
aarch64 alpine:3.19 🐳
x86_64 alpine:3.19 🐳
x86_64 windows 10

编译流程

1. 下载库

在仓库的发行版中 将 HikNetSDK 标签下的不同架构的 lib 放在源码根目录中

D:.
│  V6.1.9.45_build20220902_ArmLinux64_ZH_20240802154010_lib.zip
│  V6.1.9.48_build20230410_linux64_20240829112751_lib.zip
│  V6.1.9.48_build20230410_win64_20240829112623_lib.zip

2.1 编译 Linux 部分

将下载的zip压缩文件 ArmLinux64linux64 在源码目录解压,然后重命名

V6.1.9.45···ArmLinux64···.zip   --解压后重命名为--> arm64_linux_lib
V6.1.9.48···linux64···.zip    --解压后重命名为--> amd64_linux_lib

2.2 编译 Windows 部分

将下载的zip压缩文件 win64 在源码目录解压,然后重命名

V6.1.9.45···win64···.zip   --解压后重命名为--> arm64_windows_lib