How to build leaky weirs