LinuxForum.Fans
Тема

Посоветуйте с установкой МФУ xerox workcеntre pe 220

Автор: Andrey271064 11 сообщений 4934 просмотров
#228021

Всем здравия! Посоветуйте как установить в Мане 2011 мфушку xerox workcеntre pe 220. Скачал из нета прогу pe120_220_install.tar.gz , а что дальше делать не знаю. Или может это не то что надо. Очень был бы благодарен. В установках встает xerox workcеntre pe 120 и когда отправляю документ на печать принтер разогревается но дальше ничего не происходит

#228070

или может быть можно из консоли как-то установить программу с дровами, скачать из инета...но тогда с камими расширениями должен быть скачиваемый файл? oO

#228085

В архиве ищи файлики "Readme" или "install", в них указанно как устанавливать. Или выложи их содержимое сюда.
А через МСС пробовал настраивать?

#228093

Вот файл install.sh

Показать
text

#! /bin/sh
#
#    MFP Driver Package Installation script.
#    Product setup script
#

cd `dirname $0` ################################################################################################## # Defines

source ./set_variables.sh ./OEM.ini

# VENDOR=`grep '^VENDOR=' OEM.ini 2>/dev/null | sed 's/VENDOR=\(.*\)/\1/'` # if [ -z "$VENDOR" ]; then # echo "File OEM.ini does not exist or invalid" # echo "Exit installation" # exit 1 # fi # VENDOR_UC=`echo $VENDOR | tr a-z A-Z` # VENDOR_LC=`echo $VENDOR | tr A-Z a-z` # MFP_INSTALL_DIR=/usr/local/bin/$VENDOR_LC

if [ -f /etc/slackware-version ]; then SLACKWARE_DETECTED="1" else SLACKWARE_DETECTED="0" fi

AUTORUN_INF_FILE='../autorun.inf'

# Defines ##################################################################################################

###################################################################################### # Procedures

check_package() { if [ "$SLACKWARE_DETECTED" == "1" ]; then result=`ls /var/log/packages/$1-* 2> /dev/null` rv=$? result=`echo $result | awk -F '-' '{print $2}'` else result=`rpm -q --queryformat '%{VERSION}' $1 2>/dev/null` rv=$? fi return $rv }

#Detects if xwindow is installed IsXWindowInstalled() { status=0 result=0

if echo "$LINUX_DIST" | grep -q GUADALINEX ; then if ps auxw | grep -v grep | grep -wq X ; then result=1 fi fi

if ps -C X > /dev/null; then result=1 fi

if ps auxw | grep -v grep | grep -wq XFree86 ; then result=1 fi

echo $result

return $status }

######################################################################################

#Detects if RPM is installed IsRPMInstalled() { status=1 result=0

rpmName=`rpm --version | head -c 11 -` if [ $? -eq 0 ] && [ "$rpmName" == "RPM version" ]; then result=1 status=0 fi

# echo $result

return $status }

######################################################################################

#Detects if CUPS is installed IsCUPSInstalled() { status=1;

if echo "$LINUX_DIST" | grep -q GUADALINEX ; then if test -d /etc/cups -a -e /usr/sbin/cupsd ; then result="1.1.20" return $status fi fi

if ! check_package cups ; then result=`cups-config --version 2>/dev/null` if [ $? -ne 0 ] && ! [ -e /usr/sbin/cupsd ] ; then result= fi fi

# echo $result

return $status }

######################################################################################

#Get GhostScript version IsGSInstalled() { status=1;

if ! check_package ghostscript ; then result=`gs --version 2>/dev/null` if [ $? -ne 0 ] ; then result= fi fi

# echo $result

return $status }

######################################################################################

#Detects if SANE is installed IsSANEInstalled() { status=1

if echo "$LINUX_DIST" | grep -q "GUADALINEX\|KNOPPIX" ; then if test -d /etc/sane.d -a -n "`ls /usr/lib/libsane.so.* 2> /dev/null`" ; then result="1.0.13" return $status fi fi

if ! check_package sane ; then if ! check_package sane-backends ; then if ! check_package xsane ; then result=`sane-config --version 2>/dev/null` if [ $? -ne 0 ] && ! [ -e /usr/lib/libsane.so.1 ] ; then result= fi fi fi fi

# echo $result

return $status }

######################################################################################

#USAGE: compareVersions file1 file2 #Versions notation 'x1' 'x1.x2' 'x1.x2.x3' # 0 == # 1 > # -1 < # 2 error compareVersions() { # test files exists & readable if ! [ -r $1 ] || ! [ -r $2 ] ; then echo 2 return fi

v11=`awk -F '.' '{print $1}' $1` v12=`awk -F '.' '{print $2}' $1` v13=`awk -F '.' '{print $3}' $1` v21=`awk -F '.' '{print $1}' $2` v22=`awk -F '.' '{print $2}' $2` v23=`awk -F '.' '{print $3}' $2` rm -f $1 rm -f $2

