minio / minio-cpp

MinIO C++ Client SDK for Amazon S3 Compatible Cloud Storage
https://minio-cpp.min.io/
Apache License 2.0
139 stars 56 forks source link

Undefined reference to symbol 'crc32' #160

Closed Nikolaycc closed 3 months ago

Nikolaycc commented 3 months ago

When i link library and compile project throw error

/usr/bin/ld: /usr/local/lib/libminiocpp.a(utils.cc.o): undefined reference to symbol 'crc32'
/usr/bin/ld: /usr/local/lib/libmongoc-1.0.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make: *** [Makefile.x86_64:57: bin/Release/HadranielEdge] Error 1

Inspect libminiocpp.a

$ nm /home/octarinox/Documents/minio-cpp/build/Release/libminiocpp.a | grep crc32
                 U crc32
balamurugana commented 3 months ago

You would need to have below dependencies

  "dependencies": [
    { "name": "curlpp" },
    { "name": "inih", "features": ["cpp"] },
    { "name": "nlohmann-json" },
    { "name": "openssl" },
    { "name": "pugixml" },
    { "name": "zlib", "platform": "windows" },
    { "name": "vcpkg-cmake", "host": true },
    { "name": "vcpkg-cmake-config", "host": true }
  ]

Additionally, use vcpkg to build your project