lib: xbuddy: Deprecate _Symlink method

Why have class @staticmethod when osutils do trick

BUG=b:258054228
TEST=./run_tests

Change-Id: I55ba4aac34891f9848b912899ab5b782059c887b
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/chromite/+/4062469
Tested-by: Lizzy Presland <zland@google.com>
Auto-Submit: Lizzy Presland <zland@google.com>
Commit-Queue: Lizzy Presland <zland@google.com>
Reviewed-by: Cindy Lin <xcl@google.com>
diff --git a/lib/xbuddy/xbuddy.py b/lib/xbuddy/xbuddy.py
index a0d5de4..f19810e 100644
--- a/lib/xbuddy/xbuddy.py
+++ b/lib/xbuddy/xbuddy.py
@@ -20,6 +20,7 @@
 from chromite.lib import constants
 from chromite.lib import gs
 from chromite.lib import image_lib
+from chromite.lib import osutils
 from chromite.lib import path_util
 from chromite.lib.xbuddy import artifact_info
 from chromite.lib.xbuddy import build_artifact
@@ -617,14 +618,6 @@
                 "Version %s unknown. Can't find on GS." % version
             )
 
-    @staticmethod
-    def _Symlink(link, target):
-        """Symlinks link to target, and removes whatever link was there before."""
-        logging.debug("Linking to %s from %s", link, target)
-        if os.path.lexists(link):
-            os.unlink(link)
-        os.symlink(target, link)
-
     def _GetLatestLocalVersion(self, board):
         """Get the version of the latest image built for board by build_image
 
@@ -714,7 +707,7 @@
         for build_id in build_ids:
             link = os.path.join(self.static_dir, build_id)
             target = os.path.join(self.images_dir, build_id)
-            XBuddy._Symlink(link, target)
+            osutils.SafeSymlink(target, link)
             if self._manage_builds:
                 update_timestamp(self._timestamp_folder, build_id)