From e002798e8f85b67d67d34326b32f838541827bc5 Mon Sep 17 00:00:00 2001 From: "Kaleb S. KEITHLEY" Date: Thu, 8 Sep 2016 08:08:15 -0400 Subject: rpc/xdr: use ordinary regex to sed filter generated files Versus an extended regex While NetBSD and FreeBSD's sed has compat -r command line option, Mac OS X's sed does not. And there's no need to use an extended regex here; avoiding extra logic to determine whether running on Linux or *BSD. Change-Id: I6089f994f6c4f50eb353fc018b1b678ec93d6626 BUG: 1374280 Signed-off-by: Kaleb S. KEITHLEY Reviewed-on: http://review.gluster.org/15429 Smoke: Gluster Build System CentOS-regression: Gluster Build System NetBSD-regression: NetBSD Build System Reviewed-by: Niels de Vos --- build-aux/xdrgen | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'build-aux') diff --git a/build-aux/xdrgen b/build-aux/xdrgen index 010df656377..2d808d235ec 100755 --- a/build-aux/xdrgen +++ b/build-aux/xdrgen @@ -75,7 +75,7 @@ gen_headers () rm -f $hfile; rpcgen -h -o $hfile $xfile; # the '#ifdef' part of file should be fixed - sed -r -e '/#(ifdef|ifndef|define)/s/-/_/g' $hfile > ${hfile}.new && mv ${hfile}.new $hfile; + sed -e '/#ifndef/ s/-/_/g' -e '/#define/ s/-/_/g' -e '/#endif/ s/-/_/' $hfile > ${hfile}.new && mv ${hfile}.new $hfile; # Gen header to temp file and append generated file append_licence_header $hfile $tmp_hfile; # now move the destination file to actual original file -- cgit