We have been building 32 bit drivers using mingw32 in a msys environment. We recently downloaded and installed a snapshot build mingw-w64-bin_i686-mingw_20090121. And other than a header pathing issue, and a couple other minor hiccups, things seemed to be ok.
However, when we go to link our final output we have a problem.
Our problem now is that there does not appear to be a 64 bit version of ntoskrnl (or a 32 bit in this package). I looked in our install tree (/home/engr/tools/generic-i386-winxp64 -- which happens to be a networked drive under mingw) in mingw/lib64. I'm making an assumption that this library is automatically listed in the paths to be searched for libraries. I do see a lib64/libhal.a.
Any help is appreciated.
Here is the output. gcc is actually a shell which invokes bin/x86_64-pc-mingw32-gcc.exe when it sees the -m64 flag.
gcc -shared -L/home/engr/tmp/bhawley/generic-i386-winxp/LicenseMgr/1.8.0.13/lib -L/home/engr/tmp/bhawley/generic-i386-winxp/Libraries/2.2.0.0/lib -L/home/engr/support/generic-i386-winxp/LicenseMgr/1.8.0.13/lib -L/home/engr/support/generic-i386-winxp/Libraries/2.2.0.0/lib -L/home/engr/support/generic-i386-winxp/w32compat/pthread/lib -m64 -shared -Wl,--entry,_DriverEntry@8 -nostartfiles -nostdlib -static-libgcc /home/engr/tmp/bhawley/generic-i386-winxp/LicenseMgr/1.8.0.13/llmdrv/generic-i386-winxp-entry.o_K64 /home/engr/tmp/bhawley/generic-i386-winxp/LicenseMgr/1.8.0.13/llmdrv/llmdrv.o_K64 /home/engr/tmp/bhawley/generic-i386-winxp/LicenseMgr/1.8.0.13/llmdrv/version.o_K64 -o /home/engr/tmp/bhawley/generic-i386-winxp/LicenseMgr/1.8.0.13/drv/llmdrv_K64.sys -lLicenseMgr_K64 -lbase_K64 -lntoskrnl -lhal -lgcc
using 64bit compiler
v:/tools/generic-i386-winxp64/bin/../lib/gcc/x86_64-pc-mingw32/4.4.0/../../../../x86_64-pc-mingw32/bin/ld.exe: cannot find -lntoskrnl
collect2: ld returned 1 exit status