Git Product home page Git Product logo

Comments (5)

COM8 avatar COM8 commented on August 27, 2024

@Chrys4lisfag thanks for reporting. I'm not a Windows dev working with msvc so my knowledge here is limited.
Here is a full example for using cpr in CMake even on Windows: https://github.com/libcpr/example-cmake-fetch-content

This can be taken as starting point.

from cpr.

Chrys4lisfag avatar Chrys4lisfag commented on August 27, 2024

@Chrys4lisfag thanks for reporting. I'm not a Windows dev working with msvc so my knowledge here is limited. Here is a full example for using cpr in CMake even on Windows: https://github.com/libcpr/example-cmake-fetch-content

This can be taken as starting point.

Yeah, I've got no issues with cmake project. The only issue when I've build cpr as static library and tried to link it to my msvc project. It had crt linking type mismatch between cpr.lib and my msvc project, so I had to modify cpr library CmakeLists by adding "set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$CONFIG:Debug:Debug>")" this line to make it work.

from cpr.

kevinmoloney7 avatar kevinmoloney7 commented on August 27, 2024

@Chrys4lisfag How did you add this I am facing the same issue. I am using cmake fetch content to include cpr in my project. Where did you include set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$CONFIG:Debug:Debug>

from cpr.

Chrys4lisfag avatar Chrys4lisfag commented on August 27, 2024

@Chrys4lisfag How did you add this I am facing the same issue. I am using cmake fetch content to include cpr in my project. Where did you include set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$CONFIG:Debug:Debug>

I've added this directly in the cpr`s CMakeLists then built cpr library as static (-DBUILD_SHARED_LIBS=OFF) and used output .lib and includes in my project

from cpr.

COM8 avatar COM8 commented on August 27, 2024

Closing this one as there seams no action required from the cpr side here.

from cpr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.