diff --git a/meta-oniro-staging/recipes-devtools/gn/gn_git.bb b/meta-oniro-staging/recipes-devtools/gn/gn_git.bb
index 166b319cff8b3ceb281497a6b7e06b3825aa4299..eb782d078aaa52fd902d6ef6cf9bb878cc5c592c 100644
--- a/meta-oniro-staging/recipes-devtools/gn/gn_git.bb
+++ b/meta-oniro-staging/recipes-devtools/gn/gn_git.bb
@@ -1,6 +1,4 @@
 SUMMARY = "GN is a meta-build system that generates build files for Ninja"
-DEPENDS += "ninja-native"
-
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=0fca02217a5d49a14dfe2d11837bb34d"
 
@@ -11,6 +9,8 @@ PV = "0+git${SRCPV}"
 S = "${WORKDIR}/git"
 B = "${WORKDIR}/build"
 
+inherit ninja
+
 # Currently fails to build with clang, eg:
 # https://errors.yoctoproject.org/Errors/Details/610602/
 # https://errors.yoctoproject.org/Errors/Details/610486/