Merge pull request #3344 from hegdevasant/libflash

openpower/libflash: Use SKIBOOT_VERSION
diff --git a/openpower/package/libflash/Config.in b/openpower/package/libflash/Config.in
index b4f6c7a..247bcc6 100644
--- a/openpower/package/libflash/Config.in
+++ b/openpower/package/libflash/Config.in
@@ -1,5 +1,6 @@
 config BR2_PACKAGE_LIBFLASH
 	bool "libflash"
+	depends on BR2_PACKAGE_SKIBOOT
 	help
 	  Build libflash shared library
 
diff --git a/openpower/package/libflash/libflash.mk b/openpower/package/libflash/libflash.mk
index 6d8e810..c1fe08f 100644
--- a/openpower/package/libflash/libflash.mk
+++ b/openpower/package/libflash/libflash.mk
@@ -4,8 +4,13 @@
 #
 ################################################################################
 
-LIBFLASH_VERSION = v6.5-61-g66ab3cbd
+ifeq ($(BR2_SKIBOOT_CUSTOM_GIT),y)
+LIBFLASH_SITE = $(call qstrip,$(BR2_SKIBOOT_CUSTOM_REPO_URL))
+LIBFLASH_SITE_METHOD = git
+else
+LIBFLASH_VERSION = $(call qstrip,$(BR2_SKIBOOT_VERSION))
 LIBFLASH_SITE = $(call github,open-power,skiboot,$(LIBFLASH_VERSION))
+endif
 
 LIBFLASH_INSTALL_STAGING = YES
 LIBFLASH_INSTALL_TARGET = YES