configure: Move log2 dependency declaration to a place it takes effect