compile boost under linux without being root [closed] - c++

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking for code must demonstrate a minimal understanding of the problem being solved. Include attempted solutions, why they didn't work, and the expected results. See also: Stack Overflow question checklist
Closed 9 years ago.
Improve this question
how i can compile boost under linux without write in system folders.
I need to get headers files and shared libraries of boost in one my specific folder.

You don't need to be root to compile Boost on Linux. Moreover, many Boost libraries are header only so no compilation is needed. see also Building and Installing the Library and Easy Build and Install for more details.

Related

Cmake linking external libraries [closed]

Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 4 years ago.
Improve this question
How to link external libraries with cmake?
i want to include header files (Liblaries/include)
and link .lib files(Liblaries/lib) + opengl lib.
ADD_LIBRARY(LibsModule
file1.cpp
file2.cpp
)
then add them to a module call LibsModule
target_link_libraries(LibsModule -lpthread)
Please refer to this post:
Adding Libraries with cmake
As an advice please use the "Similar Question Asked" before posting to avoid getting downvoted or being closed as duplicate.
Cheer

What files have to shipped with the actual program? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 5 years ago.
Improve this question
I know these are the include files(in c++) We have to compile them and then have to ship them with the actual binary. But I have a bit strange problem.I used windows.h in a program and I want to ship it but windows.h have other include files and so on.So I would have to ship whole windows sdk in the form of dll's .Is there any other way to do it?
You do not need to ship header files with a binary application.
You do however need to ship any shared libraries (DLL's on Windows) that your program depends on - and this includes the compilers runtime (the standard library etc) - static libraries are made part of the executable and thus do not need to be shipped separately.
If you are using Visual Studio then you need to ship the Visual Studio redistributables along with your program (google the version for your Visual Studio version) - for other compilers there are similar requirements.

Skipping incompatible libpcap.so - cross compilation [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 6 years ago.
Improve this question
I am trying to link libpcap to my project, but I achive an error
skipping incompatible /usr/lib/i386-linux-gnu/libpcap.so when searching for -lpcap
I'm using cross compiler arm linux gcc.
I've found some topics with related problems but i haven't found solution for me.
How to link this lib correctly?
You need to provide libpcap.so built for arm..
You can check for architecture by calling:
file libpcap.so
Output:
/usr/lib/x86_64-linux-gnu/libpcap.so.1.5.3: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=916b377cfe593106dc0b054d63bc4ed0af4ad269, stripped
You can crosscompile the pcap lib from here

Install OpenCV on a C++ compiler [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 7 years ago.
Improve this question
I am used with using OpenCV with python. But does someone have an idea how to add openCV library to a C++ compiler (such DevCpp or CodeBlocks...).
If there is a compiler on which it's easier to install OpenCV library no problem, I have no restriction conserning the compiler.
I followed some tutos on the net but they were not so clear.
Thanks.
C++ has two important phases of compilation. First, each individual .cpp file is needed. You need the library header files (.h) for this. Secondly, the separate parts are linked together, and you need the library files themselves. (.lib/.a depending on platform).
So, you need to provide paths to both. The compiler knows which exact headers are needed from the #include statement, but the libraries to link must be explicitly listed.

C++ Standard for dynamic Libraries on Windows and Linux [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
where can i find examples of how to create one basic c++ project that uses dynamic shared libraries on windows and linux?
I need just of a simple example with one .cpp and .h file for the shared library and one for the program.
This is a very difficult topic. Shared libraries have very different setups and small variations among platforms.
My recommendation is that you use one tool to generate the shared library for you with the appropiate flags.
I recommend you to use one of this, and in this order, if you only want to compile for windows and linux:
WAF
CMake