QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 2838|回复: 1

[求助]请教一个freetype的问题。

[复制链接]
发表于 2007-1-27 18:28:52 | 显示全部楼层 |阅读模式
交叉编译freetype-2.1.10,步骤如下:
./configure --prefix=/usr/local/arm/2.95.3/arm-linux --host=arm-linux
CC=/usr/local/arm/2.95.3/bin/arm-linux-gcc
make
make install
编译完freetype-2.1.10后,/usr/local/arm/2.95.3/arm-linux/lib下多了
libfreetype.so.6.3.8
libfreetype.so.6
libfreetype.so
libfreetype.la
libfreetype.a
共5个文件。
/usr/local/arm/2.95.3/arm-linux/include下多了个目录freetype2,fretype2下有个目录freetype,freetype下是几个目录和些头文件,看时间应该是编译后生成的。

然后编译ft2demos-2.1.10,一个示例程序包,步骤如下:
make
提示:Please compile the library before the demo programs!
请问什么原因???

还有,如果单独编译freetype-doc-2.1.10中的一个名为example1.c的文件,步骤如下:
arm-linux-gcc -o example1 example1.c
提示如下:
[root@haha infotest]# arm-linux-gcc -o exa exa.c
/tmp/ccmdcBgl.o: In function `main':
/tmp/ccmdcBgl.o(.text+0x2e0): undefined reference to `FT_Init_FreeType'
/tmp/ccmdcBgl.o(.text+0x30: undefined reference to `FT_New_Face'
/tmp/ccmdcBgl.o(.text+0x32c): undefined reference to `FT_Set_Char_Size'
/tmp/ccmdcBgl.o(.text+0x34c): undefined reference to `cos'
/tmp/ccmdcBgl.o(.text+0x36: undefined reference to `sin'
/tmp/ccmdcBgl.o(.text+0x38: undefined reference to `sin'
/tmp/ccmdcBgl.o(.text+0x3a4): undefined reference to `cos'
/tmp/ccmdcBgl.o(.text+0x41: undefined reference to `FT_Set_Transform'
/tmp/ccmdcBgl.o(.text+0x43: undefined reference to `FT_Load_Char'
/tmp/ccmdcBgl.o(.text+0x4f0): undefined reference to `FT_Done_Face'
/tmp/ccmdcBgl.o(.text+0x4f: undefined reference to `FT_Done_FreeType'
collect2: ld returned 1 exit status
请问是什么原因呢???

请各位帮忙解答,谢谢!!!
发表于 2007-2-5 20:11:36 | 显示全部楼层
arm-linux-gcc -o example1 example1.c  -lfreetype
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-4-19 03:45 , Processed in 0.065971 second(s), 15 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表