接上篇https://blog.csdn.net/qq_32605451/article/details/122540358?spm=1001.2014.3001.5501
所需文件gphoto2,libexif,popt
编译链为MP157: arm-buildroot-linux-gnueabihf
一、编译popt
下载popt_1.16.orig .tar.gz,并解压
配置
./configure --prefix=/ --host=arm-buildroot-linux-gnueabihf
编译安装
make
make install DESTDIR=/home/han/arm_mp157_libgphoto2
二、编译libexif
下载libexif-master并解压
配置
autoreconf -i
./configure --prefix=/ --host=arm-buildroot-linux-gnueabihf
编译安装
make
make install DESTDIR=/home/han/arm_mp157_libgphoto2
三、编译gphoto2
下载gphoto2_2.5.27.tar.gz并解压
配置
./configure --prefix=/ --host=arm-buildroot-linux-gnueabihf \
LDFLAGS='-ldl' \
POPT_CFLAGS=-I/home/han/arm_mp157_libgphoto2/include/ \
POPT_LIBS="-L/home/han/arm_mp157_libgphoto2/lib/ -lpopt" \
LIBLTDL=/home/han/arm_mp157_libgphoto2/lib/libltdl.a \
LTDLINCL=-I/home/han/arm_mp157_libgphoto2/include/ \
LIBUSB_LIBS=/home/han/arm_mp157_libgphoto2/lib/libusb-1.0.a \
LIBUSB_CFLAGS=-I/home/han/arm_mp157_libgphoto2/include/ \
LIBEXIF_CFLAGS=-I/home/han/arm_mp157_libgphoto2/include/ \
LIBEXIF_LIBS=/home/han/arm_mp157_libgphoto2/lib/libexif.a \
--with-libgphoto2=/home/han/arm_mp157_libgphoto2 \
--without-cdk \
--without-readline \
--without-aalib \
--without-jpeg \
--without-pthread
编译安装
make
make install DESTDIR=/home/han/arm_mp157_libgphoto2
三、将文件拷贝到arm开发板上
在arm开发板上创建/home/han/arm_mp157_libgphoto2即安装目录,将生成的文件全部拷贝到此目录下
使用
`cp -rfd 自行补齐`