1.下载源码
2.解压,配置
tar -xzf xawtv-3.95.tar.gz
cd xawtv-3.95/
./configure --prefix=$PWD/tmp
make
make install
3.出现的错误
1)console/fs.h找不到
console/fs.h:2:20: error: FSlib.h: No such file or directory
解决:
sudo apt-get install libfs-dev
sudo apt-get install libxaw7-dev
安装完成后make依然出错
接着查找FSlib.h在哪里
直接修改console/fs.h第二行为: #include <X11/fonts/FSlib.h>即可
或者在配置阶段使用./configure --prefix=$PWD/tmp --x-includes=/usr/include/X11/fonts/
2)asm/page.h找不到
console/fbtools.c:24:22: error: asm/page.h: No such file or directory
console/matrox.c:12:38: error: asm/page.h: No such file or directory
把asm/page.h修改为sys/user.h即可。
3)console/fs.o: In function `fs_open':
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:226: undefined reference to `FSListFonts'
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:235: undefined reference to `FSOpenBitmapFont'
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:236: undefined reference to `FSFreeFontNames'
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:240: undefined reference to `FSQueryXInfo'
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:243: undefined reference to `FSQueryXExtents16'
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:244: undefined reference to `FSQueryXBitmaps16'
console/fs.o: In function `fs_connect':
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:196: undefined reference to `FSOpenServer'
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:198: undefined reference to `FSServerName'
/work/ming/disanqi/2_camera_wifi_3G_alsa_video/xawtv-3.95/console/fs.c:201: undefined reference to `FSServerName'
collect2: ld returned 1 exit status
make: *** [console/fbtv] Error 1
在Makefile里面添加 -lFS
接着make成功,最后make install
在tmp目录下看到编译出来的xawtv以及一些库,文档
参考:https://blog.csdn.net/zhang_danf/article/details/79268017