summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorBruce Richardson <bruce.richardson@intel.com>2014-06-18 21:33:06 +0100
committerThomas Monjalon <thomas.monjalon@6wind.com>2014-06-19 00:57:50 +0200
commit6af52f1134ff4d75fdac7ac88bcb4693643db9ca (patch)
tree6b5f99acee7db7fe23de0a14bf95c41d4e2bf8af /scripts
parentf1445721a98e6204a0e441a08d582cfe9e1843df (diff)
downloaddpdk-6af52f1134ff4d75fdac7ac88bcb4693643db9ca.zip
dpdk-6af52f1134ff4d75fdac7ac88bcb4693643db9ca.tar.gz
dpdk-6af52f1134ff4d75fdac7ac88bcb4693643db9ca.tar.xz
scripts: fix filtering of config comments on bsd
On BSD 10, the cpp binary behaves a little differently and often leaves lines starting with a space before the inital '#' character. This change ensures those lines are filtered out properly. Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/gen-config-h.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/gen-config-h.sh b/scripts/gen-config-h.sh
index 86b41ab..efd7667 100755
--- a/scripts/gen-config-h.sh
+++ b/scripts/gen-config-h.sh
@@ -34,7 +34,7 @@
echo "#ifndef __RTE_CONFIG_H"
echo "#define __RTE_CONFIG_H"
grep CONFIG_ $1 \
-| grep -v '^#' \
+| grep -v '^[ \t]*#' \
| sed 's,CONFIG_\(.*\)=y.*$,#define \1 1,' \
| sed 's,CONFIG_\(.*\)=n.*$,#undef \1,' \
| sed 's,CONFIG_\(.*\)=\(.*\)$,#define \1 \2,' \