0. First install the dependency pack:
$sudo Apt-get Install Python-gtk2-dev
Additional packages may be required and are installed as prompted.
1. Install LIBJPEG9, low version Libjpeg8 does not support JPG scan, download jpegsrc.v9.tar.gz and install:
$./configure
$make
$sudo make Install
Or
$sudo Apt-get Install Libjpeg9
2. Install ImageMagick, the high version may appear many unexpected errors, so download imagemagick-6.9.5-7.tar.gz can be:
$./configure
$make
$sudo make Install
Or
$sudo Apt-get Install ImageMagick
3. Install Zbar,zbar-0.10.tar (https://github.com/ZBar/ZBar). Note that the configuration here is critical, or the installation will fail:
$./configure–enable-shared–without-jpeg–without-python–without-gtk–without-qt–without-imagemagick– Disable-video cflags= ""
$make
$sudo make Install
4. Finally, you may need to perform ldconfig to activate the installed library configuration file:
$sudo Ldconfig
5. Test whether the Zbar was successfully installed. You can obtain a two-dimensional code or barcode at will, and then perform the following command to get the scan result:
$zbarimg Xxx.png
$CODE -128:abc-abc-1234
$zbarimg xxx.jpg
$QR-code:http://apk.hiapk.com/m/downloads?
id=com.qq.reader&vcode=11