How to build multiplatform projects like net-snmp with MinGW
-
wrote on 17 May 2023, 07:48 last edited by
Hi!
Can somebody explain how build this net-snmp code:
net-snmp
Steps shown at "README.win32" not works. I cant execute configure script. Same trouble with "libsmi" project:
libsmiMy OS: Windows7
Compiler: MinGW + Qt -
Hi!
Can somebody explain how build this net-snmp code:
net-snmp
Steps shown at "README.win32" not works. I cant execute configure script. Same trouble with "libsmi" project:
libsmiMy OS: Windows7
Compiler: MinGW + QtHi and welcome to devnet,
Can you explain in what way is that related to Qt ?
The instructions to build net-snmp are to be run in a terminal not from an IDE. -
wrote on 16 Jun 2023, 06:51 last edited by
These are the steps to achieve the result:
- Download the Net-SNMP library
- Extract it wherever you want
- Download MSYS and install it
- Run MSYS, you will have a bash shell
- Now, locate the mingw compiler on Qt (see the image below)
- On the MSYS bash type these commands:
1. mkdir -p /mingw
2. mount c:/Qt/Tools/mingw730_64 /mingw (the path of the mingw you discovered on point 5.)
3. go to the Net-SNMP source path
4. ./configure –prefix=/mingw –without-openssl –without-perl-modules
5. make
6. make install - Now, in the mingw Qt dir, you should have the Net-SNMP library and tools.
- Edit your .pro files and add this line: win32: LIBS += -L$$PWD/net-snmp/lib/ -lnetsnmp -lws2_32