# test first digits are not empty if ! [ $v11 ] || ! [ $v21 ] ; then echo 2 return fi if [ $v11 -gt $v21 ]; then echo 1 return fi if [ $v11 -lt $v21 ]; then echo -1 return fi if [ -z $v12 ] && [ -z $v22 ]; then echo 0 return fi

# test second digits are not empty if [ $v12 ] && [ $v22 ]; then if [ $v12 -gt $v22 ]; then echo 1 return fi if [ $v12 -lt $v22 ]; then echo -1 return fi if [ -z $v13 ] && [ -z $v23 ]; then echo 0 return fi if [ $v13 ] && [ $v23 ]; then if [ $v13 -gt $v23 ]; then echo 1 return fi if [ $v13 -lt $v23 ]; then echo -1 return fi echo 0 return else if [ $v13 ] ; then echo 1 return fi if [ $v23 ]; then echo -1 return fi fi else if [ $v12 ] ; then echo 1 return fi if [ $v22 ]; then echo -1 return fi fi

echo 2 return }

######################################################################################

# Test digit (digit digit) IsDigit() { result=0 case $1 in [0-9]) result=1;; [0-9][0-9]) result=1;; *) result=0;; esac echo $result return $result }

######################################################################################

print_manifest() { echo echo "$1 that is required for driver package to work properly was not" echo "detected on your system. Please exit installation procedure and install" echo "$1 package from your Linux distribution CD-ROM or from Linux distribution" echo "vendor web site" echo -e "\t[1] Exit installation procedure" echo -e "\t[2] I am sure I have necessary software installed. Continue installation" }

run_menu_exit_installation() { execMenu=1 while [ $execMenu -eq 1 ] do read -p 'Please make your choice [1,2]: ' -n 1 shallInstall case $shallInstall in 1) status=1; exit $status;; 2) status=0; execMenu=0;; *) echo -e -n '\r' esac done echo }

do_setup() { GHOSTSCRIPT_VERSION=7.05.2 DRIVER_PATH=$1

status=1

###################################################################################### # Detect the Linux environment

# rpmPresent=`IsRPMInstalled` # cupsVer=`IsCUPSInstalled` # saneVer=`IsSANEInstalled` # gsVer=`IsGSInstalled`

IsRPMInstalled ; rpmPresent=$result IsCUPSInstalled ; cupsVer=$result IsSANEInstalled ; saneVer=$result IsGSInstalled ; gsVer=$result

###################################################################################### # Make installation parameters

parCUPS=0 if [ "$cupsVer" != "" ]; then parCUPS=1 fi #------------------------------------------------------------------------------------- parSANE=0 if [ "$saneVer" != "" ]; then parSANE=1 fi #------------------------------------------------------------------------------------- parGS=0 if [ "$gsVer" != "" ]; then # Any version of gs is good for us now parGS=1 # echo "$gsVer" > $TMP_DIR/dummy1$$ # echo "$GHOSTSCRIPT_VERSION" > $TMP_DIR/dummy2$$ # verCmp=`compareVersions $TMP_DIR/dummy1$$ $TMP_DIR/dummy2$$` # if [ "$verCmp" == "0" ] ; then # parGS=1 # elif [ "$verCmp" == "1" ] ; then # parGS=1 # elif [ "$verCmp" == "-1" ] ; then # parGS=2 # fi fi

status=0

###################################################################################### # Perform installation

if [ $XWINDOWINSTALLED -eq 1 ] ; then # LD_LIBRARY_PATH=$PWD/rd:$LD_LIBRARY_PATH # export LD_LIBRARY_PATH ## ../../../mfpinstall RPM=-1 CUPS=$parCUPS QtCUPS=-1 KUPS=-1 SANE=$parSANE SCRIPTS=$PWD DRIVER=$DRIVER_PATH LANGUAGE=$LANGUAGE # ../../../mfpinstall CUPS=$parCUPS GS=$parGS SANE=$parSANE SCRIPTS=$PWD DRIVER=$DRIVER_PATH LANGUAGE=$LANGUAGE ./mfpinstall CUPS=$parCUPS GS=$parGS SANE=$parSANE SCRIPTS=$PWD DRIVER=$DRIVER_PATH LANGUAGE=$LANGUAGE status=$? else # OK. If we are here - things are really goes better. No let's make environment for and install driver package echo 'MFP driver package is about to be installed on your system...' ############################################################################################ # Check CUPS if [ $parCUPS -ne 1 ]; then print_manifest "CUPS" run_menu_exit_installation fi ############################################################################################ # Check GhostScript if [ $parGS -ne 1 ]; then print_manifest "GhostScript" run_menu_exit_installation fi ############################################################################################ # Check SANE if [ $parSANE -ne 1 ]; then print_manifest "SANE" run_menu_exit_installation fi # OK. We've managed all the preparation - install driver package if [ $status -eq 0 ]; then CUR_DIR=$PWD cd "$DRIVER_PATH" sh drivers.sh install status=$? cd "$CUR_DIR" fi ############################################################################### # Report installation's result if [ $status -eq 0 ]; then echo 'MFP driver package has been installed successfully.' else echo 'Installation failed' fi fi

return $status }

