The new version of libiconv does not support nmake compilation. You can only use cygwin and other environments to compile libraries such as. dll. La. It seems that there are methods to generate. Lib. Find a Windows version online, libiconv for Windows: http://gnuwin32.sourceforge.net/packages/libiconv.htm download sources. Is 1.9.2 version
Compile the static Library:
Refer to readme. woe32 for compilation. It must be completed in the command line. You can use the version earlier than vc7 for compilation, just as vc6 exists in my computer.
First, set the environment variable of vc6:
In the vc6 installation directory./Microsoft Visual Studio/vc98/bin, run vcvars32.bat.
Then:
Nmake-F makefile. msvc no_nls = 1 mflags =-MD
Generate the dynamic library Lib, and write the DLL method readme. Just add a DLL = 1 parameter.
Problems:
Iconv. Lib (iconv. OBJ): Error lnk2001: unresolved external symbol _ imp_locale_charset
Solution:
The iconv is generated. lib method, we found that the locale_charset function should not be exported in this way, and finally found that it was originally localcharset. h. one macro definition of in does not take effect. libcharset_dll_exported should be empty during static compilation, but it is not defined as null. leave it blank and compile it again.