fn maybe_lib(
    unit: &Unit,
    state: &mut State<'_, '_>,
    unit_for: UnitFor
) -> CargoResult<Option<UnitDep>>