#///////////////////////////////////////////////////////////////////////////////////// #// Beginning of MFP setup program

###################################################################################### # Check kernel version KERNEL_VER=2.4 XWINDOWINSTALLED=`IsXWindowInstalled` TMP_DIR=/var/tmp if ! [ -d $TMP_DIR ]; then mkdir -p -m 777 $TMP_DIR fi status=1 osVer=`uname -r` osVer1=`echo $osVer|awk -F '.' '{print $1}' -` osVer2=`echo $osVer|awk -F '.' '{print $2}' -` echo $osVer1.$osVer2 > $TMP_DIR/dummy1$$ echo $KERNEL_VER > $TMP_DIR/dummy2$$ verCmp=`compareVersions $TMP_DIR/dummy1$$ $TMP_DIR/dummy2$$` if [ $verCmp -eq 2 ] || [ $verCmp -lt 0 ]; then echo Wrong Linux Kernel version. Kernel must be $KERNEL_VER or highter. Installation halted... exit 1 fi # Check kernel version ######################################################################################

# Copy x86_64 binaries into installation pool begin { if [ -d x86_64 ]; then mkdir -p $MFP_INSTALL_DIR/x86_64/ cp -a -f x86_64/* $MFP_INSTALL_DIR/x86_64/ else echo '*** WARNING ! This distribution does NOT support AMD64 / EM64T systems ***' sleep 3 fi # Copy x86_64 binaries into installation pool end }

###################################################################################### # Prepare qt library

# Check if libstdc++ v3 (gcc 2.96) installed if [ ! -h /usr/lib/libstdc++-libc6.2-2.so.3 -o ! -f /usr/lib/libstdc++-3-libc6.2-2-2.10.0.so ]; then echo -n "libstdc++ v3 (gcc 2.96) not found, intstall ... " zcat rd/libstdc++-3.tar.gz | tar -xf - -C / ldconfig echo "done" fi

LD_LIBRARY_PATH=$PWD/rd:$LD_LIBRARY_PATH export LD_LIBRARY_PATH

# Prepare qt library ######################################################################################

MODEL= MODEL_DIRECTORY= LANGUAGE=English ACTION=Install ###################################################################################### # Parse parameters if [ $# -eq 4 ]; then MODEL=$1 MODEL_DIRECTORY=$2 LANGUAGE=$3 ACTION=$4 fi # Parse parameters ######################################################################################

# Uncoment the next line to force text mode install #XWINDOWINSTALLED=0

###################################################################################### # Make sure CUPS is started if present

if ! ( ps -e | grep cupsd >/dev/null 2>/dev/null ) ; then `cupsd >/dev/null 2>/dev/null` fi

# Make sure CUPS is started if present ######################################################################################

status=0 if [ $XWINDOWINSTALLED -eq 1 ]; then ###################################################################################### # Install under XWin if [ "$MODEL" == "" ] ; then # First start - let's determine parameters echo 'Starting graphical installation part. Please, wait...' ./autorun.gui & exit 0 else case $ACTION in install) # Install driver # CUR_DIR=$PWD # cd "./platforms/$LINUX_DISTR/scripts" ## sh setup.sh $XWINDOWINSTALLED ../../../models/$MODEL_DIRECTORY/$LINUX_DISTR $LANGUAGE # sh setup.sh $XWINDOWINSTALLED ../../../models/$MODEL_DIRECTORY $LANGUAGE do_setup ./models/$MODEL_DIRECTORY status=$? # cd "$CUR_DIR";; ;; uninstall) # Uninstall driver CUR_DIR=$PWD ### cd "./models/$MODEL_DIRECTORY/$LINUX_DISTR" # cd "./models/$MODEL_DIRECTORY" # sh drivers.sh uninstall ./uninstall -p ./models/$MODEL_DIRECTORY -e ./drivers.sh -a uninstall status=$? cd "$CUR_DIR";; *) echo "Wrong action. You can either 'install' or 'uninstall' driver package." exit 1;; esac fi else ###################################################################################### # No XWin - text installation

###################################################################################### # OK. Now determine what to install, or, may be, uninstall (model, directory, language, action). if [ "$MODEL" == "" ] ; then # First start - let's determine parameters

# Hey, User! Lets talk!

