Not overriding these variables entirely in the nodejs buildpack allows for it to be easily composable with others that provide dependencies not specifiable in an npm package.json using the heroku-buildpack-multi without having to hack the nodejs buildpack itself.
Preserve ENV vars CPATH and CPPPATH (composable buildpacks)
Thanks for submitting this pull request @davidjrice. I don't see any immediate harm in merging this, but I'd like to better understand your use case first. Can you give a rundown of the multi-buildpack workflow you're using?
The buildpacks used are.
The rough workflow is
The end result is that node-canvas installs gracefully under npm without hacking the library itself.
Thanks for the patch, @davidjrice. It's been merged into the official buildpack! I'd love to see a blog post about how you wired this all together, as I've got some cairo/node-canvas aspirations of my own... 🤘