Different rear ends have different length pinion shafts. A 8.2 Chevy 10 bolt has a short pinion compared to a 8.5 GM 10 bolt. A Dana 60 has a long pinion shaft and a 9 inch Ford has a short pinion shaft. So the distance from the center of the axle tube to the U joint mounting surface is going to be different for each different rear end. The rear end in your picture is a 7.5 GM 10 bolt, which has a short pinion shaft. If you are going to replace a 7.5 10 bolt with a 7.5 10 bolt then the drive shaft will not change. If you are replacing the 7.5 10 bolt with a Dana 60 then the drive shaft will be too long. The only way to tell what length drive shaft you will need is to install the rear end in the correct location and then measure for the correct drive shaft length.
The most common U joints are the 1310, 1330, 1350 and the 3R. If your drive shaft has a 1310 U joint and the yoke on the rear end you are using takes a 1330 U joint then you are going to have to modify the drive shaft or get an adapter U joint.