meta-facebook: obmc_functions : Add Command script
1. Add Command script to avoid shellcheck fail.
example.
gpioset $(gpiofind line_name)=1
need change to gpioset "$(gpiofind line_name)"=1 to avoid shellcheck
fail but it can't work.
2. Add set_gpio and get_gpio script for all meta-facebook platform
Usage:
set_gpio LINE_NAME SetValue
val="$(get_gpio "LINE_NAME")"
Change-Id: I99cb2e60e29a24a273d0bb9e0cb276106d730b22
Signed-off-by: Peter Yin <peter.yin@quantatw.com>
diff --git a/meta-facebook/recipes-fb/obmc_functions/fb-common-functions_0.1.bb b/meta-facebook/recipes-fb/obmc_functions/fb-common-functions_0.1.bb
new file mode 100644
index 0000000..ab50539
--- /dev/null
+++ b/meta-facebook/recipes-fb/obmc_functions/fb-common-functions_0.1.bb
@@ -0,0 +1,13 @@
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
+
+RDEPENDS:${PN} += " bash"
+
+SRC_URI += " \
+ file://fb-common-functions \
+ "
+
+do_install() {
+ install -d ${D}${libexecdir}
+ install -m 0755 ${WORKDIR}/fb-common-functions ${D}${libexecdir}
+}