News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

How to print out values in MASM syntax?

Started by RedSkeleton007, June 27, 2015, 06:54:38 AM

Previous topic - Next topic

dedndave

the irvine32 library include files have a small issue to be aware of
when you include the file, "Irvine32.inc", it includes a couple other INC files (SmallWin.inc, VirtualKeys.inc)
now, i am not sure about the details of how masm works - it seems to find these additional files for me
but, there is a potential problem with paths
at any rate - be aware that you may have to move things around or change paths, etc

also, i mentioned earlier that the CaseMap:None option is commented out
i prefer case sensitive symbol names, so i add it to my source
(less than ideal - probably better to modify Irvine32.inc and un-comment the OPTION line)

that having been said...
i created a folder in the root and copied all the irvine files in there...

;###############################################################################################

        INCLUDE     \Irvine\Irvine32.inc  ;adds SmallWin.inc, VirtualKeys.inc

        OPTION      CaseMap:None

        INCLUDE     \Irvine\floatio.inc
        INCLUDE     \Irvine\GraphWin.inc
        INCLUDE     \Irvine\macros.inc

        INCLUDELIB  \Irvine\kernel32.lib
        INCLUDELIB  \Irvine\user32.lib
        INCLUDELIB  \Irvine\Irvine32.lib

;###############################################################################################

        .DATA

szMessage db 'Hello World',13,10,0

;***********************************************************************************************

        .DATA?

;###############################################################################################

        .CODE

;***********************************************************************************************

main    PROC

        mov     edx,offset szMessage
        call    WriteString

        call    WaitMsg
        INVOKE  ExitProcess,0

main    ENDP

;###############################################################################################

        END     main

RedSkeleton007

Quote from: dedndave on February 03, 2016, 12:25:49 AM
that having been said...
i created a folder in the root and copied all the irvine files in there...
So in other words, you figured out how to get MASM programs that use the irvine files to compile in the MASM32 Editor?

If so, do we not need this anymore:
INCLUDE    \Masm32\Include\Masm32rt.inc

dedndave

that line of code is for the Masm32 library package - Irvine's package is not 100% compatible

as for using QEditor, i don't see any reason you can't use the editor
but, the build menu options are for use with the Masm32 package
they execute batch files, and i think you can add menu items - so, you could add Irvine selections i think

i don't use QEditor - i use NotePad and NotePad++
and, i generally use my own batch files to build with

dedndave

#33
... if you have visual studio installed, it may set some of the environment variables that masm and link recognize
if that's the case, you may have to find work-arounds to add to your batch files

for example, you might use the SETLOCAL batch command to temporarily alter specific variables
or, there are command-line switches to override them

https://msdn.microsoft.com/en-us/library/s0ksfwcf.aspx

https://msdn.microsoft.com/en-us/library/hx5b050y.aspx

https://msdn.microsoft.com/en-us/library/6y6t9esh.aspx

command-line switches may vary from version to version
you can type
>ml /help
or
>ml /?
to get a list - same for link