Better dependenceies system.

Signed-off-by: Jakub Sztandera <kubuxu@gmail.com>