###################################################################################### # 1. - MFP model & directory transString=`cat $AUTORUN_INF_FILE | grep ModelName | awk -F '=' '{print $2}' - | tr ' ' '~'` echo i=0 for translated in $transString; do i=`expr $i + 1` done if [ $i -eq 1 ]; then MODEL=`echo $translated | tr '~' ' '` MODEL_DIRECTORY=`cat $AUTORUN_INF_FILE | grep DriversDir | awk -F '=' '{print $2}' -` else echo 'Please, select your device model...' i=0 for translated in $transString; do i=`expr $i + 1` name=`echo $translated | tr '~' ' '` echo -e '\t' [$i] $name done iCancel=`expr $i + 1` echo -e '\t' [$iCancel] 'Cancel installation' execMenu=1 while [ $execMenu -eq 1 ] do read -p 'Please make your choice [1,2, ...]: ' -n 1 shallInstall result=`IsDigit $shallInstall` if [ $result -eq 1 ] ; then if [ $shallInstall -ge 1 ] && [ $shallInstall -le $i ]; then execMenu=0 # Get model & dir names j=0 for translated in $transString do j=`expr $j + 1` if [ $j -eq $shallInstall ]; then MODEL=`echo $translated | tr '~' ' '` fi done transDirs=`cat $AUTORUN_INF_FILE | grep DriversDir | awk -F '=' '{print $2}' - | tr ' ' '~'` j=0 for translated in $transDirs do j=`expr $j + 1` if [ $j -eq $shallInstall ]; then MODEL_DIRECTORY=`echo $translated | tr '~' ' '` fi done fi if [ $shallInstall -eq $iCancel ]; then echo exit 1 fi fi echo -e -n '\r' done echo fi

###################################################################################### # 2. - Language - NO USE. DON'T understand anything except english. LANGUAGE=English

###################################################################################### # 3. - Action echo echo 'What would you like to do?..' echo -e '\t[1] Install driver package' echo -e '\t[2] Uninstall driver package' echo -e '\t[3] Cancel installation' execMenu=1 while [ $execMenu -eq 1 ] do read -p 'Please make your choice [1,2,3]: ' -n 1 shallInstall case $shallInstall in 1) ACTION=install execMenu=0;; 2) ACTION=uninstall execMenu=0;; 3) status=1; echo exit $status;; *) echo -e -n '\r' esac done echo # Well. If we are still here - let's do something useful ###################################################################################### # Perform driver installation/uninstallation

#228094

есть еще один,наверное этот нужен pe220.install

Показать
text

#!/bin/sh
# Installation script for Xerox WorkCentre PE220 Series Driver version 1.0.
# Produced using ESP Package Manager v3.3.0; report problems to epm@easysw.com.
#%product Xerox WorkCentre PE220 Series Driver
#%vendor Xerox (c)
#%copyright Xerox (c)
#%version 1.0 1000001
#%description Xerox WorkCentre PE220 Series CUPS printer configuration file.
#%rootsize 0
#%usrsize 358
#
PATH=/usr/xpg4/bin:/bin:/usr/bin:/usr/ucb:${PATH}
SHELL=/bin/sh
if test "`id -u`" != "0"; then
    echo Sorry, you must be root to install this software.
    exit 1
fi
echo 'Copyright Xerox (c)'
# Reset umask for install...
umask 002
# Determine correct echo options...
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
    ac_n=-n
    ac_c=
else
    ac_n=
    ac_c='\c'
fi
# Determine correct extract options for the tar command...
if test `uname` = Darwin; then
    ac_tar="tar -xpPf"
else if test "`tar --help 2>&1 | grep GNU`" = ""; then
    ac_tar="tar -xpf"
else
    ac_tar="tar -xpPf"
fi fi
if test "$*" = "now"; then
    echo Software license silently accepted via command-line option.
else
    echo ""
    echo This installation script will install the 'Xerox WorkCentre PE220 Series Driver'
    echo software version '1.0' on your system.
    echo ""
    while true ; do
        echo $ac_n "Do you wish to continue? $ac_c"
        read yesno
        case "$yesno" in
            y | yes | Y | Yes | YES)
            break
            ;;
            n | no | N | No | NO)
            exit 1
            ;;
            *)
            echo Please enter yes or no.
            ;;
        esac
    done
    more pe220.license
    echo ""
    while true ; do
        echo $ac_n "Do you agree with the terms of this license? $ac_c"
        read yesno
        case "$yesno" in
            y | yes | Y | Yes | YES)
            break
            ;;
            n | no | N | No | NO)
            exit 1
            ;;
            *)
            echo Please enter yes or no.
            ;;
        esac
    done
fi
if test -x /etc/software/pe220.remove; then
    echo Removing old versions of pe220 software...
    /etc/software/pe220.remove now
fi
case `uname` in
    AIX)
    dfroot=`df -k / | tr '\n' ' '`
    dfusr=`df -k /usr | tr '\n' ' '`
    fsroot=`echo $dfroot | awk '{print $15}'`
    sproot=`echo $dfroot | awk '{print $11}'`
    fsusr=`echo $dfusr | awk '{print $15}'`
    spusr=`echo $dfusr | awk '{print $11}'`
    ;;

