News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

PROTOs

Started by traphunter, December 05, 2013, 10:36:36 PM

Previous topic - Next topic

traphunter

Hi everybody!

I had a look at poasm, but I don't like to declare every API-function manually.
I can't get the FuncProtos.zip (http://forum.pellesc.de/index.php?topic=5092.0) because guest are not allowed to download attachments, I guess. Could I get this file here?

TWell

Another option is WinInc from here
Maybe some problems with it too ?

dedndave

is there some reason the masm32 package includes don't work ?
is there some reason masm doesn't work ?   :redface:

it's a safe bet that most of us don't want to prototype all the API functions, either

traphunter

thank you both!

with goasm and easy code I've just included windows.inc and general functions like ExitProcess assembled fine. With poasm, poide and masm32 includes it doesn't work. I tried to include winbase.inc, but this inc file doesn't exist. And for masm32 I can't get uptodate binaries. There is allways sand in the gear.

BTW, I like goasm syntax but I don't like some behaviour from easy code.

dedndave


traphunter

with goasm and easy code I had already used these headers. But they don't work with poasm. Nothing worked with poasm for me, except a PROTO ... in the source file. I hope this FuncProtos.zip will work, but I don't want to register at that forum, I hope I can get it in this forum.

dedndave

ok - i am a little confused   :biggrin:
not the first time

you like GoAsm, but not EasyCode
so - continue to use GoAsm, but not EasyCode
there is no requirement that you use EasyCode

my understanding of PoAsm is that it will use the include files from the masm32 package
however, i've never had the need to try it out

TWell

Quote from: traphunter on December 06, 2013, 04:05:15 AM
with goasm and easy code I had already used these headers. But they don't work with poasm. Nothing worked with poasm for me, except a PROTO ... in the source file. I hope this FuncProtos.zip will work, but I don't want to register at that forum, I hope I can get it in this forum.
POAsm example with minimal WinInc.

traphunter


I've downloaded WinInc208
I've extracted it
I've added the directory to the project options as another include directory
My source file has an statement "include Windef.inc"

and the assembler makes trouble:

..\WinInc208\Include\Windef.inc(217): error: Expected ':'.
..\WinInc208\Include\Windef.inc(217): error: Expected 'type'.
..\WinInc208\Include\Windef.inc(219): error: Expected ':'.
..\WinInc208\Include\Windef.inc(219): error: Expected 'type'.
..


If I try masm32 header I get this error:

\asmtest.asm(32): error: Symbol 'ExitProcess' is undefined.


ok, ExitProcess should be defined in winbase.h, but there isn't a winbase.inc.
What now? I am not a mage and can not imagine where this function is defined.

I hate those problems. :(

Thank you for your patience

Vortex

Hi traphunter,

Attached is the include file set for Poasm.

TWell

Quote from: traphunter on December 06, 2013, 06:07:23 AM

I've downloaded WinInc208
I've extracted it
I've added the directory to the project options as another include directory
My source file has an statement "include Windef.inc"

and the assembler makes trouble:

..\WinInc208\Include\Windef.inc(217): error: Expected ':'.
..\WinInc208\Include\Windef.inc(217): error: Expected 'type'.
..\WinInc208\Include\Windef.inc(219): error: Expected ':'.
..\WinInc208\Include\Windef.inc(219): error: Expected 'type'.
..

With POAsm try this:WIN32_LEAN_AND_MEAN equ <>
include Windows.inc
orWIN32_LEAN_AND_MEAN equ <>
;include Windows.inc
include WinAsmP.inc
include Windef.inc
include WinBase.inc
include WinUser.inc
POAsm must include  modified WinAsmP.inc ?

traphunter

thank you Vortex, but still the same problem

error: Symbol 'ExitProcess' is undefined.


windows.inc fails and winbase.inc doesn't exists and I can't imagine what *.inc has to be included.

Or is it a MUST to write my own winbase.inc to have the right prototype for ExitProcess?


@TWell

I tried both and both leads to the same errors in windef.inc

Vortex

You need kernel32.inc to define ExitProcess. Could you post here your source code? Maybe, we can help you.

traphunter

build :t

I first searched at msdn for the right headers, than I try to include the same header in assembler , therefore I whish I could have the same *.inc files like the microsoft *.h files.

thank you

EDIT: In the future I will try the lib name and not only the header name, reported by microsoft

dedndave

take a look at the file  \masm32\include\masm32rt.inc
it's a plain text file - you can open it with NotePad
it takes care of most things you'll need in one line
    INCLUDE     \masm32\include\masm32rt.inc

the masm32 package does not have a winbase.inc
instead, the contents of that file are in windows.inc (which also includes winextra.inc)

this is a recording, for more options, press #*