Package Details: kyocera-sane 2.1.4406-1

Git Clone URL: https://aur.archlinux.org/kyocera-sane.git (read-only, click to copy)
Package Base: kyocera-sane
Description: Kyocera sane scanner support package for many Kyocera printers.
Upstream URL: https://www.kyocera.com/
Licenses: custom
Submitter: MartinX3
Maintainer: dreieck
Last Packager: MartinX3
Votes: 1
Popularity: 0.000000
First Submitted: 2021-06-27 13:28 (UTC)
Last Updated: 2024-01-21 13:43 (UTC)

Pinned Comments

MartinX3 commented on 2021-06-28 19:53 (UTC) (edited on 2021-06-28 20:29 (UTC) by MartinX3)

!!!Important!!!
If your printer supports eSCL or WSD install https://archlinux.org/packages/extra/x86_64/sane-airscan/
(Without it, sane might detect your printer, but scanning will be very buggy and half broken.)
.
Otherwise use this package.

Latest Comments

1 2 Next › Last »

MartinX3 commented on 2024-01-21 13:45 (UTC)

I'm sorry for missing the notification in 2023.
There was no notification email.

Thank you for the information.
This package is now updated and I will orphan it since I don't need it anymore to print and scan with my kyocera.

dreieck commented on 2024-01-21 12:09 (UTC) (edited on 2024-01-21 12:15 (UTC) by dreieck)

Please do not install /etc/udev/rules.d/40-scanner-permissions.rules since it creates overly permissive access permissions for all USB devices! It is not kyocera scanner specific.

Regards and thanks for maintaining!

dreieck commented on 2024-01-21 11:49 (UTC) (edited on 2024-01-21 12:20 (UTC) by dreieck)

Updated PKGBUILD:

# Maintainer:  Martin Dünkelmann <nc-duenkekl3@netcologne.de> (https://aur.archlinux.org/account/MartinX3)
# Contributor: dreieck (https://aur.archlinux.org/account/dreieck)
# Maintainer:  Martin Dünkelmann <nc-duenkekl3@netcologne.de> (https://aur.archlinux.org/account/MartinX3)

pkgname=kyocera-sane
pkgver=2.1.4406
pkgrel=1
pkgdesc='Kyocera sane scanner support package for many Kyocera printers.'
arch=(
  'i386'
  'i486'
  'i586'
  'i686'
  'x86_64'
)
url='https://www.kyocera.com/'
license=('custom')
depends=(
  'freeimage'
  'gcc-libs'
  'glibc'
  'libtiff5'
  'libusb'
  'libjpeg'
  'openssl-1.1'
  'sane'
)
makedepends=()
source=(
  'https://www.kyoceradocumentsolutions.de/content/download-center/de/drivers/all/SANE_Driver_zip.download.zip'
  'README.txt'
)
sha256sums=(
  '6729c68ab90a1e8f4edef3fc4a35942e965cbded11d4d51b7a897bc98eb02fae'
  '945f922065e8278d2ec6e0c1e8ce6851834359cd02ff85534fa3d7baccec6ffe'
)

prepare() {
    cd "${srcdir}"
    mkdir -p build
    case "${CARCH}" in
      'i386'|'i486'|'i586'|'i686')
        bsdtar xvf "${pkgname}_${pkgver}_i386.deb"
      ;;
      'x86_64')
        bsdtar xvf "${pkgname}_${pkgver}_amd64.deb"
      ;;
    esac
    bsdtar xvf "${srcdir}/data.tar.xz" -C "${srcdir}/build"
}

build() {
  cd "${srcdir}/build"

  # From .deb postinst
  install -dvm755 "etc/sane.d/dll.d"
  touch "etc/sane.d/dll.d/kyocera.conf"
  printf '%s\n' 'kyocera'          >> "etc/sane.d/dll.d/kyocera.conf"
  printf '%s\n' 'kyocera_gdi_a3'   >> "etc/sane.d/dll.d/kyocera.conf"
  printf '%s\n' 'kyocera_wc3'      >> "etc/sane.d/dll.d/kyocera.conf"
  printf '%s\n' 'kyocera_wc3_usb'  >> "etc/sane.d/dll.d/kyocera.conf"

  chmod 644 "etc/sane.d"/*.conf
  chmod 644 "etc/sane.d/dll.d"/*.conf

  # Move UDEV rule do documentation, since it creates overly persmissive permissions.
  mv -v "etc/udev/rules.d/40-scanner-permissions.rules" "usr/share/doc/${pkgname}"/
  chmod 644 "usr/share/doc/${pkgname}/40-scanner-permissions.rules"
  rmdir -v "etc/udev/rules.d"

  # Move the license into place.
  install -Dvm644 "usr/share/doc/${pkgname}/copyright" "usr/share/licenses/${pkgname}/COPYRIGHT"
  rm "usr/share/doc/${pkgname}/copyright"

  # Clean unnecessary files.
  case "${CARCH}" in
    'i386'|'i486'|'i586'|'i686')
      rm -r "usr/lib/i386-linux-gnu"
    ;;
    'x86_64')
      rm -r "usr/lib/x86_64-linux-gnu"
    ;;
  esac
  rm -r "usr/local"
}

package() {
  cd "${srcdir}/build"

  # Move files into place
  cp -rv * "${pkgdir}"/

  install -Dvm644 -t "${pkgdir}/usr/share/doc/${pkgname}" "${srcdir}/README.txt"
}

dreieck commented on 2024-01-21 11:40 (UTC) (edited on 2024-01-21 11:45 (UTC) by dreieck)

According to namcap, freeimage and openssl-1.1 are dependencies, but openssl-1.0 and libtiff4 not anymore:

kyocera-sane E: Dependency freeimage detected and not included (libraries ['usr/lib/libfreeimage.so.3'] needed in files ['usr/lib/sane/libsane-kyocera_gdi_a3.so.1.0.24'])
kyocera-sane E: Dependency openssl-1.1 detected and not included (libraries ['usr/lib/libcrypto.so.1.1', 'usr/lib/libssl.so.1.1'] needed in files ['usr/lib/libkmadrwapi.so', 'usr/lib/libkmcmnapi2.so', 'usr/lib/sane/libsane-kyocera_wc3.so.1.0.24'])

Also, libjpeg and libtiff5 are needed dependencies!

Regards and thanks for maintaining!

dreieck commented on 2024-01-21 11:19 (UTC)

data.tar.gz must be changed to data.tar.xz.

dreieck commented on 2024-01-21 11:18 (UTC)

wget is not used, please remove it from makedepends.

dreieck commented on 2024-01-21 11:17 (UTC)

unzip -o SANE_Driver_zip.download.zip is not needed. The zip source file will be extracted automatically via bsdtar after download. Then, unzip can also be removed from makdepends.

dreieck commented on 2024-01-21 11:16 (UTC)

The commend # fix licence warning should be changed to # install license. Since actually it is not about fixing an annoying warning, but to do something that is required.

dreieck commented on 2024-01-21 11:14 (UTC)

Please quote "${srcdir}" and "${pkgdir}", since they might contain whitespace for example.

dreieck commented on 2024-01-21 11:03 (UTC)

Can you please remove the executable permission from several configuration files of your package:

  • /etc/sane.d/kyocera.conf
  • /etc/sane.d/kyocera_devices.conf
  • /etc/sane.d/kyocera_gdi_a3.conf
  • /etc/sane.d/kyocera_wc3.conf
  • /etc/sane.d/kyocera_wc3_usb.conf
  • /etc/udev/rules.d/40-scanner-permissions.rules

(use -m 644 as argument to the install command.)

Regards and thanks for maintaining!