Sdl.h没有这样的文件或目录 [英] Sdl.h no such file or directory

查看:670
本文介绍了Sdl.h没有这样的文件或目录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在项目中设置了SDL,并且还希望包含图像库和混音器库,但出现此错误.

http://imgur.com/a/ltM93

我尝试过的事情:

我不知道这些工作原理如何,但是当我尝试包含.h图像库时,它会显示出来,因此我必须缺少某些内容.

I have SDL set up in a project and want to also include the image and mixer libs ,but i get this error.

http://imgur.com/a/ltM93

What I have tried:

I don''t know how these things work but the .h image lib shows up when I try to include it so i must be missing something

推荐答案

告诉编译器他应该在哪里寻找包含文件.通常通过使用-I命令行选项和环境变量来完成此操作.另请参见 The C Preprocessor:Search Path [
You have to tell the compiler where he should look for include files. This is usually done by using the -I command line option and environment variables. See also The C Preprocessor: Search Path[^].

When using an IDE, there is usually a configuration option to specify additional pathes (for the current project and gobally for all projects). Add there the path to your SDL.h file.

Note that similar applies to the .lib library files for which there are also path options.


这篇关于Sdl.h没有这样的文件或目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