Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-5143

fix linking with mongocrypt in node bindings

    • 3
    • Not Needed

      https://github.com/mongodb/libmongocrypt/pull/604

      This PR fixes an issue when installing mongodb-client-encryption with npm install --build-from-source.

      make: Entering directory 'Codes/JavaScript/Clones/mongosh/node_modules/mongodb-client-encryption/build'
        CXX(target) Release/obj.target/mongocrypt/src/mongocrypt.o
        SOLINK_MODULE(target) Release/obj.target/mongocrypt.node
      /usr/bin/ld: cannot find Codes/JavaScript/Clones/mongosh/node_modules/mongodb-client-encryption/deps/lib/libmongocrypt-static.a: No such file or directory
      /usr/bin/ld: cannot find Codes/JavaScript/Clones/mongosh/node_modules/mongodb-client-encryption/deps/lib/libkms_message-static.a: No such file or directory
      /usr/bin/ld: cannot find Codes/JavaScript/Clones/mongosh/node_modules/mongodb-client-encryption/deps/lib/libbson-static-for-libmongocrypt.a: No such file or directory
      collect2: error: ld returned 1 exit status
      make: *** [mongocrypt.target.mk:142: Release/obj.target/mongocrypt.node] Error 1
      make: Leaving directory 'Codes/JavaScript/Clones/mongosh/node_modules/mongodb-client-encryption/build'
      

      Now with this PR when the shared_libmongocrypt npm config is set to true it will link against a system supplied libmongocrypt, otherwise it uses the static libraries from the release build.

            Assignee:
            Unassigned Unassigned
            Reporter:
            neal.beeken@mongodb.com Neal Beeken
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: