linking libcurl in Visual Studio 8 - visual-studio

I have a C project needed to be compiled into a DLL.
This C project includes . I had compiled a libcurl.dll from source with VS2008.
I put the libcurl.dll in C:\Windows\System32 (I suppose this serves as installing the DLL)
Now, when I compile my own C project, it says 'cannot open include file curl/curl.h'.
Did I miss any steps? Sorry I'm really new to Windows system.
Thanks in advance!

You need to add the path to curl/curl.h as an additional include directory in your project settings. Right click on the project, go to properties, and it's under the compiler section.
You'll also need to add curl.lib as a input library under your linker settings.

Related

Including the Expat library in Visual Studio 2013

I've downloaded a copy of Expat 2.0.1, which is basically a bunch of .h and .c files (see the complete directory in the screenshot below).
To add the library to the VS 2013 project I'm working on, I went to Properties -> Configuration Properties -> VC++ Directories and added the path of the 2.0.1 folder shown in the screenshot to the "Include Directories" field. This gets rid of all the intellisense errors, but when I build the project I get a bunch of linker errors that are complaining about unresolved symbols (eg XML_ParserCreate, which is a function from the Expat library). I can right-click on these symbols and peek the definition, so it seems like everything is "hooked up" correctly. How can I get the linker to stop complaining? There doesn't seem to be any libraries I can add to the Linker section of the configuration. Do I need to use Makefile.MPW somehow?
This is just the source, you have to create the library yourself, see MicrosoftDocs. BTW MPW is a Mac file.

openRTMFP cumulus how to compile and install

i've just downloaded cumulus, POCO, OpenSSL and LuaJIT and visual studio. now i'm trying to compile it as it said in instruction here
however i've never used visual studio and i've never programed on visual c. so i'm stuck at the very begining.
in instruction i've put link above said "Visual Studio 2008/2010 solution and project files are included. It searchs external librairies in External/lib folder and external includes in External/include folder in the root Cumulus folder. So you must put POCO, OpenSSL and LuaJIT headers and libraries in these folders.". i tryed everything but compiler can't find 'Poco/foundation.h'.
and it seems to me if i deal with this error there will more over.
so if someone has expirience in compiling cumulus-server please help me to deal with it.
thanks a lot for you help!
step 1 - create 2 files
cumulus_root_folder/external/lib
cumulus_root_folder/external/include
step 2 - put the headers into the include folder from the other 3 dependent projects
dependent projects are: openssl, poco, luajit.
put openssl file into the external/include from openssl-version/include
put Poco file into the external/include from poco-version/Foundation/include
put SAX, DOM, XML files into the external/include/Poco from poco-version/XML/include/Poco
put Net file into the external/include/Poco from poco-version/Net/include/Poco
put Util file into the external/include/Poco from poco-version/Util/include/Poco
put LuaJIT's headers with the same way.
now you can build cumuluslib.
step 3 - Open your cumuluslib project with specific visual studio version then build it.
When it's done you can see the lib file at cumulus_root_folder/cumuluslib/lib
step 4 - now you have to build the 3 dependent projects and put their lib files to cumulus_root_folder/external/lib its tough mission, maybe you will need 32-bit windows. Do not forget: when you building poco, do it with debug if not, some of your files will be missing.
When you done with building and gathering lib files you can build cumulusserver. Same way as cumuluslib. Then your cumulus.exe will be in cumulus_root_folder/cumulusserver/debug

Trouble building Boost Libraries

