gstreamer的arm编译过程及错误分析

时间:2021-04-27 16:33:23
 

gstreamer0.10.24 下载:http://gstreamer.freedesktop.org/src/gstreamer/

glib2.28.0 下载

libxml2-2.7.2 下载

交叉编译器:arm-2010q1
主机:ubuntu10.04
0.设置环境变量
vim .bashrc(在后面加上以下代码)
export PATH=/usr/local/arm/arm-2010q1/bin:$PATH

#(1)glib2.28.0

cd glib2.28.0
CC=arm-none-linux-gnueabi-gcc ./configure --build=i686-linux --host=arm-none-linux-gnueabi --prefix=/home/nation/glib-arm glib_cv_stack_grows=no glib_cv_uscore=no ac_cv_func_posix_getpwuid_r=yes ac_cv_func_posix_getgrgid_r=yes ac_cv_lib_rt_clock_gettime=no glib_cv_monotonic_clock=yes

sudo make
sudo make isntall

#(2)libxml2-2.7.2

cd libxml2-2.7.2

CC=arm-none-linux-gnueabi-cc sudo ./configure --build=i686-linux --host=arm-none-linux-gnueabi --prefix=/home/nation/libxml2-arm

sudo make
sudo make install

#(3)gstreamer-0.10.24
cd gstreamer-0.10.24
export PKG_CONFIG_PATH=/usr/lib/pkgconfig
export GLIB=/home/nation/glib-arm
export LIBXML2=/home/nation/libxml2-arm
export CFLAGS="$CFLAGS -I$GLIB/include -I$LIBXML2/include -I$GLIB/lib/glib-2.0/include"
export LDFLAGS="-L$GLIB/lib -L$LIBXML2/lib"

CC=arm-none-linux-gnueabi-gcc sudo ./configure --build=i686-linux --host=arm-none-linux-gnueabi --prefix=/home/nation/gstream-arm NM=$(MVTOOL_PREFIX)nm --disable-registry --disable-loadsave --disable-gtk-doc ac_cv_func_register_printf_function=no --disable-tests --disable-valgrind --disable-debug --disable-gst-debug

sudo make

sudo make install

错误分析:


(1)
configure: error:
*** You must have either have gettext support in your C library, or use the
*** GNU gettext library. (http://www.gnu.org/software/gettext/gettext.html

安装pc机的gettext
(2)
checking for glib-genmarshal... no
configure: error: Could not find a glib-genmarshal in your PATH

安装pc机的glib

(3)
checking for bison... no
configure: error: Could not find bison
安装pc机的bison
(4)
checking for flex... no
configure: error: Could not find flex
安装pc机的flex

(5)gstreamer
../libtool: eval: line 4174: syntax error near unexpected token `|


./configuer加上 NM=$(MVTOOL_PREFIX)nm

(6)libxml2
/bin/rm: cannot remove 'libtoolT': No such file or directory
Done configuring
但是没看到error字样,应该成功了吧。

也可以 vi libtoolT 保存退出