add a BlockingCounter (semaphore like behaviour)
TEST: unit test set for the BlockingCounter template
replace mutex/conditinals craft in AsyncReader by BlockingCounter
TEST: unit test for thread waiting on AsyncReader
FIX: unit test on OS X
Merge pull request #320 from reneme/blocking_counter

Refactor Cumbersome Synchronisation in AsyncReader