RE: CRT section Error!



Thanks Mark and Doran I had a goof up in the project settings and so I
switched to the c++ support and ddkbuild from "hollistech" which fixed
everything and it seems to be working now.


"Arif Golde" wrote:

> The project compiles successfully when I use the Visual studio+DDK enviroment
> but gives this error on the DDK command line enviroment.On compiling I am
> getting this error
> error LNK1218: warning treated as error; no output file generated
>
> The file warning file elaborates on the error.
> cpprt.obj : warning LNK4210: .CRT section exists; there may be unhandled
> static initializers or terminator.
>
> The sources file
> +++++++++++++++++++++++++++++++++++++++++++++++++++
> # sources file for use with DDK BUILD utility
> #
> # File created on 3/16/2005
> #
> TARGETNAME = CardReader
> TARGETPATH = obj
> TARGETTYPE = DRIVER
> DRIVERTYPE = WDM
>
> #uncomment the following line to build with C++ compiler
> #USECXX_FLAG=/Tp
>
> !IF ("$(DDKBUILDENV)"=="chk") || ("$(DDKBUILDENV)"=="checked")
> BUILDTYPE = CHECKED
> !ELSE
> BUILDTYPE = FREE
> NTDEBUG=
> !ENDIF
>
>
> # Singly linked lists have been optimized in a non-back
> # compatible way for XP and later platforms. As such,
> # any binary built with the XP or later DDK and using
> # singly linked lists will not load on 2000 and earlier
> # platforms without the use of the following define in
> # the build. This define turns off the new optimizations,
> # and thus it should only be used for cross-platform
> # binaries.
> #C_DEFINES =$(C_DEFINES) -D_WIN2K_COMPAT_SLIST_USAGE
>
>
> !if !defined(DDK_TARGET_OS) || "$(DDK_TARGET_OS)"=="Win2K"
> C_DEFINES =$(C_DEFINES) -DWIN2K
> !endif
>
> MSC_WARNING_LEVEL=/W1
>
> TARGETLIBS=$(DDK_LIB_PATH)\ntstrsafe.lib $(DDK_LIB_PATH)\csq.lib
> USE_PDB=1
>
> # ntstrsafe.h is in DDK_INC_PATH even for WDM driver
> INCLUDES=$(INCLUDE);$(DDK_INC_PATH)
> #TARGETLIBS=$(TARGETLIBS) $(DDK_LIB_PATH)\ntoskrnl.lib
>
> #TARGETLIBS=$ C:\WINDDK\3790\lib\wxp\i386\ntstrsafe.lib
> #TARGETLIBS=$(TARGETLIBS) $(DDK_LIB_PATH)\msvcrt4d.lib
> #TARGETLIBS=$(TARGETLIBS) $(DDK_LIB_PATH)\libc.lib
> #TARGETLIBS=$(TARGETLIBS) $(DDK_LIB_PATH)\libcd.lib
> #TARGETLIBS=$(TARGETLIBS) $(DDK_LIB_PATH)\libcmt.lib
>
> SOURCES=CardReader.rc \
> registry.cpp \
> debug.cpp \
> CardReader.cpp \
> wmi.cpp \
> iorw.cpp \
> queue.cpp \
> cpprt.cpp \
> pnp.cpp \
> ComPort.cpp \
> DataBufferQueue.cpp \
> power.cpp
>
> #PRECOMPILED_INCLUDE=pch.h
> #PRECOMPILED_PCH=pch.pch
> #PRECOMPILED_OBJ=pch.obj
>
> #
> # setup visualC++ source browsing
> #
> BROWSER_INFO=1
> BSCMAKE_FLAGS=$(BSCMAKE_FLAGS) -n
> LINKER_FLAGS = -MAP
> #CARDREADER_WMI_TRACE=1
>
> !ifdef CARDREADER_WMI_TRACE
>
> C_DEFINES =$(C_DEFINES) -DCARDREADER_WMI_TRACE
>
> !if ("$(PRECOMPILED_CXX)" == "") && ("$(USECXX_FLAG)" == "")
> RUN_WPP=$(SOURCES)\
> -km \
> -func:DbgLog(AREA,LEVEL,MSG,...)
> !else
> RUN_WPP=$(SOURCES)\
> -km -dll\
> -func:DbgLog(AREA,LEVEL,MSG,...)
> !endif
>
> !endif
>
>
>
.



Relevant Pages

  • Re: ANSI C under Visual Studio 2008
    ... Try using SEH, or some of the data declarations (trying to remember off the ... Windows Filesystem and Driver Consulting ... The driver still compiles and runs fine. ... also compiles and runs under MSVC 8, but I haven't bother to try MSVC ...
    (microsoft.public.development.device.drivers)
  • Re: Fedora Core3 - nvidia - I can compile the driver - where to put it ?
    ... The driver package from nvidia.com ... >> contains the source code for the driver which compiles against the ... >> currently running kernel as a last resort (kernel sources must be ... >> I always buy nVidia because they're so trouble free with Linux. ...
    (comp.os.linux.setup)
  • Re: Nvidia problems
    ... have you compiled the NVidia driver? ... The driver itself compiles and installs, and as i remember correctly, ... Load "extmod" ...
    (Fedora)
  • Re: Nvidia problems
    ... have you compiled the NVidia driver? ... The driver itself compiles and installs, and as i remember correctly, ... Load "extmod" ...
    (Fedora)
  • Re: Nvidia problems
    ... have you compiled the NVidia driver? ... The driver itself compiles and installs, and as i remember correctly, ... Load "extmod" ...
    (Fedora)