comparison gsm-fw/cfgmagic/functions @ 524:11b6ca57a079

gsm-fw/cfgmagic: first rough sketch at L1 configuration
author Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
date Mon, 14 Jul 2014 07:03:53 +0000
parents afceeeb2cba1
children 042c178ebac5
comparison
equal deleted inserted replaced
523:b92febec14aa 524:11b6ca57a079
39 # looks good, proceed 39 # looks good, proceed
40 . "cfgmagic/feature.$1" 40 . "cfgmagic/feature.$1"
41 } 41 }
42 42
43 export_to_c() { 43 export_to_c() {
44 if [ $# != 1 ] 44 while [ $# != 0 ]
45 then 45 do
46 echo "export_to_c: wrong number of arguments" 1>&2 46 case "$c_export_list" in
47 exit 1 47 *" $1 "* | *" $1")
48 fi 48 ;;
49 case "$c_export_list" in 49 *)
50 *" $1 "* | *" $1") 50 c_export_list="$c_export_list $1"
51 ;; 51 ;;
52 *) 52 esac
53 c_export_list="$c_export_list $1" 53 shift
54 ;; 54 done
55 esac
56 } 55 }
57 56
58 export_to_mk() { 57 export_to_mk() {
59 if [ $# != 1 ] 58 while [ $# != 0 ]
60 then 59 do
61 echo "export_to_mk: wrong number of arguments" 1>&2 60 case "$mk_export_list" in
62 exit 1 61 *" $1 "* | *" $1")
63 fi 62 ;;
64 case "$mk_export_list" in 63 *)
65 *" $1 "* | *" $1") 64 mk_export_list="$mk_export_list $1"
66 ;; 65 ;;
67 *) 66 esac
68 mk_export_list="$mk_export_list $1" 67 shift
69 ;; 68 done
70 esac
71 } 69 }
72 70
73 export_to_m4() { 71 export_to_m4() {
74 if [ $# != 1 ] 72 while [ $# != 0 ]
75 then 73 do
76 echo "export_to_m4: wrong number of arguments" 1>&2 74 case "$m4_export_list" in
77 exit 1 75 *" $1 "* | *" $1")
78 fi 76 ;;
79 case "$m4_export_list" in 77 *)
80 *" $1 "* | *" $1") 78 m4_export_list="$m4_export_list $1"
81 ;; 79 ;;
82 *) 80 esac
83 m4_export_list="$m4_export_list $1" 81 shift
84 ;; 82 done
85 esac
86 } 83 }