HP-UX) dfroot=`df -k / | tr '\n' ' '` dfusr=`df -k /usr | tr '\n' ' '` fsroot=`echo $dfroot | awk '{print $1}'` sproot=`echo $dfroot | awk '{print $9}'` fsusr=`echo $dfusr | awk '{print $1}'` spusr=`echo $dfusr | awk '{print $9}'` ;;

IRIX*) dfroot=`df -k / | tr '\n' ' '` dfusr=`df -k /usr | tr '\n' ' '` fsroot=`echo $dfroot | awk '{print $15}'` sproot=`echo $dfroot | awk '{print $13}'` fsusr=`echo $dfusr | awk '{print $15}'` spusr=`echo $dfusr | awk '{print $13}'` ;;

SCO*) dfroot=`df -k -B / | tr '\n' ' '` dfusr=`df -k -B /usr | tr '\n' ' '` fsroot=`echo $dfroot | awk '{print $13}'` sproot=`echo $dfroot | awk '{print $11}'` fsusr=`echo $dfusr | awk '{print $13}'` spusr=`echo $dfusr | awk '{print $11}'` ;;

*) dfroot=`df -k / | tr '\n' ' '` dfusr=`df -k /usr | tr '\n' ' '` fsroot=`echo $dfroot | awk '{print $13}'` sproot=`echo $dfroot | awk '{print $11}'` fsusr=`echo $dfusr | awk '{print $13}'` spusr=`echo $dfusr | awk '{print $11}'` ;; esac

temp=`ls -ln pe220.sw | awk '{print $5}'` spsw=`expr $temp / 1024`

temp=`ls -ln pe220.ss | awk '{print $5}'` spss=`expr $temp / 1024`

spall=`expr $spsw + $spss`

if test x$sproot = x -o x$spusr = x; then echo WARNING: Unable to determine available disk space; installing blindly... else if test x$fsroot = x$fsusr; then if test $spall -gt $sproot; then echo Not enough free disk space for software: echo You need $spall kbytes but only have $sproot kbytes available. exit 1 fi else if test $spsw -gt $sproot; then echo Not enough free disk space for software: echo You need $spsw kbytes in / but only have $sproot kbytes available. exit 1 fi

if test $spss -gt $spusr; then echo Not enough free disk space for software: echo You need $spss kbytes in /usr but only have $spusr kbytes available. exit 1 fi fi fi if test -w /usr ; then echo Backing up old versions of shared files to be installed... for file in /usr/lib/sane/libsane-xerox_pe220.so /usr/lib/sane/libsane-xerox_pe220.so.1 /usr/lib/sane/libsane-xerox_pe220.so.1.0.1 \ /usr/local/bin/xerox/pe220.version /usr/local/lib/sane/libsane-xerox_pe220.so /usr/local/lib/sane/libsane-xerox_pe220.so.1 \ /usr/local/lib/sane/libsane-xerox_pe220.so.1.0.1 /usr/share/cups/model/xerox/pe220.ppd; do if test -d $file -o -f $file -o -h $file; then mv -f $file $file.O fi done fi echo Installing software... $ac_tar pe220.sw if echo Write Test >/usr/.writetest 2>/dev/null; then rm -f /usr/.writetest $ac_tar pe220.ss fi if test -d /etc/software; then rm -f /etc/software/pe220.remove else mkdir -p /etc/software fi cp pe220.remove /etc/software chmod 544 /etc/software/pe220.remove echo Running post-install commands... #! /bin/sh # # pe220 postinstall script #

################################################################################################## # Defines

PRINTER_NAME=pe220

if [ "$XEROXMFP_INSTALL_DIR" == "" ] ; then XEROXMFP_INSTALL_DIR=/usr/local/bin/xerox fi DRIVERS_REG_DIR=$XEROXMFP_INSTALL_DIR/drivers DRIVERS_REG_FILE=$DRIVERS_REG_DIR/installed_software DRIVER_REG_DIR=$DRIVERS_REG_DIR/$PRINTER_NAME

FIRMWARE_DEVICE_NAME="WorkCentre PE220 Series"

source ../../set_variables.sh ../../OEM.ini

VENDOR="Xerox" ISSUE=`cat /etc/issue 2>/dev/null` LINUX_DIST= if ( echo $ISSUE | grep -q "Red Hat Linux release 8" ); then LINUX_DIST="REDHAT_8" elif ( echo $ISSUE | grep -q "Red Hat Linux release 9" ); then LINUX_DIST="REDHAT_9" elif ( echo $ISSUE | grep -q "Fedora" ); then LINUX_DIST="FEDORA" fi

# Defines ##################################################################################################