OS: Win7
IDE: Visual Studio 2010 Professional
Boost Lib Version: 1.47
Downloaded "boost_1_47_setup.exe" installer from http://www.boostpro.com/download/
Initially installed everything for VS 10, then just checked every box (5+ GB install!)
Added the "boost\boost_1_47" path into "Additional Include Directories" in C++->General
Copy/Pasted code from "Getting Started on Windows: 4 - Build a Simple Program Using Boost"
Compiled without issue
Included boost/regex.hpp and re-compiled
Received Error:
LINK : fatal error LNK1104: cannot open file 'libboost_regex-vc100-mt-gd-1_47.lib'
Expected, haven't built the binaries yet.
Ran "Visual Studio Command Prompt" from tools folder in my VS 10 installation as admin
cd'ed to boost root
Ran bootstrap.bat from command line
Received Error:
Building Boost.Build engine
The system cannot find the path specified.
'.\build.bat' is not recognized as an internal or external command,
operable program or batch file.
Failed to build Boost.Build engine.
Please consult bootstrap.log for furter diagnostics.
Everything I did came from the Getting Started page on Boost.org. Not sure if its just dated or if I'm doing something wrong.
Came here looking for answers, found some similar issues, namely the following:
Problem with C++ Boost installation (can't find file) in VC++ 2010
Problem with C++ Boost installation (can't find file) in VC++ 2010
Boost C++ Libraries linker error libboost_serialization-vc100-mt-gd-1_47.lib
Boost C++ Libraries linker error libboost_serialization-vc100-mt-gd-1_47.lib
No dice. Any help would be appreciated. Thanks
The compiler cannot find the BOOST's library file. To fix the issue you have to find on your computer the libboost_regex-vc100-mt-gd-1_47.lib file and add its folder path to the Project->YourProjectName Properties (Alt+F7)->Configuration Properties->Linker->General->Additional Library Directories. After recompile your project.
This is the answer to the above comment of #Johnny 5....thousand. In VS10 the compiler-wide additional libraries are deprecated. I solved the problem by adding a new project property sheet to all my projects. It is possible to do it by calling the Property Manager Tab (View->Property Manager). In the Property Manager Tab is necessary to click right mouse button on the project, select Add New Project Property Sheet, Save the sheet to a well-known place. After to define a new User Macro - Name:BOOST, Value: Your Boost Path, for example c:\boost_1_47_0\, also add the $(BOOST) to the Additional Include Directories and ad the $(BOOST)\lib to the Additional Library Directories. That's all. For all other projects is required to add existing property sheet.

Visual Studio 2010 can't see /bin library of OpenCV

I'm trying to use OpenCv 2.2 in Visual Studio 2010.
I've configured everything by instruction:
http://opencv.willowgarage.com/wiki/VisualC%2B%2B
and by instruction from the book:
So I've added all /lib and /include paths.
When I build project, it compiles and before starting app, VS displays an error message that opencv_core220d.dll is missing.
This file is in C:/OpenCV2.2/bin as all .dll files. If I add this file to my working directory - it will be fine. Then VS displays error about every .dll file that I added in Linker-Input configuration ( but with .lib extension ).
So, if I add all .dlls file that I've added as .lib in Linker configuration - to my working directory, project will start.
But why? Why VC doesn't see OpenCV2.2/bin folder? Where is this pointed?
Because it doesn't know to look there by default. However, it does know to check the current directory for the DLLs.
You can tell it where to look by adding C:/OpenCV2.2/bin to your Path variable, or if you would rather not muck up your global Path you can set the Environment variable local to the C++ project.
I think that is the syntax for appending to the Path in VS2010, but I'm not sure, so Google it if that doesn't work :)

How to exclude .lib file from linker command line argument in VC++

I am compiling a vc++ program which is showing below error
error LNK1104: cannot open file 'D:\Visual Studio 2010\Projects\credentialproviders\Win32\Debug\Helpers.lib'
how i can remove that Helpers.lib file reference from linker command line argument because in project settings->linker->commandline its in readonly mode and I can't edit this to remove that line. I am using Visual Studio 2010.
thanks
Search the .vcproj file, and the project source code for "Helpers.lib". There are a couple places it can get linked in, and this is the simplest way to find it.
Otherwise, look for:
Project properties -> linker -> inputs
In the solution explorer, see if the .lib is included anywhere in the project tree.
Anywhere in the source code, #pragma comment(lib, "helpers.lib")
If Helpers is a project in your solution, check project dependencies for the project. By default, thisk linking is done implicitly if the project depends on it.
if this lib is not referenced in Linker->Input->Additional Dependencies, so check Project Dependencies, and remove any dependency on porject Helpers. also it's possible that this linking is done from code by #pragma comment(lib, "Helpers)
I don't really think the above answers it properly. I just had this same problem and the way to fix it is to go to View->Property Manager. double click Microsoft.Cpp.Win32.user and go to Linker->Input. There you can edit out the additional dependencies that were previously read only. Do it for both debug/release versions if needed.

Resources