initial commit
This commit is contained in:
commit
0c7ea419db
20 files changed
+102
No files matched your search
Generated
+2
@@ -0,0 +1,2 @@
|
||||
# Default ignored files
|
||||
/workspace.xml
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<settings>
|
||||
<option name="USE_PROJECT_PROFILE" value="false" />
|
||||
<version value="1.0" />
|
||||
</settings>
|
||||
</component>
|
||||
Generated
+4
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.6" project-jdk-type="Python SDK" />
|
||||
</project>
|
||||
Generated
+8
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/.idea/tesseract-box.iml" filepath="$PROJECT_DIR$/.idea/tesseract-box.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
||||
Generated
+8
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="PYTHON_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<content url="file://$MODULE_DIR$" />
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
||||
Vendored
+40
@@ -0,0 +1,40 @@
|
||||
# encoding: utf-8
|
||||
# -*- mode: ruby -*-
|
||||
# vi: set ft=ruby :
|
||||
|
||||
Vagrant.configure("2") do |config|
|
||||
config.vm.box = "generic/debian10"
|
||||
config.vm.box_check_update = false
|
||||
|
||||
config.vm.provider :virtualbox do |vb|
|
||||
vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
|
||||
# Display the VirtualBox GUI when booting the machine
|
||||
# vb.gui = true
|
||||
|
||||
# Customize the amount of memory on the VM:
|
||||
vb.memory = "4096"
|
||||
|
||||
# Use 1 CPUs
|
||||
vb.cpus = 4
|
||||
end
|
||||
|
||||
config.vm.network "forwarded_port", guest: 8000, host: 8001, auto_correct: true
|
||||
config.vm.network "forwarded_port", guest: 80, host: 81, auto_correct: true
|
||||
config.vm.network "forwarded_port", guest: 5000, host: 5001, auto_correct: true
|
||||
|
||||
config.vm.synced_folder ".", "/vagrant"
|
||||
|
||||
config.vm.provision "shell", privileged: true, path: "./provision.sh"
|
||||
|
||||
# Error:
|
||||
# [default] GuestAdditions seems to be installed (5.1.38) correctly, but not running.
|
||||
# @see solution from: https://github.com/dotless-de/vagrant-vbguest/issues/333#issuecomment-487105544
|
||||
if Vagrant.has_plugin?("vagrant-vbguest")
|
||||
config.vbguest.auto_update = false
|
||||
end
|
||||
|
||||
# Enable X11 forwarding for graphical apps.
|
||||
# Make sure you have xquartz installed if using OSX host!
|
||||
config.ssh.forward_agent = true
|
||||
config.ssh.forward_x11 = true
|
||||
end
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,34 @@
|
||||
echo "%vagrant ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/vagrant
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
export PATH=$PATH:/home/vagrant/local/bin
|
||||
|
||||
# зависимости
|
||||
apt-get update
|
||||
apt-get install -y htop nano libsm6 libxext6 libxrender-dev \
|
||||
libicu-dev libpango1.0-dev libcairo2-dev g++ autoconf automake \
|
||||
libtool pkg-config libpng-dev libjpeg62-turbo-dev libtiff5-dev \
|
||||
zlib1g-dev libicu-dev libleptonica-dev
|
||||
|
||||
# Устанавливаем чертежные шрифты в систему
|
||||
export FONTS_DIR=/usr/local/share/fonts
|
||||
echo "export FONTS_DIR=$FONTS_DIR" >> /home/vagrant/.bashrc
|
||||
cp /vagrant/fonts/* $FONTS_DIR
|
||||
chmod -R 644 $FONTS_DIR
|
||||
fc-cache -v
|
||||
|
||||
# скачиваем и собираем tesseract 4.1.1
|
||||
cd /
|
||||
wget https://github.com/tesseract-ocr/tesseract/archive/4.1.1.tar.gz
|
||||
tar -zxvf 4.1.1.tar.gz
|
||||
cd /tesseract-4.1.1 || exit 1
|
||||
mkdir -p $HOME/local/include $HOME/local/lib/pkgconfig
|
||||
export PKG_CONFIG_PATH=$HOME/local/lib/pkgconfig
|
||||
./autogen.sh
|
||||
LIBLEPT_HEADERSDIR=$HOME/local/include ./configure \
|
||||
--prefix=$HOME/local/ --with-extra-libraries=$HOME/local/lib
|
||||
make
|
||||
make install
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user