调整sane库打包到wen

This commit is contained in:
modehua 2023-04-15 13:06:21 +08:00
parent bcbe4f90db
commit e2be8f2f62
1 changed files with 34 additions and 31 deletions

View File

@ -47,7 +47,6 @@ if [ "$oem" != "hg" ] \
&& [ "$oem" != "lscso" ] \
&& [ "$oem" != "hwso" ] \
&& [ "$oem" != "lscsm" ]\
&& [ "$oem" != "ctsso" ]\
&& [ "$oem" != "cts" ]\
&& [ "$oem" != "zg" ]\
@ -305,7 +304,9 @@ elif [ "$oem" == "cts" ] \
|| [ "$oem" == "ctsso" ];
then
ver3=18
elif [ "$oem" == "zj" ];
elif [ "$oem" == "zj" ]\
|| [ "$oem" == "zjweb" ]\
|| [ "$oem" == "zjsso" ];
then
ver3=20
elif [ "$oem" == "zg" ];
@ -381,53 +382,55 @@ rm dpkg/$dpkgtype/$oem/etc/udev/rules.d/*
cp dpkg/60-sane.rules dpkg/$dpkgtype/$oem/etc/udev/rules.d/60-"$oem"sane.rules
#创建sane的文件目录 //必须保证这一步成功
rm -rf dpkg/$dpkgtype/$oem/usr/lib/*
if [ $? -ne 0 ];then
echo "del sane file fail"
exit 1
fi
if [ ! -d dpkg/$dpkgtype/$oem/usr/lib/$libpath ];
if [ "${oem:0-2:2}" != "so" ] || [ "${oem:0-3:3}" != "web" ];
then
mkdir -p dpkg/$dpkgtype/$oem/usr/lib/$libpath/sane
#创建sane的文件目录 //必须保证这一步成功
rm -rf dpkg/$dpkgtype/$oem/usr/lib/*
if [ $? -ne 0 ];then
echo "mkdir sane file fail !!! --->mkdir path dpkg/$dpkgtype/$oem/usr/lib/$libpath/sane"
echo "del sane file fail"
exit 1
fi
cp release/$syspath/$cpu/libsane-"$sanelibname"sane.so dpkg/$dpkgtype/$oem/usr/lib/$libpath/sane/libsane-"$sanelibname"sane.so.1
if [ $? -ne 0 ];then
echo "copy libsane file fail sane name is :libsane-"$sanelibname"sane.so!!!"
exit 1
fi
#kylin sp1有其他路径无法区分sp1 还是sp版本 ,所以全部进行拷贝即可 kylin mips 特殊处理
if [ "$cpu" == "mips64" ];
if [ ! -d dpkg/$dpkgtype/$oem/usr/lib/$libpath ];
then
mkdir -p dpkg/$dpkgtype/$oem/usr/lib/"mips64el-linux-gnuabi64"/sane
mkdir -p dpkg/$dpkgtype/$oem/usr/lib/$libpath/sane
if [ $? -ne 0 ];then
echo "mips64el mkdir sane file fail !!!"
echo "mkdir sane file fail !!! --->mkdir path dpkg/$dpkgtype/$oem/usr/lib/$libpath/sane"
exit 1
fi
cp release/$syspath/$cpu/libsane-"$sanelibname"sane.so dpkg/$dpkgtype/$oem/usr/lib/"mips64el-linux-gnuabi64"/sane/libsane-"$sanelibname"sane.so.1
cp release/$syspath/$cpu/libsane-"$sanelibname"sane.so dpkg/$dpkgtype/$oem/usr/lib/$libpath/sane/libsane-"$sanelibname"sane.so.1
if [ $? -ne 0 ];then
echo "copy libsane file fail sane name is :libsane-"$sanelibname"sane.so!!!"
exit 1
fi
fi
else
echo "del sane file fail"
exit 1
#kylin sp1有其他路径无法区分sp1 还是sp版本 ,所以全部进行拷贝即可 kylin mips 特殊处理
if [ "$cpu" == "mips64" ];
then
mkdir -p dpkg/$dpkgtype/$oem/usr/lib/"mips64el-linux-gnuabi64"/sane
if [ $? -ne 0 ];then
echo "mips64el mkdir sane file fail !!!"
exit 1
fi
cp release/$syspath/$cpu/libsane-"$sanelibname"sane.so dpkg/$dpkgtype/$oem/usr/lib/"mips64el-linux-gnuabi64"/sane/libsane-"$sanelibname"sane.so.1
if [ $? -ne 0 ];then
echo "copy libsane file fail sane name is :libsane-"$sanelibname"sane.so!!!"
exit 1
fi
fi
else
echo "del sane file fail"
exit 1
fi
fi
if [ "$oem" == "lscweb" ] || [ "$oem" == "hwweb" ] || [ "$oem" == "hgweb" ] || [ "$oem" == "ctsweb" ];
if [ "$oem" == "lscweb" ] || [ "$oem" == "hwweb" ] || [ "$oem" == "hgweb" ] || [ "$oem" == "ctsweb" ] || [ "$oem" == "zjweb" ];
then
cp -rf release/$syspath/$cpu/* dpkg/$dpkgtype/$oem/opt/$dpkgpath/bin
elif [ "$oem" == "hgso" ] || [ "$oem" == "hwso" ] || [ "$oem" == "lscso" ] || [ "$oem" == "ctsso" ];
elif [ "$oem" == "hgso" ] || [ "$oem" == "hwso" ] || [ "$oem" == "lscso" ] || [ "$oem" == "ctsso" ] || [ "$oem" == "zjso" ];
then
cp -rf release/$syspath/$cpu/* dpkg/$dpkgtype/$oem/opt/$dpkgpath/lib
cp sdk/include/scannerlib/* dpkg/$dpkgtype/$oem/opt/$dpkgpath/include