The problem with Oracle SDK compilation is well solved under MacOS and Linux, because GCC and pkg-config are both self-bringing programs. However, there are no two programs under windows that need to be installed on your own. The advantage is that MSYS2 has encapsulated two programs, configured as follows: Install MSYS2 tutorial as follows, point me to view. After the installation is complete, use the
Pacman-s Mingw-w64-x86_64-toolchain
Note: The default for direct use of the pacman–s GCC installation is the Mysy version, which is not good. To use the above command to install to the C:\TOOLS\MSYS64\MINGW64 directory is not counted. Install the GCC program. The command to install the Pkg-config program is as follows:
Pacman-s Pkg-config
Two when the program is installed, it is automatically saved under the C:\TOOLS\MSYS64\USR directory. After installing Pkg-config, you need to configure the oci8.pc file, which is in the directory:
C:\Tools\msys64\usr\share\pkgconfig
For more information, please visit the personal blog, using Golang to connect Oracle under Windows