Skip to content
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

cannot find -llibgsl #10

Open
plmokn86 opened this issue Jun 26, 2020 · 7 comments
Open

cannot find -llibgsl #10

plmokn86 opened this issue Jun 26, 2020 · 7 comments

Comments

@plmokn86
Copy link

libgsl.dll和libgslcblas.dll 已放到bin_qt5.14.1_debug目录下,但编译时报错:
error: cannot find -llibgsl
什么原因?
我的环境:win10, Qt_5_14_1_MinGW_32

@czyt1988
Copy link
Owner

拉取一下最新版,我把gsl的lib也添加进来了

@YihanHu-2022
Copy link

您好我昨天拉取了最新版本的项目,但是在配置过程中也出现了同样的问题,请问是否有办法解决呢

@YihanHu-2022
Copy link

环境为 win10 5_12_9_MinGw_64

@czyt1988
Copy link
Owner

src/3rdParty/gsl/lib下是否有libgsl.lib和libgslcblas.lib文件,如果有,清理一下再重新编译
另外,编译过程和.dll没有关系,找不到lib要确保上述两个lib文件是否存在

@YihanHu-2022
Copy link

抱歉还是没有解决这个问题,请问确保lib文件存在的意思是指让libgsl.lib文件存在吗?如果是的话应该存在在哪个目录下呢

@YihanHu-2022
Copy link

还有在项目运行的时候会出现丢失精度的报错:
SAItem.cpp:38: error: cast from 'SAItem*' to 'int' loses precision [-fpermissive]
SAMdiSubWindow.cpp:25: error: cast from 'SAMdiSubWindow*' to 'int' loses precision [-fpermissive]
SAMainWindow.cpp:57: error: cast from 'const SAMainWindow*' to 'int' loses
请问这个该如何解决

@czyt1988
Copy link
Owner

抱歉还是没有解决这个问题,请问确保lib文件存在的意思是指让libgsl.lib文件存在吗?如果是的话应该存在在哪个目录下呢

是的,应该存在src/3rdParty/gsl/lib/libgsl.lib和src/3rdParty/gsl/lib/libgslcblas.lib

还有在项目运行的时候会出现丢失精度的报错:
SAItem.cpp:38: error: cast from 'SAItem*' to 'int' loses precision [-fpermissive]
SAMdiSubWindow.cpp:25: error: cast from 'SAMdiSubWindow*' to 'int' loses precision [-fpermissive]
SAMainWindow.cpp:57: error: cast from 'const SAMainWindow*' to 'int' loses
请问这个该如何解决

把C风格的强制转换变为C++风格,如: m_id(reinterpret_cast(par)),m_id = reinterpret_cast(this);
你是哪个编译器?后续的提交我会把这个改了。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants