If the supply of the two buildings is done via L1/L2/L3/PEN, different qualities of grounding in various buildings can lead to potential differences between the buildings. These can then be equalized through the shielding of the network cable, which can be annoying when touching the devices or can instantly destroy the entire device. I am not an electrician, just a button presser and thinker, but for these reasons, either a potential equalization is created (thick cable between the buildings) or it is made galvanically isolated, i.e., via a short fiber optic segment. However, if the second building is simply connected to the main building via a five-core cable, for example, there are fewer problems in this regard.