http://www.zendo.name/solaris-11-stdio-h%EF%BC%9A-no-such-file-or-directory/
在Solaris 11下使用gcc编译器,安装编译器
1
|
pkg install gcc-45 或者 pkg install gcc-3
|
数字是gcc版本号
但是在进行编译时,会出现头文件错误,最基本的stdio.h也找不到
1
|
root@solaris11:~ # cat hello.c
|
1
2
3
4
5
6
7
8
|
#include <stdio.h> int main( int argc, char * argv[])
{ while (1) {
getchar ();
}
return 0;
} |
1
|
root@solaris11:~$ gcc hello.c |
1
|
hello.c:1:19 fatal error: stdio.h: No such file or directory |
1
|
root@solaris11:~$ slocate stdio.h |
1
2
3
4
5
6
7
8
|
/usr/include/glib-2.0/glib/gstdio.h /usr/include/libgsf-1/gsf/gsf-output-stdio.h /usr/include/libgsf-1/gsf/gsf-outfile-stdio.h /usr/include/libgsf-1/gsf/gsf-input-stdio.h /usr/include/libgsf-1/gsf/gsf-infile-stdio.h /usr/include/ast/ast_stdio.h /usr/include/ast/stdio.h /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/include/ssp/stdio.h |
用slocate寻找,找到了很多头文件,可是没用,难道是链接库的位置错误?不是,默认的solaris 11并没有安装完整的头文件,只需要安装system/header即可
1
|
pkg install system /header
|
这样就可以正常编译了,而solocate的结果里也会多出一项 /usr/gcc/4.5/include/c++/4.5.2/tr1/stdio.h
solaris 11 stdio.h: No such file or directory的更多相关文章
-
numa.h:No such file or directory 解决方法
参考: numa.h:No such file or directory numa.h:No such file or directory 解决方法 Ubuntu: $ apt-get install ...
-
Python.h:No such file or directory
出现No such file or directory的错误,有两种情况,一种是真的没有Python.h这个文件,一种是Python的版本不对, 可以进入/usr/include/文件夹下的Pytho ...
-
如何解决Python.h:No such file or directory
安装python2.7对应的dev sudo apt-get install python-dev 安装python3.6对应的dev sudo apt-get install python3-dev
-
OK6410 rmmod卸载模块失败:No such file or directory -- 转
原文地址:http://hi.baidu.com/andio/item/b8be9810282841433a176e86 rmmod chdir no such file or directory 说 ...
-
新增分区格式化时提示设备文件不存在:--- No such file or directory的处理方法
[原文链接]:http://blog.itpub.net/28874898/viewspace-774249/ 在系统中的空余空间添加新的分区: fdisk /dev/sda (第一块硬盘上) ...
-
使用exceljs时报错:no such file or directory
最近使用exceljs生成excel并保存时,总是失败 await workbook.xlsx.writeFile(tep) .then(function () { context.result = ...
-
交叉编译工具链bash: gcc:no such file or directory
在进行交叉编译工具链安装时,有三种方法: 1.源码编译,手动安装 2.二进制可执行文件直接安装 3.直接解压工具链,手动修改环境变量 为了方便,我们多用方法3进行安装.但是问题来了,你的工具链制作时有 ...
-
手动编译源码安装包报错 fatal error:cruses.h: no such file or direcrory
很明显是缺少cruses.h这个文件,但是用yum搜索又搜不到,可能是我的yum源的库包太少的原因吧. 后来多方查找,发现cruses.h这个头文件属于ncurses模块,需要安装ncurses-de ...
-
利用Qt Designer 进行 空间提升propomotion 的时候异常: NO such file or directory
1. 因为在提升的时候,只设置了 类名,以及文件名,但是没有给定Qt 的uic 的指定搜索路径,因此报错 在生成的ui_xxxx.h文件必然找不到这个文件. 如下图: 2. 解决方法 在项目的属性中: ...
随机推荐
-
Delphi_08_Delphi_Object_Pascal_基本语法_06_函数参数
发现Delphi中关于函数参数部分的内容还是比较多的,暂时说到这篇随笔为止吧,以后再继续讨论一下函数的参数部分的内容. 一 工程文件 program DefaultParameter; {$APPTY ...
-
Excel常用操作
[对Excel工作表,按某一列数据进行排序] 选中这些数据,在菜单栏上点"数据 - 排序",在弹出的窗口中的主要关键字里选择这一列,按升序或降序,那么其它的数据也会跟着它一一对应变 ...
-
leetcode 172
172. Factorial Trailing Zeroes Given an integer n, return the number of trailing zeroes in n!. Note: ...
-
java complier compliance level问题引发的思考
http://blog.csdn.net/shan9liang/article/details/17266519 ******************************************* ...
-
C++编程开发学习的50条建议(转)
每个从事C++开发的朋友相信都能给后来者一些建议,但是真正为此进行大致总结的很少.本文就给出了网上流传的对C++编程开发学习的50条建议,总结的还是相当不错的,编程学习者(不仅限于C++学习者)如果真 ...
-
构建ASP.NET MVC4+EF5+EasyUI+Unity2.x注入的后台管理系统(44)-工作流设计-设计表单
原文:构建ASP.NET MVC4+EF5+EasyUI+Unity2.x注入的后台管理系统(44)-工作流设计-设计表单 系列目录 设计表单是比较复杂的一步,完成一个表单的设计其实很漫长,主要分为四 ...
-
【转】Entity Framework教程
转自:http://www.cnblogs.com/xray2005/category/189491.html Entity Framework系列文章导航 摘要: 本节集合了Entity Fra ...
-
jQuery点击下拉菜单的展示与隐藏
首先点击显示某个div,然后要求再次点击时消失,或者点击document的其他地方会隐藏掉这个层,涉及到冒泡的问题,阻止document冒泡到dom上.代码如下: var $el = $(" ...
-
tengine 的优化
查服务器CPU的核数 : [root@c01 conf]# grep processor /proc/cpuinfo |wc -l 4 [root@c01 conf]# grep -c process ...
-
【Linux】在虚拟机上安装CentOS7
在配置好的机子上,可以装个双系统,但是在我自己的本子上,磁盘读写太垃圾了,连压缩卷 都执行不了,分不出空间,装不了CentOS系统,没办法,采用虚拟机的方式,把它转起来. -------------- ...