Register routes in the block controller

Permalink
I would like to install a block in a package, without caring if I need to add a route for my Ajax controller or any block specific services.
The problem is, that i need to register the route in the on_start function in my package controller. It doesn't work, when I put it in my block controller. Cause it fires to late and all routes are allready initialized.
So now my idea would be, to use the install and uninstall function in the block controller to add and remove the routes directly to the config app.php. what do you think about it? does any body have experience with manipulating the config app.php?

Lemonbrain