mirror of http://192.168.10.4:8099/sane/dpkg.git
add TWAIN components to package
This commit is contained in:
parent
609ce7157b
commit
4cfd69b7d1
23
build.sh
23
build.sh
|
@ -1,3 +1,6 @@
|
||||||
|
# usage: build.sh oem os password twain
|
||||||
|
# the last parameter 'twain' is optional for building twain-ui, added on 2023-07-18
|
||||||
|
|
||||||
oem=$1 #厂商
|
oem=$1 #厂商
|
||||||
password="hg123123" #电脑密码
|
password="hg123123" #电脑密码
|
||||||
cpu=$(arch) #cpu架构
|
cpu=$(arch) #cpu架构
|
||||||
|
@ -122,6 +125,9 @@ function appbuild()
|
||||||
./../code_app/build.sh ${oem%${oem:0-2:2}*}
|
./../code_app/build.sh ${oem%${oem:0-2:2}*}
|
||||||
else
|
else
|
||||||
./../code_app/build.sh $oem
|
./../code_app/build.sh $oem
|
||||||
|
#if [ "${4}" == "twain" ]; then
|
||||||
|
./../code_app/build.sh ${oem}twain
|
||||||
|
#fi
|
||||||
echo ""
|
echo ""
|
||||||
fi
|
fi
|
||||||
echo "-----------------------------over code_app build-----------------------------"
|
echo "-----------------------------over code_app build-----------------------------"
|
||||||
|
@ -382,6 +388,11 @@ rm dpkg/$dpkgtype/$oem/etc/udev/rules.d/*
|
||||||
|
|
||||||
cp dpkg/60-sane.rules dpkg/$dpkgtype/$oem/etc/udev/rules.d/60-"$oem"sane.rules
|
cp dpkg/60-sane.rules dpkg/$dpkgtype/$oem/etc/udev/rules.d/60-"$oem"sane.rules
|
||||||
|
|
||||||
|
# make directory for TWAIN components ...
|
||||||
|
mkdir dpkg/$dpkgtype/$oem/usr/local
|
||||||
|
mkdir dpkg/$dpkgtype/$oem/usr/local/lib
|
||||||
|
mkdir dpkg/$dpkgtype/$oem/usr/local/lib/twain
|
||||||
|
|
||||||
if [ "${oem:0-2:2}" != "so" ] && [ "${oem:0-3:3}" != "web" ];
|
if [ "${oem:0-2:2}" != "so" ] && [ "${oem:0-3:3}" != "web" ];
|
||||||
then
|
then
|
||||||
#创建sane的文件目录 //必须保证这一步成功
|
#创建sane的文件目录 //必须保证这一步成功
|
||||||
|
@ -401,6 +412,10 @@ then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cp release/$syspath/$cpu/libsane-"$sanelibname"sane.so dpkg/$dpkgtype/$oem/usr/lib/$libpath/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 [ "${4}" == "twain" ]; then
|
||||||
|
cp release/$syspath/$cpu/libtwaindsm.so dpkg/$dpkgtype/$oem/usr/local/lib/libtwaindsm.so
|
||||||
|
cp release/$syspath/$cpu/lib${oem}twain*.ds dpkg/$dpkgtype/$oem/usr/local/lib/twain/
|
||||||
|
#fi
|
||||||
|
|
||||||
if [ $? -ne 0 ];then
|
if [ $? -ne 0 ];then
|
||||||
echo "copy libsane file fail sane name is :libsane-"$sanelibname"sane.so!!!"
|
echo "copy libsane file fail sane name is :libsane-"$sanelibname"sane.so!!!"
|
||||||
|
@ -416,6 +431,10 @@ then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
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/"mips64el-linux-gnuabi64"/sane/libsane-"$sanelibname"sane.so.1
|
||||||
|
#if [ "${4}" == "twain" ]; then
|
||||||
|
cp release/$syspath/$cpu/libtwaindsm.so dpkg/$dpkgtype/$oem/usr/local/lib/libtwaindsm.so
|
||||||
|
cp release/$syspath/$cpu/lib${oem}twain*.ds dpkg/$dpkgtype/$oem/usr/local/lib/twain/
|
||||||
|
#fi
|
||||||
|
|
||||||
if [ $? -ne 0 ];then
|
if [ $? -ne 0 ];then
|
||||||
echo "copy libsane file fail sane name is :libsane-"$sanelibname"sane.so!!!"
|
echo "copy libsane file fail sane name is :libsane-"$sanelibname"sane.so!!!"
|
||||||
|
@ -447,6 +466,10 @@ else
|
||||||
mkdir -p "dpkg/$syspath/$oem/usr/local/lib/sane/"
|
mkdir -p "dpkg/$syspath/$oem/usr/local/lib/sane/"
|
||||||
fi
|
fi
|
||||||
cp release/$syspath/$cpu/libsane-"$sanelibname"sane.so dpkg/$dpkgtype/$oem/usr/local/lib/sane/libsane-"$sanelibname"sane.so.1
|
cp release/$syspath/$cpu/libsane-"$sanelibname"sane.so dpkg/$dpkgtype/$oem/usr/local/lib/sane/libsane-"$sanelibname"sane.so.1
|
||||||
|
#if [ "${4}" == "twain" ]; then
|
||||||
|
cp release/$syspath/$cpu/libtwaindsm.so dpkg/$dpkgtype/$oem/usr/local/lib/libtwaindsm.so
|
||||||
|
cp release/$syspath/$cpu/lib${oem}twain*.ds dpkg/$dpkgtype/$oem/usr/local/lib/twain/
|
||||||
|
#fi
|
||||||
fi
|
fi
|
||||||
savedpkgpath="dpkg/$dpkgtype/$oem/opt/apps/$dpkgpath"
|
savedpkgpath="dpkg/$dpkgtype/$oem/opt/apps/$dpkgpath"
|
||||||
echo $dpkgpath
|
echo $dpkgpath
|
||||||
|
|
Loading…
Reference in New Issue