citusdata / pg_shard

ATTENTION: pg_shard is superseded by Citus, its more powerful replacement
https://github.com/citusdata/citus
GNU Lesser General Public License v3.0
1.06k stars 63 forks source link

Cannot run regression tests when using older GNU sed #91

Closed samay-sharma closed 9 years ago

samay-sharma commented 9 years ago

I was testing pg_shard on RHEL 5.11 and on running make installcheck, all the regression tests failed.

The regression test outputs have the following message :- sed: invalid option -- E.

On some research, it seems that not all versions for sed support the -E option. GNU sed supports -r while BSD sed supports -E. However, it seems that support for -E has been added in later versions of GNU sed. I replaced -E with -r in the launcher.sh script and all the regression tests passed.

Some information about the machine I ran these tests on:

$ uname -r
2.6.18-398.el5xen

$ cat /etc/*-release
Red Hat Enterprise Linux Server release 5.11 (Tikanga)

$ sed --version
GNU sed version 4.1.5
jasonmp85 commented 9 years ago

I might have included that out of caution. It's for enabling "extended" regexes, but as far as I can tell, removing the flag altogether has no effect. I am acutely aware of differences in flags between BSD and GNU variants (grep, sed, make, but sed especially), so tested this on OS X, Ubuntu, and CentOS. But I didn't go back as far as RHEL5… I guess I must have had a newer sed with the BSD compatibility change.

Anyways, if you could test whether removing the flag hurts anything that would be great, since it's an easy way to sidestep this issue.

samay-sharma commented 9 years ago

Tested on Centos 5 and RHEL 5 as regressions were failing on both with -E. On removing the -E flag, all tests passed on both. So, I think we should be fine here.

Just for completeness, this is the new line 32 in my working launcher.sh script. sed -i.bak -e's/^/#/g' -e"\$a\\