Installed Cygwin64 and cannot find unresolved inclusion in <iostream> when in eclipse - c++

I linked to as many of the libraries as I can find and still I get an unresolved inclusion for <iostream> in eclipse. I even searched the c:\cygwin\ directory for iostream and I cannot find it. So, how do I find this basic library in the cygwin64 installation?

The default installation for Cygwin is quite minimal. In particular, it doesn't include software development tools.
Re-run the Cygwin setup.exe program and add gcc-g++ to your system. (It is in the Devel category on the Select Packages screen.) This will add the C++ compiler and Standard C++ library.

Related

Cannot include external C++ libraries using vcpkg Viual Studio Code

I am new to making c++ projects (I just know the programming language), I am trying to make a c++ project and want to import the sqlite3 module in c++ using vcpkg.
I have successfully installed vcpkg and installed the libraries using vcpkg install sqlite3.
I have also used the vcpkg integrate install command to make it readily available to all kinds of c++ projects.
But my VS Code is not able to locate the required header file sqlite3.h when I try to include it in my main.cpp file.
I have checked the include-path settings of VS code and have already added the vcpkg include path in it but the problem still persists.
I tried to change the compilers paths many times but the problem still exists.
My compilers include: msys-g++, LLVM-clang++, and Microsoft-msvc.
I tried googling a lot but couldn't find a proper solution to my issue.
I find it very difficult to import any other packages/libraries in my project due to this reason as c++ does not have properly maintained package managers like npm, pub, or pip.

lapack complains about libgcc_s_sjlj-1.dll

I am trying to write a program that uses armadillo in Visual Studio. I downloaded Prebuilt libraries for lapack and blas from http://icl.cs.utk.edu/lapack-for-windows/lapack/. I also downloaded MinGW and added C:/MinGW/bin to my System PATH. C:/MinGW/bin has libgfortran-3.dll and libgcc_s_dw2-1.dll which are what the lapack documentation states is needed. However, when I attempt to run my program I get a runtime error stating that the program can't run because libgcc_s_sjlj-1.dll is missing. This dll does not come with MinGW and I tried downloading multiple versions. How can I get rid of this error?
The MinGW-w64 project have something called "personal builds". One of them is "sjlj". The library is built using a gcc compiler from this personal build.
Assuming that it was used the current latest version (6.3.0) and win32 threads the you can find the toolchain binaries here. If not, you can check some other versions.
You can either extract the dll you need or extract it and add it to your system path.

Installing GLFW from source on Windows

I am trying to install GLFW for use in Eclipse. I am using MinGW and am on Windows 7 64-bit. I tried to install GLFW using the pre-compiled binaries, but that did not work, as I could not build projects with it.
I installed CMake and follwed the instructions on http://www.glfw.org/docs/latest/compile.html. I used CMake and it seemed to have worked, giving me a Makefile. Then I used mingw32-make to make it.
However, I am confused as to where the library files are, if there even are any. I was also under the impression that I needed a .dll file to use an external library. If anyone could help me through past this point that would be greatly appreciated
So what I did was right. All I needed to do was to link the libraries, which can be found in {%PATH_TO_GLFW%}/src. The name of the library is glfw3.

ubuntu: including boost to eclipse CDT when installed from Aptitude

I am new to both C++ and eclipse and I am trying to use smart pointers.
I installed boost using aptitude:
sudo apt-get install libboost-all-dev
then in my eclipse project I added "boost" to
/ properties / c/c++build / settings / cross G++ linker / Libraries /
now in my C++ I try to include smart pointers:
#include <boost/smart_ptr.h>
but I am told : unresolved inclusion: boost/smart_ptr.h
I am really not sure why. From my (limited) understanding, I should not need to look for the path to to the libboost and to the include path of the compiler. I based this on the fact that I included other libraries installed by aptitude and I could include them in my code directly.
Sounds like a basic question, but all the threads I could find were either about windows, or about boost being downloaded and manually compiled (in which case I understand the path has to be given to the compiler).
Anything I am missing ?
Thx a lot

Compiling libpng and using it with netbeans and mingw

I have only previously used visual studio for developing c++ but I've just moved to netbeans and am having some issues.
I got mingw installed so that my projects will compile but I dont know how to add external libraries to that. I want to use a static library, not a dll.
The library I specifically am looking at is libpng
I hope this isn't too IDE specific, I'm also looking to know how to prepare the library.
Windows OS.
I figured it out more or less. I used the cmake gui, configured for msys make and mingw g++ and gcc, on the zlib source directory and then ran msys make and make install on the output directory. After that I did the same on libpng, but I had to add some variables to point to the zlib include and library directories within cmake.
Then in netbeans, I right clicked>>properties on my project and added include and lib location for each of the two libraries. I also could have copied the files into my mingw directories.
Now I'm just stuck with this issue.