# Register scanner CUR_PWD=$PWD SANE_CONFIG_LOCATIONS="/etc/sane.d /usr/local/etc/sane.d" for SANE_CONFIG_LOCATION in $SANE_CONFIG_LOCATIONS ; do if [ -w ${SANE_CONFIG_LOCATION}/dll.conf ] ; then if ! test -e ${SANE_CONFIG_LOCATION}/xerox_$PRINTER_NAME.dll.conf; then cd "${SANE_CONFIG_LOCATION}" echo "" >> dll.conf echo "xerox_$PRINTER_NAME" | cat dll.conf - | tr -s ["\n"] > xerox_$PRINTER_NAME.dll.conf cp -b -f xerox_$PRINTER_NAME.dll.conf dll.conf chmod 664 dll.conf fi fi done cd "$CUR_PWD"

# Install 64-bit sane backend begin {

if [ "$PLSFX" == "64" ]; then mkdir -p /usr/lib64/sane cp -a /usr/local/bin/${VENDOR_LC}/x86_64/libsane-${VENDOR_LC}_${PRINTER_NAME}.so.1.0.1 /usr/lib64/sane/ ( cd /usr/lib64/sane && \ ln -s libsane-${VENDOR_LC}_${PRINTER_NAME}.so.1.0.1 libsane-${VENDOR_LC}_${PRINTER_NAME}.so.1 ; \ ln -s libsane-${VENDOR_LC}_${PRINTER_NAME}.so.1.0.1 libsane-${VENDOR_LC}_${PRINTER_NAME}.so ) fi

# Install 64-bit sane backend end }

################################################################################################## ## Printer ppd file

gzip -f /usr/share/cups/model/xerox/$PRINTER_NAME.ppd > /dev/null 2>/dev/null

## Printer ppd file ##################################################################################################

################################################################################################## ## Install printer

#if [ -x /etc/rc.d/init.d/cups ] ; then # CUPS_SCRIPT=/etc/rc.d/init.d/cups #else # CUPS_SCRIPT=/etc/init.d/cups #fi #echo DEBUG: CUPS_SCRIPT=$CUPS_SCRIPT #CUPS_RUNNING=0 #if [ "$CUPS_SCRIPT" != "" ] && ( $CUPS_SCRIPT status 2>/dev/null | grep running >/dev/null 2>/dev/null ) ; then # CUPS_RUNNING=1 #fi #echo DEBUG: CUPS_RUNNING=$CUPS_RUNNING # #if ( service cups status 2>/dev/null | grep running >/dev/null 2>/dev/null ) ; then # CUPS_RUNNING=1 #fi #if ! [ $CUPS_RUNNING -eq 1 ] ; then # if [ -e /etc/init.d/cups ]; then # if ; then # CUPS_RUNNING=1 # fi # fi #fi #if ! [ $CUPS_RUNNING -eq 1 ] ; then # if ! ( ps -e | grep cupsd >/dev/null 2>/dev/null ) ; then # `cupsd 2>/dev/null` # fi # if ( ps -e | grep cupsd >/dev/null 2>/dev/null ) ; then # CUPS_RUNNING=1 # fi #fi

if [ "`ps ax | awk '{print $1,$5}' | grep cupsd | awk '{print $1}'`" == "" ] ; then cupsd >/dev/null 2>/dev/null ./isCupsOn 631 60 >/dev/null 2>/dev/null fi CUPS_RUNNING=1 if [ $CUPS_RUNNING -eq 1 ] ; then echo Adding printer... # Add printer read -t 1 # Get device port DEVICE_PORT= DEVICE_LINE=`/usr/lib${PLSFX}/cups/backend/mfp 2>/dev/null | grep "$FIRMWARE_DEVICE_NAME" | head -n 1` echo DEBUG: pe220.post.sh: DEVICE_LINE=$DEVICE_LINE if [ "$DEVICE_LINE" != "" ] ; then DEVICE_PORT=`echo $DEVICE_LINE | awk '{print $2}' -` fi echo DEBUG: pe220.post.sh: DEVICE_PORT=$DEVICE_PORT if [ "$DEVICE_PORT" != "" ] ; then echo DEBUG: Printer install string=lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v $DEVICE_PORT lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v $DEVICE_PORT else echo DEBUG: Printer install string=lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v mfp:/dev/mfp0 lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v mfp:/dev/mfp0 fi # if ( /usr/lib${PLSFX}/cups/backend/mfp 2>/dev/null | grep "Xerox MFP USB Port" >/dev/null ) ; then # DEVICE_PORT=`/usr/lib${PLSFX}/cups/backend/mfp 2>/dev/null | grep "Xerox MFP USB Port" | awk '{print $2}' -` # if [ "$DEVICE_PORT" != "" ] ; then # lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v $DEVICE_PORT # else # lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v mfp:/dev/mfp4 # fi # else # DEVICE_PORT=`/usr/lib${PLSFX}/cups/backend/mfp 2>/dev/null | grep "Xerox MFP Parallel Port" | awk '{print $2}' -` # if [ "$DEVICE_PORT" != "" ] ; then # lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v $DEVICE_PORT # else # lpadmin -p $PRINTER_NAME -m xerox/$PRINTER_NAME.ppd.gz -v mfp:/dev/mfp0 # fi # fi

