@@ -77,24 +77,21 chroot_remove_cc() { | |||
|
77 | 77 | } |
|
78 | 78 | #GPL v2.0 |
|
79 | 79 | #https://github.com/sakaki-/bcmrpi3-kernel-bis/blob/master/conform_config.sh |
|
80 | # edited with thir param | |
|
81 | #start | |
|
82 | 80 | set_kernel_config() { |
|
83 |
|
|
|
84 |
|
|
|
85 |
|
|
|
86 |
|
|
|
87 |
|
|
|
88 |
|
|
|
89 |
|
|
|
90 |
|
|
|
81 | # flag as $1, value to set as $2, config must exist at "./.config" | |
|
82 | local TGT="CONFIG_${1#CONFIG_}" | |
|
83 | local REP="${2//\//\\/}" | |
|
84 | if grep -q "^${TGT}[^_]" .config; then | |
|
85 | sed -i "s/^\(${TGT}=.*\|# ${TGT} is not set\)/${TGT}=${REP}/" .config | |
|
86 | else | |
|
87 | echo "${TGT}=${2}" >> .config | |
|
88 | fi | |
|
91 | 89 | } |
|
92 | 90 | |
|
93 | 91 | unset_kernel_config() { |
|
94 |
|
|
|
95 |
|
|
|
96 |
|
|
|
92 | # unsets flag with the value of $1, config must exist at "./.config" | |
|
93 | local TGT="CONFIG_${1#CONFIG_}" | |
|
94 | sed -i "s/^${TGT}=.*/# ${TGT} is not set/" .config | |
|
97 | 95 | } |
|
98 | 96 | # |
|
99 | #end | |
|
100 | # | |
|
97 |
General Comments 0
Vous devez vous connecter pour laisser un commentaire.
Se connecter maintenant