[Feature]add MT2731_MP2_MR2_SVN388 baseline version
Change-Id: Ief04314834b31e27effab435d3ca8ba33b499059
diff --git a/meta/poky/scripts/wimac_rul.sh b/meta/poky/scripts/wimac_rul.sh
new file mode 100755
index 0000000..746d366
--- /dev/null
+++ b/meta/poky/scripts/wimac_rul.sh
@@ -0,0 +1,36 @@
+#!/bin/bash
+#
+# @author Howard Chen
+# @brief if the input file violate rules, return 1, else 0
+#
+
+if [ $# != 1 ] || [ ! -f $F ] || [ ! ${F##*.} = "c" ]
+then
+ echo "usage: wimac_rul.sh <c_source>"
+ exit 1
+fi
+
+
+F=$1
+CMD_P=$(cat -n $F | grep @nostrict-g)
+if [ "$CMD_P" != "" ]
+then
+ echo "[PASS]: $F"
+ exit 0
+fi
+
+LINES=$(cat -n $F | sed -e /@nostrict/d | sed -e /\#include/d | gcc -E - | grep extern | sed -e /@nostrict/d )
+
+if [ "$LINES" != "" ]
+then
+ echo ""
+ echo ""
+ echo "[FAIL]: $F"
+ echo "$LINES"
+ echo "--------------------------------------------------------------------------------"
+ exit 1
+else
+ echo "[PASS]: $F"
+ exit 0
+fi
+