Closed rocket-booster closed 2 years ago
2.7.2
操作系统:ubuntu16.04 架构:mingw
加载方式:通过add_requires("hiredis")和add_packages("hiredis") 加载
linux:加载正常 { static = true, license = "BSD-3-Clause", version = "v1.0.2", libfiles = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/lib/libhiredis.a" }, linkdirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/lib" }, sysincludedirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/include" }, links = { "hiredis" } }
{ static = true, license = "BSD-3-Clause", version = "v1.0.2", libfiles = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/lib/libhiredis.a" }, linkdirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/lib" }, sysincludedirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/include" }, links = { "hiredis" } }
mingw:只能检测到头文件,不能检测到库。 { license = "BSD-3-Clause", shared = true, version = "v1.0.2", sysincludedirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/69688960df35471daf9e3809068a0433/include" } }
{ license = "BSD-3-Clause", shared = true, version = "v1.0.2", sysincludedirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/69688960df35471daf9e3809068a0433/include" } }
mingw需要xrepo info hiredis查询到安装路径,通过add_linkdirs后才能检测到库。 add_linkdirs("/home/rocky/.xmake/packages/h/hiredis/v1.0.2/69688960df35471daf9e3809068a0433/lib")
可能是库名字特殊导致: /home/rocky/.xmake/packages/h/hiredis/v1.0.2/69688960df35471daf9e3809068a0433/lib/libhiredis.dll.a
希望能跟linux一样,自动检测库。
No response
可以了,再试下
xrepo update-repo xrepo remove --all hiredis xmake f -p mingw -c xmake
nice,已解决
Xmake 版本
2.7.2
操作系统版本和架构
操作系统:ubuntu16.04 架构:mingw
描述问题
加载方式:通过add_requires("hiredis")和add_packages("hiredis") 加载
linux:加载正常
{ static = true, license = "BSD-3-Clause", version = "v1.0.2", libfiles = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/lib/libhiredis.a" }, linkdirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/lib" }, sysincludedirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/944c61d7a4e443f89f1bfbce4436adaf/include" }, links = { "hiredis" } }
mingw:只能检测到头文件,不能检测到库。
{ license = "BSD-3-Clause", shared = true, version = "v1.0.2", sysincludedirs = { "/home/rocky/.xmake/packages/h/hiredis/v1.0.2/69688960df35471daf9e3809068a0433/include" } }
mingw需要xrepo info hiredis查询到安装路径,通过add_linkdirs后才能检测到库。 add_linkdirs("/home/rocky/.xmake/packages/h/hiredis/v1.0.2/69688960df35471daf9e3809068a0433/lib")
可能是库名字特殊导致: /home/rocky/.xmake/packages/h/hiredis/v1.0.2/69688960df35471daf9e3809068a0433/lib/libhiredis.dll.a
期待的结果
希望能跟linux一样,自动检测库。
工程配置
No response
附加信息和错误日志
No response