Hello
I have some cpp sources which i want to have it in masm32 code
I succesfully tried to get the assembly listings from VC++ 6
But I can't get a compilable sourcecode
does somebody has a tutorial , hint, tip, program for my problem?
thx
Ar-ras
I can compile the asm listing of the vc++6 project
but I get one Error
C:\Program\Release>C:\MASM32\BIN\ML.EXE /c /coff /Cp /I"\mas
m32\Include" rotate.asm
Microsoft (R) Macro Assembler Version 8.00.50727.42
Copyright (C) Microsoft Corporation. All rights reserved.
Assembling: rotate.asm
C:\Program\Release>C:\MASM32\BIN\LINK.EXE /SUBSYSTEM:WINDOWS
/RELEASE /VERSION:4.0 /OPT:REF /LIBPATH:"\masm32\Lib" rotate.obj
Microsoft (R) Incremental Linker Version 7.10.3077
Copyright (C) Microsoft Corporation. All rights reserved.
wcrt.lib(crt0win.obj) : error LNK2019: unresolved external symbol _WinMain@16 re
ferenced in function _WinMainCRTStartup
rotate.exe : fatal error LNK1120: 1 unresolved externals
Like you can see, I use the wcrt.lib of jibz
Should I modify the wcrt.lib so that it has no winmaincrtstartup function?
How does vc++ solveds this problem?
Here is an example for you :
\masm32\bin\ml /c /coff Window.asm
\masm32\bin\link /SUBSYSTEM:WINDOWS Window.obj /LIBPATH:C:\masm32\lib crt0\crt0.lib kernel32.lib user32.lib gdi32.lib msvcrt.lib
crt0.lib is a tiny C run-time module to reduce the size of the final executable.
[attachment deleted by admin]
Thanks :dance:
I am going deeper and deeper into the material.
Look I just want to add functions, which are coded in c++
So I compile them with vc++ and get the assemble listings
I try to compile them with the needed libs but i get that the main is missing
I just want to add this functions... not less... not more
So thats why i used wcrt.lib, hoping that it wouldn't need this main function
How can I just compile the assembly listings with the c++ functions without to have that main function :(
Thank YOU
To link your object file, you can specify the /ENTRY:xxx switch to redirect the entry point from main :
link /SUBSYSTEM:WINDOWS /ENTRY:myentrypoint /LIBPATH:...
Naturally, you should define the label myentrypoint in your source code.