[Turbopack] avoid attaching referenced output assets to chunks (#75933)
### What?
`referenced_output_assets` are different for every chunk group. Attaching them as references to a random chunk in the group causes a different Chunk instance which not only causes duplicate work, but also multiple writes to the same file.
This fixes that by refactoring that and attaching the `referenced_output_assets` higher. Actually it simplifies it.
Closes PACK-4322
Closes PACK-4392