openalpr/openalpr — pull request #67 by manupap1 (2014-12-15 02:21:32+00:00)
Title: New folder for debian packaging

This pull request add a new folder `distros/debian` for debian packaging.
I tested it on a clean debian jessie; Here is the instructions I used:

##### Setting of build environnement
```bash
sudo apt-get install build-essential devscripts
```
##### Installation of build dependencies
```bash
sudo apt-get install debhelper git cmake quilt libopencv-dev libtesseract-dev libtesseract-dev libleptonica-dev liblog4cplus-dev libcurl3-dev uuid-dev
```
##### Copy of the debian folder to the right location
A symlink does not work and would raise an error.
```bash
cd openalpr
cp -R distros/debian ./
```
##### Get an upstream source tarball
With previous/obsolete version of debian source format (version 1.0), the dpkg-source program would have build this tarball automatically.
But now with version 3.0, the upstream source tarball shall be built manually or downloaded from the upstream source repository.
So, as suggested by the debian documentation, I added a rule to download and build the tarball from the github repository.
```bash
fakeroot debian/rules get-orig-source
```
##### Package building
```bash
debuild
```
This will build the following packages:
- libopenalpr2 (the core library)
- libopenalpr-data (non-binary data, libopenalpr2 depends on it)
- libopenalpr-dev (the development library, depends on libopenalpr2)
- openalpr (command line program, depends on libopenalpr2)
- openalpr-daemon (daemon, depends on libopenalpr2)
- openalpr-utils (command line tools, depends on libopenalpr2)

##### Notes
I added some patches inside the `patches` directory; these patches are applied at build time by quilt:
- A first patch to enable the build of utility programs (binary names are changed because of common name)
- A second patch to install the static library
- A third patch to build alpr against the shared library