gyp: float gyp patch for long filenames
gyp: float gyp patch for long filenames

Pulling in https://codereview.chromium.org/2019133002/ in its current
state, as gyp seems to be largely abandoned as a project.

Original commit message:

    Hash intermediate file name to avoid ENAMETOOLONG

    Hash the intermediate Makefile target used for multi-output rules
    so that it still works when the involved file names are very long.

    Since the intermediate file's name is effectively arbitrary, this
    does not come with notable behavioural changes.

    The `import hashlib` boilerplate is taken directly
    from `xcodeproj_file.py`.

Concretely, this makes the V8 inspector build currently fail when long
pathnames are involved, notably when using ecryptfs which has a lower
file name length limit.

Fixes: https://github.com/nodejs/node/issues/7959
Ref: https://github.com/nodejs/node/issues/7510
PR-URL: https://github.com/nodejs/node/pull/7963
Reviewed-By: Sakthipriyan Vairamani <b84950071fc99921a72f4fa56f6cad2496b3223c@gmail.com>
Reviewed-By: Ben Noordhuis <59bd0a3ff43b32849b319e645d4798d8a5d1e889@bnoordhuis.nl>
Reviewed-By: James M Snell <2d64a127ffc94dbe6295928a16bedf8b26814159@gmail.com>
Reviewed-By: Saúl Ibarra Corretgé <8a7991f6950ea189abf159d6ec98d2fcc13dc5f6@gmail.com>

nodegit/node-gyp,nodegit/node-gyp,nodejs/node-gyp,nodejs/node-gyp,nodegit/node-gyp,nodegit/node-gyp,nodegit/node-gyp,nodejs/node-gyp,nodejs/node-gyp,nodejs/node-gyp