This is a HUGE bug!  We just updated our operating systems where I work from RHEL 6.4 to 6.10 resulting in a grep update from 2.6.3-3 to 2.20-6 and this broke our build scripts.  After searching google all day trying to figure out what was causing our problems, I found this bug was introduced in 2.12:

https://unix.stackexchange.com/questions/184200/grep-exclude-dir-behaviour-a-bug-or-a-feature

Can grep 2.6.3-3 be used with RHEL 6.10 to resolve our issue in the meantime?