1

I was trying to use a c library libwebsockets(https://github.com/warmcat/libwebsockets) for my c++ program. I followed the manual and it creates a visual studio solution and it works.

Since I am not used to develop a program on a windows 7 visual studio environment, I am not sure how library works. It looks like solution contains some test codes and core libraries.

In a windows7 environment, what is the best way to develop a C++ project using this this C library?

I am considering two ways which are:

  1. Add the c projects on the c++ project

  2. Add the c++ project on the c projects

Peter Hwang
  • 971
  • 1
  • 12
  • 25

2 Answers2

2

Create two different Projects: One for the C lib and the other for your C++ Code. Then build the C Code into a *.lib File and add it to your C++ Project using this Answer: How to include libraries in Visual Studio 2012?

You can add both Projects into one Solution so they are easily accessible.

Community
  • 1
  • 1
Mailerdaimon
  • 6,003
  • 3
  • 35
  • 46
0

Use CMake utility to create VS project files out of make files.

Alex D
  • 942
  • 1
  • 6
  • 17