using dislin with Windows10/codeblocks/mingw C++ : linker error undefined ref. 'imp___iob_func'

14 views
Skip to first unread message

Bernhard ZEIMETZ

unread,
Jun 15, 2026, 10:57:44 AM (9 days ago) Jun 15
to dislin-users
Hello,
I would like to use dislin with codeblocks (v25.03, using mingw 14.02, windows 10)
I set up a very bare test programme (type "Win32 GUI project")
which in main.cpp has
 #include <discpp.h>  
and in WinMain() 
 Dislin g; 
//nothing else is called

Following advice in other threads, I set under 
Project > Build Options> Linker > other linker options:
  -mthreads
  ..\..\ExtLibs\dislin_gcc\discpp.a  -lgdi32 -luser32 -lopengl32
 
but I get a linker error 
undefined ref. to "__imp___iob_func"
(3X, in the same 3 (sub)files dis_win.cpp, errmes.cpp, resall.cpp)

I found online some infos on similar problems but with other compilers/languages/symbols, and the advice given there doesn't help. (eg adding other libraries)

Thanks in advance for any ideas or advice!

Helmut Michels

unread,
Jun 16, 2026, 6:29:41 AM (8 days ago) Jun 16
to dislin-users
Hi,

please use the library discppu.a instead of discpp.a. discppu.a supports the ucrt runtime
library. I have tested it with  codeblocks v25.03, mingw 14.02 and Windows 11.

With best regards,

Helmut

Bernhard ZEIMETZ

unread,
Jun 18, 2026, 4:53:36 AM (6 days ago) Jun 18
to dislin-users
Hi Helmut,
thanks very much, this works!
regards, Bernhard
Reply all
Reply to author
Forward
0 new messages