[tetrapak] fix tetrapak version generation and bugfix to correctly update installed tetrapak on version change

Summary:
- update installed tetrapak on version change
- fix version generation
- check permissions to install tetrapak

Test Plan:
make install, apply chenge and try to install new version.
check that link "your_erlang_path/bin/tetrapak" updated for new version

Reviewers: druss, aschultz

CC: mkraemer, druss, aschultz

Differential Revision: https://review.tpip.net/D1255
[tetrapak] possible to hook tasks on the general task, not only on exact subtasks

Summary:
Sometimes, you need hook tasks not on exact tasks, but on a general task.
Example is, to load pathes of all dependencies should be possible to hook before build:<subtasks>.

Before, if you use hook: run_before, ["build"] and there no exact task with this name, after this change, the hook will
be applied on build:* tasks.

Test Plan: make, you can hook something for testing

Reviewers: vtarasen, orixmann, aschultz

Reviewed By: vtarasen

CC: mkraemer, aschultz

Differential Revision: https://review.tpip.net/D1268