Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

C 

about IncludePath for MinGW-w64 cross-compiler and VSCode

Hello,

About a year ago I worked successfully with
MinGW-w64 cross-compiler and VSCode on Kali Linux.I use C ++.
At that time I used  MinGW directory:  /usr/lib/gcc/x86_64-w64-mingw32/
Now this directory is currently down.
To install MinGW64 I use the following command:
apt-get install mingw-w64-common mingw-w64-i686-dev mingw-w64-tools mingw-w64-x86-64-dev
The compiler is now installed in the /usr directory and is not working properly!
Please if anyone knows the solution to this problem share it.
Thanks.
You could elaborate on -> not working properly.
May you be given directions by software engineer document writers.
finds header`s but does not find functions.


For example:


#include <winsock2.h> //OK
#include <windows.h> //OK
#include <ws2tcpip.h> //OK
#include <stdio.h> //OK


but can't find the functions : for example

if (32 >= (int)(ShellExecute(NULL,"open", ..... // No
GetUserName(returnval, &bufferlen); // No
GetComputerName(returnval, &bufferlen); // No

There is my : c_cpp_properties.json

{
"configurations": [
{
"name": "Linux",
"includePath": [
"/usr/x86_64-w64-mingw32/include",
"${workspaceFolder}/**"
],
"defines": [],
"compilerPath": "/usr/bin/g++",
"cStandard": "c11",
"cppStandard": "c++17",
"intelliSenseMode": "gcc-x64"
}
],
"version": 4


Path to directory : /usr/lib/gcc/x86_64-w64-mingw32 --> now is empty

A year ago, everything was working fine.
After reinstalling Kali Linux something changed ?
then copy the new x86_64-w64-mingw32 dir to gcc/x86_64-w64-mingw32
[Image: bitcoin.png] Be Nice For Once 15hVUVz7xA4kazHdk2BuErENGCskVwjYXP
I copied it many times, but without success
Where do you store your binary(so dll) files for C++?
May you be given directions by software engineer document writers.
My Mingw executables are located under /usr/bin:

Code
shisho@gibson:~$ exa -lh /usr/bin | grep "ming"
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-addr2line
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-ar
.rwxr-xr-x   1.8M root 15 Apr 14:25  i686-w64-mingw32-as
lrwxrwxrwx     38 root  3 May 12:15  i686-w64-mingw32-c++ -> /etc/alternatives/i686-w64-mingw32-c++
.rwxr-xr-x   1.2M root 27 Mar  7:28  i686-w64-mingw32-c++-posix
.rwxr-xr-x   1.2M root 27 Mar  7:28  i686-w64-mingw32-c++-win32
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-c++filt
lrwxrwxrwx     38 root  3 May 12:15  i686-w64-mingw32-cpp -> /etc/alternatives/i686-w64-mingw32-cpp
.rwxr-xr-x   1.1M root 27 Mar  7:28  i686-w64-mingw32-cpp-posix
.rwxr-xr-x   1.1M root 27 Mar  7:28  i686-w64-mingw32-cpp-win32
.rwxr-xr-x   1.1M root 15 Apr 14:25  i686-w64-mingw32-dlltool
.rwxr-xr-x    51k root 15 Apr 14:25  i686-w64-mingw32-dllwrap
.rwxr-xr-x    39k root 15 Apr 14:25  i686-w64-mingw32-elfedit
lrwxrwxrwx     38 root  3 May 12:15  i686-w64-mingw32-g++ -> /etc/alternatives/i686-w64-mingw32-g++
.rwxr-xr-x   1.2M root 27 Mar  7:28  i686-w64-mingw32-g++-posix
.rwxr-xr-x   1.2M root 27 Mar  7:28  i686-w64-mingw32-g++-win32
lrwxrwxrwx     38 root  3 May 12:15  i686-w64-mingw32-gcc -> /etc/alternatives/i686-w64-mingw32-gcc
lrwxrwxrwx     40 root  3 May 12:15  i686-w64-mingw32-gcc-9 -> /etc/alternatives/i686-w64-mingw32-gcc-9
.rwxr-xr-x   1.1M root 27 Mar  7:28  i686-w64-mingw32-gcc-9.3-posix
.rwxr-xr-x   1.1M root 27 Mar  7:28  i686-w64-mingw32-gcc-9.3-win32
lrwxrwxrwx     41 root  3 May 12:15  i686-w64-mingw32-gcc-ar -> /etc/alternatives/i686-w64-mingw32-gcc-ar
.rwxr-xr-x    34k root 27 Mar  7:28  i686-w64-mingw32-gcc-ar-posix
.rwxr-xr-x    34k root 27 Mar  7:28  i686-w64-mingw32-gcc-ar-win32
lrwxrwxrwx     41 root  3 May 12:15  i686-w64-mingw32-gcc-nm -> /etc/alternatives/i686-w64-mingw32-gcc-nm
.rwxr-xr-x    34k root 27 Mar  7:28  i686-w64-mingw32-gcc-nm-posix
.rwxr-xr-x    34k root 27 Mar  7:28  i686-w64-mingw32-gcc-nm-win32
.rwxr-xr-x   1.1M root 27 Mar  7:28  i686-w64-mingw32-gcc-posix
lrwxrwxrwx     45 root  3 May 12:15  i686-w64-mingw32-gcc-ranlib -> /etc/alternatives/i686-w64-mingw32-gcc-ranlib
.rwxr-xr-x    34k root 27 Mar  7:28  i686-w64-mingw32-gcc-ranlib-posix
.rwxr-xr-x    34k root 27 Mar  7:28  i686-w64-mingw32-gcc-ranlib-win32
.rwxr-xr-x   1.1M root 27 Mar  7:28  i686-w64-mingw32-gcc-win32
lrwxrwxrwx     39 root  3 May 12:15  i686-w64-mingw32-gcov -> /etc/alternatives/i686-w64-mingw32-gcov
lrwxrwxrwx     44 root  3 May 12:15  i686-w64-mingw32-gcov-dump -> /etc/alternatives/i686-w64-mingw32-gcov-dump
.rwxr-xr-x   473k root 27 Mar  7:28  i686-w64-mingw32-gcov-dump-posix
.rwxr-xr-x   473k root 27 Mar  7:28  i686-w64-mingw32-gcov-dump-win32
.rwxr-xr-x   551k root 27 Mar  7:28  i686-w64-mingw32-gcov-posix
lrwxrwxrwx     44 root  3 May 12:15  i686-w64-mingw32-gcov-tool -> /etc/alternatives/i686-w64-mingw32-gcov-tool
.rwxr-xr-x   494k root 27 Mar  7:28  i686-w64-mingw32-gcov-tool-posix
.rwxr-xr-x   494k root 27 Mar  7:28  i686-w64-mingw32-gcov-tool-win32
.rwxr-xr-x   551k root 27 Mar  7:28  i686-w64-mingw32-gcov-win32
.rwxr-xr-x   1.1M root 15 Apr 14:25  i686-w64-mingw32-gprof
.rwxr-xr-x   1.5M root 15 Apr 14:25  i686-w64-mingw32-ld
lrwxrwxrwx     19 root 15 Apr 14:25  i686-w64-mingw32-ld.bfd -> i686-w64-mingw32-ld
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-nm
.rwxr-xr-x   1.2M root 15 Apr 14:25  i686-w64-mingw32-objcopy
.rwxr-xr-x   2.5M root 15 Apr 14:25  i686-w64-mingw32-objdump
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-ranlib
.rwxr-xr-x   748k root 15 Apr 14:25  i686-w64-mingw32-readelf
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-size
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-strings
.rwxr-xr-x   1.2M root 15 Apr 14:25  i686-w64-mingw32-strip
.rwxr-xr-x   1.0M root 15 Apr 14:25  i686-w64-mingw32-windmc
.rwxr-xr-x   1.1M root 15 Apr 14:25  i686-w64-mingw32-windres
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-addr2line
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-ar
.rwxr-xr-x   2.0M root 15 Apr 14:25  x86_64-w64-mingw32-as
lrwxrwxrwx     40 root  3 May 12:15  x86_64-w64-mingw32-c++ -> /etc/alternatives/x86_64-w64-mingw32-c++
.rwxr-xr-x   1.2M root 27 Mar  7:28  x86_64-w64-mingw32-c++-posix
.rwxr-xr-x   1.2M root 27 Mar  7:28  x86_64-w64-mingw32-c++-win32
.rwxr-xr-x   1.2M root 15 Apr 14:25  x86_64-w64-mingw32-c++filt
lrwxrwxrwx     40 root  3 May 12:15  x86_64-w64-mingw32-cpp -> /etc/alternatives/x86_64-w64-mingw32-cpp
.rwxr-xr-x   1.1M root 27 Mar  7:28  x86_64-w64-mingw32-cpp-posix
.rwxr-xr-x   1.1M root 27 Mar  7:28  x86_64-w64-mingw32-cpp-win32
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-dlltool
.rwxr-xr-x    51k root 15 Apr 14:25  x86_64-w64-mingw32-dllwrap
.rwxr-xr-x    39k root 15 Apr 14:25  x86_64-w64-mingw32-elfedit
lrwxrwxrwx     40 root  3 May 12:15  x86_64-w64-mingw32-g++ -> /etc/alternatives/x86_64-w64-mingw32-g++
.rwxr-xr-x   1.2M root 27 Mar  7:28  x86_64-w64-mingw32-g++-posix
.rwxr-xr-x   1.2M root 27 Mar  7:28  x86_64-w64-mingw32-g++-win32
lrwxrwxrwx     40 root  3 May 12:15  x86_64-w64-mingw32-gcc -> /etc/alternatives/x86_64-w64-mingw32-gcc
lrwxrwxrwx     42 root  3 May 12:15  x86_64-w64-mingw32-gcc-9 -> /etc/alternatives/x86_64-w64-mingw32-gcc-9
.rwxr-xr-x   1.1M root 27 Mar  7:28  x86_64-w64-mingw32-gcc-9.3-posix
.rwxr-xr-x   1.1M root 27 Mar  7:28  x86_64-w64-mingw32-gcc-9.3-win32
lrwxrwxrwx     43 root  3 May 12:15  x86_64-w64-mingw32-gcc-ar -> /etc/alternatives/x86_64-w64-mingw32-gcc-ar
.rwxr-xr-x    34k root 27 Mar  7:28  x86_64-w64-mingw32-gcc-ar-posix
.rwxr-xr-x    34k root 27 Mar  7:28  x86_64-w64-mingw32-gcc-ar-win32
lrwxrwxrwx     43 root  3 May 12:15  x86_64-w64-mingw32-gcc-nm -> /etc/alternatives/x86_64-w64-mingw32-gcc-nm
.rwxr-xr-x    34k root 27 Mar  7:28  x86_64-w64-mingw32-gcc-nm-posix
.rwxr-xr-x    34k root 27 Mar  7:28  x86_64-w64-mingw32-gcc-nm-win32
.rwxr-xr-x   1.1M root 27 Mar  7:28  x86_64-w64-mingw32-gcc-posix
lrwxrwxrwx     47 root  3 May 12:15  x86_64-w64-mingw32-gcc-ranlib -> /etc/alternatives/x86_64-w64-mingw32-gcc-ranlib
.rwxr-xr-x    34k root 27 Mar  7:28  x86_64-w64-mingw32-gcc-ranlib-posix
.rwxr-xr-x    34k root 27 Mar  7:28  x86_64-w64-mingw32-gcc-ranlib-win32
.rwxr-xr-x   1.1M root 27 Mar  7:28  x86_64-w64-mingw32-gcc-win32
lrwxrwxrwx     41 root  3 May 12:15  x86_64-w64-mingw32-gcov -> /etc/alternatives/x86_64-w64-mingw32-gcov
lrwxrwxrwx     46 root  3 May 12:15  x86_64-w64-mingw32-gcov-dump -> /etc/alternatives/x86_64-w64-mingw32-gcov-dump
.rwxr-xr-x   473k root 27 Mar  7:28  x86_64-w64-mingw32-gcov-dump-posix
.rwxr-xr-x   473k root 27 Mar  7:28  x86_64-w64-mingw32-gcov-dump-win32
.rwxr-xr-x   551k root 27 Mar  7:28  x86_64-w64-mingw32-gcov-posix
lrwxrwxrwx     46 root  3 May 12:15  x86_64-w64-mingw32-gcov-tool -> /etc/alternatives/x86_64-w64-mingw32-gcov-tool
.rwxr-xr-x   494k root 27 Mar  7:28  x86_64-w64-mingw32-gcov-tool-posix
.rwxr-xr-x   494k root 27 Mar  7:28  x86_64-w64-mingw32-gcov-tool-win32
.rwxr-xr-x   551k root 27 Mar  7:28  x86_64-w64-mingw32-gcov-win32
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-gprof
.rwxr-xr-x   1.8M root 15 Apr 14:25  x86_64-w64-mingw32-ld
lrwxrwxrwx     21 root 15 Apr 14:25  x86_64-w64-mingw32-ld.bfd -> x86_64-w64-mingw32-ld
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-nm
.rwxr-xr-x   1.4M root 15 Apr 14:25  x86_64-w64-mingw32-objcopy
.rwxr-xr-x   2.7M root 15 Apr 14:25  x86_64-w64-mingw32-objdump
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-ranlib
.rwxr-xr-x   748k root 15 Apr 14:25  x86_64-w64-mingw32-readelf
.rwxr-xr-x   1.2M root 15 Apr 14:25  x86_64-w64-mingw32-size
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-strings
.rwxr-xr-x   1.4M root 15 Apr 14:25  x86_64-w64-mingw32-strip
.rwxr-xr-x   1.3M root 15 Apr 14:25  x86_64-w64-mingw32-windmc
.rwxr-xr-x   1.4M root 15 Apr 14:25  x86_64-w64-mingw32-windres

[Image: zrK9OGf.gif]


Possibly Related Threads...
Thread / Author Replies Views Last Post
[Python] by BastilleJun 9, 2020 12:42 PM 4 179 Jun 9, 2020 12:42 PM
Last Post: Bastille
[C#] by FrogSquad4Dec 17, 2017 03:49 PM 4 188 Dec 17, 2017 03:49 PM
Last Post: rizkyaqew
[Python] by ⁣Null⁣Mar 6, 2017 03:18 AM 7 195 Mar 6, 2017 03:18 AM
Last Post: SIM-1866423