In file included from /usr/include/stdio.h:34, from hello.c:2: /usr/lib/gcc/i686-linux-gnu/4.4.5/include/stddef.h:211: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘typedef’ In file included from /usr/include/stdio.h:75, from hello.c:2: /usr/include/libio.h:332: error: expected specifier-qualifier-list before ‘size_t’ /usr/include/l...
by fmh414888 - Linux环境编程 - 2012-02-27 22:45:51 阅读(3277) 回复(3)
前两天开始动手,想弄个gcc4.4玩玩,在网上google了一下,首先急匆匆的把源码给弄下来了,用的是svn: svn checkout svn://gcc.gnu.org/svn/gcc/trunk gcc 首先找了个安装指南,地址在:http://gcc.gnu.org/install/ 下面描述我的安装过程(系统:ubuntu9.04 x86_64,现有gcc版本:系统自带的4.3.3版本) 按照上面的指南的步骤,扫了一眼prerequistes,直接跳过(或许这是造成后面麻烦的原因之一吧) 然后开始配置,首先...
今天安装了最新版的ubuntu7。10,然后用gcc编个程序 #include "stdio.h" main() { printf(" hello linux !"); } 然后保存并命名为hello.c 然后执行命令: gcc hello hello.c 可是编译不出来 提示为 gcc: hello: No such file or directory Hello.c:1:19: error: stdio.h:No such file or directory Hello.c: In function 'main': Hello.c:4: warning: incompatible implicit declaration of built-in function 'printf' 我是新...
root@ygh-desktop:/usr/local/src/gcc-3.3.2# ./configure --prefix=/usr/local/gcc332 Configuring for a i686-pc-linux-gnulibc1 host. *** This configuration is not supported in the following subdirectories: target-libffi target-boehm-gc target-zlib target-libjava (Any other directories should still work fine.) Created "Makefile" in /usr/local/src/gcc-3.3.2 using "mt-frag" /usr/bin/ld:crt1.o:...
1. 下载crosstool-0.43.tar.gz 【crosstool-0.43.tar.gz】 http://kegel.com/crosstool/crosstool-0.43.tar.gz 2. 配置 crosstool-0.43 [xxxx@ ctools]$ echo $HOME /home/xxxx [xxxx@ ctools]$ mkdir download crosstool-4.1.1 [xxxx@ ctools]$ tar zxvf crosstool-0.43.tar.gz [xxxx@ ctools]$ cd crosstool-0.43 [color="#0000ff"][xxxx@ crosstool-0.43]$ vi demo-arm.sh #!/bin/sh # This script has one...
前几天在服务器上装了个ubuntu8.04, 上面的gcc是4.2.4版本的. 而我有时候需要测试产品在最新gcc编译后的运行情况, 于是,我就装了个gcc-4.3.3. 安装4.3.3是个很简单的过程, 主要就是tar -xzf, configure,make的过程. 不过由于开始没注意, 就遇到一系列错误, 比如: "gnu/stubs-32.h: No such file or directory", 因为是64位的机器,默认是没有stubs-32.h, 于是一查,我装了ia32-libs. 装好后,这个是没了, 其他又出来了主要是编译32位...
大家好, 我在ubuntu6.1上下载了gcc4.1.1的源码,运行了下面的configure命令 ../gcc-4.1.1/configure --prefix=$HOME/d##Projects/gccDebug/InstallPfx --program-suffix=-4.1.1 --enable-threads=posix --disable-cpp --enable-initfini-array --enable-language=c,c++,treelang --enable-libssp --enable-checking=release --enable-coverage --enable-gather-detailed-mem-stats --with-gc 生成Makefile之后运行“make bootst...
如题,参考了网上所说的ubuntu降低gcc版本的deb包dpkg的安装方法,成功在update-altnertive --config gcc上完成新安装的gcc链接。gcc -v也能看到新安装的gcc版本,为什么就是不能编译文件。提示如下: root@ankerli-X201E:~# gcc -g -E hello.c -o hello In file included from /usr/include/stdio.h:27, from hello.c:1: /usr/include/features.h:374:25: error: sys/cdefs.h: 没有那个文件或目录 /usr/inc...