build: don't bundle deps/zlib if --shared-zlib set
Even if the --shared-zlib flag was used, the bundled deps/zlib was still being compiled into the binary as it was required by the C++ test suite.
Fixes: https://github.com/nodejs/node/issues/10649
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
commit message follows commit guidelines
Affected core subsystem(s)
build, zlib
cc/ @bnoordhuis