# Enable printer read -t 1 lpadmin -p $PRINTER_NAME -E # Make printer default read -t 1 lpadmin -d $PRINTER_NAME # Set options if printer has not been installed if [ "__MFP_OVERWRITE_DRIVER__" != "1" ] ; then # Preserve existing driver options echo DEBUG: Setting SCALING option to printer=$PRINTER_NAME lpoptions -p $PRINTER_NAME -o scaling=100 -o page-left=13 -o page-top=13 -o page-right=13 -o page-bottom=13 fi fi

## Install printer ##################################################################################################

################################################################################################## ## Restart (or start) CUPS

echo "Initializing CUPS drivers..." if [ -x /etc/rc.d/init.d/cups ] ; then CUPS_SCRIPT=/etc/rc.d/init.d/cups else CUPS_SCRIPT=/etc/init.d/cups fi echo DEBUG: CUPS_SCRIPT=$CUPS_SCRIPT if [ -x $CUPS_SCRIPT ]; then $CUPS_SCRIPT restart >/dev/null 2>/dev/null else cups_pid=`ps ax | awk '{print $1,$5}' | grep cupsd | awk '{print $1}'` echo DEBUG: cups_pid=$cups_pid if [ $cups_pid != "" ] ; then kill $cups_pid fi cupsd >/dev/null 2>/dev/null fi if ./isCupsOn 631 60 >/dev/null 2>/dev/null ; then echo "done." fi

## Restart (or start) CUPS ##################################################################################################

################################################################################################## ## System menu

# Create Xerox menu items

if [ "$LINUX_DIST" == "REDHAT_8" -o "$LINUX_DIST" == "REDHAT_9" ] ; then APPLNK_FILE="/usr/share/applications/Uninstall_$PRINTER_NAME.desktop" if [ -f "$APPLNK_FILE" ] ; then rm -f "$APPLNK_FILE" fi echo "[Desktop Entry]" > "$APPLNK_FILE" echo "Name=Uninstall WorkCentre PE220 Series" >> "$APPLNK_FILE" echo "Name[C]=Uninstall WorkCentre PE220 Series" >> "$APPLNK_FILE" echo "Comment=WorkCentre PE220 Series driver uninstallation script" >> "$APPLNK_FILE" echo "Comment[C]=WorkCentre PE220 Series driver uninstallation script" >> "$APPLNK_FILE" echo "Type=Application" >> "$APPLNK_FILE" # echo "Exec=sh /usr/local/bin/xerox/drivers/$PRINTER_NAME.uninstall.sh" >> "$APPLNK_FILE" echo "Exec=/usr/local/bin/xerox/uninstall -p /usr/local/bin/xerox/drivers -e ./$PRINTER_NAME.uninstall.sh" >> "$APPLNK_FILE" echo "Path=/usr/local/bin/xerox/drivers/" >> "$APPLNK_FILE" echo "Icon=/usr/share/icons/Uninstall.png" >> "$APPLNK_FILE" echo "Terminal=0" >> "$APPLNK_FILE" echo "TerminalOptions=" >> "$APPLNK_FILE" echo "X-KDE-SubstituteUID=false" >> "$APPLNK_FILE" echo "X-KDE-Username=" >> "$APPLNK_FILE" echo 'Categories=Application;SystemSetup;X-Xerox-Config;' >> "$APPLNK_FILE" else MENU_LOCATION1=/usr/share/applnk MENU_LOCATION2=/usr/share/applnk-mdk MENU_LOCATION3= MENU_LOCATION4= if [ "$KDEDIR" != "" ] ; then MENU_LOCATION3=$KDEDIR/share/applnk MENU_LOCATION4=$KDEDIR/share/applnk-mdk fi if [ -d /usr/share/gnome/apps ] && [ "`ls /usr/share/gnome/apps 2>/dev/null`" != "" ] ; then MENU_LOCATION5=/usr/share/gnome/apps else MENU_LOCATION5=/etc/X11/applnk fi # Remove duplicated menu entries at KDE menu in Fedora if echo "$LINUX_DIST" | grep -q "FEDORA" ; then if [ "$MENU_LOCATION5" != "" ] ; then if [ -d "$MENU_LOCATION5" ] ; then if [ "$MENU_LOCATION1" ] ; then MENU_LOCATION1= fi if [ "$MENU_LOCATION3" ] ; then MENU_LOCATION3= fi fi fi fi MENU_LOCATION6= if [ "$KDEDIRS" != "" ] ; then for kdeDir in `echo $KDEDIRS | tr ' ' '|' | tr ':' ' ' | tr '|' ' '` ; do MENU_LOCATION6="$MENU_LOCATION6 $kdeDir/share/applnk" MENU_LOCATION6="$MENU_LOCATION6 $kdeDir/share/applnk-mdk" done fi for kdeDir in kde kde2 kde3 ; do MENU_LOCATION6="$MENU_LOCATION6 /opt/$kdeDir/share/applnk" MENU_LOCATION6="$MENU_LOCATION6 /opt/$kdeDir/share/applnk-mdk" done for kdeDir in kde kde2 kde3 ; do MENU_LOCATION7="$MENU_LOCATION7 /etc/opt/$kdeDir/share/applnk/SuSE" done for MFP_APPLNKS_DIR in $MENU_LOCATION1 $MENU_LOCATION2 $MENU_LOCATION3 $MENU_LOCATION4 $MENU_LOCATION5 $MENU_LOCATION6 $MENU_LOCATION7 do # if [ "$MFP_APPLNKS_DIR" != "" ] ; then echo DEBUG: $PRINTER_NAME.post.sh: MENU dir: MFP_APPLNKS_DIR=$MFP_APPLNKS_DIR - menu to be installed if [ -d "$MFP_APPLNKS_DIR" ] && mkdir -p "$MFP_APPLNKS_DIR/Xerox_MFP" ; then echo DEBUG: $PRINTER_NAME.post.sh: MENU dir: MFP_APPLNKS_DIR=$MFP_APPLNKS_DIR - MENU IS INSTALLED # if ! [ -d "$MFP_APPLNKS_DIR" ] ; then # mkdir -p "$MFP_APPLNKS_DIR" # fi

APPLNK_FILE="$MFP_APPLNKS_DIR"/Xerox_MFP/Uninstall_$PRINTER_NAME.desktop if [ -f "$APPLNK_FILE" ] ; then rm -f "$APPLNK_FILE" fi echo "[Desktop Entry]" > "$APPLNK_FILE" echo "Name=Uninstall WorkCentre PE220 Series" >> "$APPLNK_FILE" echo "Name[C]=Uninstall WorkCentre PE220 Series" >> "$APPLNK_FILE" echo "Comment=WorkCentre PE220 Series driver uninstallation script" >> "$APPLNK_FILE" echo "Comment[C]=WorkCentre PE220 Series driver uninstallation script" >> "$APPLNK_FILE" echo "Type=Application" >> "$APPLNK_FILE" # echo "Exec=sh /usr/local/bin/xerox/drivers/$PRINTER_NAME.uninstall.sh" >> "$APPLNK_FILE" echo "Exec=/usr/local/bin/xerox/uninstall -p /usr/local/bin/xerox/drivers -e ./$PRINTER_NAME.uninstall.sh" >> "$APPLNK_FILE" echo "Path=/usr/local/bin/xerox/drivers/" >> "$APPLNK_FILE" echo "Icon=/usr/share/icons/Uninstall.png" >> "$APPLNK_FILE" echo "Terminal=0" >> "$APPLNK_FILE" echo "TerminalOptions=" >> "$APPLNK_FILE" echo "X-KDE-SubstituteUID=false" >> "$APPLNK_FILE" echo "X-KDE-Username=" >> "$APPLNK_FILE" fi done

fi

## System menu ##################################################################################################

# Register $PRINTER_NAME mkdir -p $DRIVERS_REG_DIR if ! grep $PRINTER_NAME $DRIVERS_REG_FILE >/dev/null 2>/dev/null; then echo "$PRINTER_NAME" >> $DRIVERS_REG_FILE fi #mkdir -p $DRIVER_REG_DIR #echo "1.0.1" > $DRIVER_REG_DIR/version #echo "version: 1.0" >> $DRIVER_REG_DIR/version #echo "release: 1" >> $DRIVER_REG_DIR/version cp -f -p --target-directory=$DRIVERS_REG_DIR $PRINTER_NAME.remove # Prepare uninstall scripts echo "#! /bin/sh" > $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh echo "cd \"$DRIVERS_REG_DIR\"" >> $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh echo "sh $PRINTER_NAME.remove now" >> $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh echo "sh mfpcommon.remove now" >> $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh echo "rm -f $PRINTER_NAME.remove" >> $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh echo "read -t 1" >> $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh echo "rm -f $PRINTER_NAME.uninstall.sh &" >> $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh chmod 755 $DRIVERS_REG_DIR/$PRINTER_NAME.uninstall.sh

echo Installation is complete.

#228095

а как через ММС настраивать? научите, если не очень сложно :o

#228105

Файл должен быть текстовый install или readme.
А так запускай на установку install.sh
Распакуй архив, через консоль зайди в эту папку
[console]cd /путь_до_папки[/console]
и запусти установку
[console]./install.sh[/console]

#228282

Огромное спасибо!!! smile Все печатает.Сейчас буду разбираться со сканером :D

#228284

А подскажите в какой папке можно посмотреть какое оборудование установлено и драйвера к нему? Или это не одна папка а вразных по немногу?

#228305

МСС- центр управления мандривой(Настройка компьютера), все там. И принтеры и сканеры и звук и т.д.

#228323

Спасибо! Нашел! :rolleyes:

Войдите или зарегистрируйтесь, чтобы ответить.