Hi,
I've just been to http://www.openwatcom.org/ .
They have now released the complete package for free. Has absolutely everything. I've just played with the dialog editor, wde.exe, works just like the Microsoft one. Also the wre.exe and wimgedit.exe
-- note the complete package is about 60M, but you can get it in little pieces
-- I found the resource editors in "cm_ide_nt.zip".

Anyway, what intrigues me is "WASM", the assembler. Can't see any docs on it. I did a search in this forum, and came up with this comment by "Beaster" on mar 12, 2002:

"there is no docu for WASM, not even from WATCOM. It seems, they didnt use the tool stand alone.

However, I do It works fine and it is very similar to MASM. The WASM has some minor bugs, but nothing real.

The main reason (the only one?) to use WASM is the chance, that it will become open-source."

So, it now is. Anyone out there experienced with WASM? How much like MASM is it? Are there any docs anywhere? (I haven't hunted exhaustively through the Open Watcom docs, so maybe there is something somewhere).

Regards,
Barry Kauler
P.S. I've just updated my "x86" links page, at http://www.goosee.com/x86/
Posted on 2003-02-16 19:08:48 by bkauler
hah, your webpage was the first asm website I ever visited :alright:
Posted on 2003-02-16 19:30:14 by BubbaFate
it can't be used to creates comercial programs, right (for a whole)?
Posted on 2003-02-16 22:52:07 by Bi_Dark
Barry,

Thanks for the link, the dialog editor works fine and appears to save the DLG file in standard RC format.

As far as the WASM assembler, best way is to start shoving some MASM code through it to see if it is close enough to be compatible. It would certainly be interesting if it was a viable replacement for MASM.

Regards,

hutch@movsd.com
Posted on 2003-02-17 00:39:22 by hutch--

It uses (or is capable of) a slightly better syntax than MASM.
But why use MASM/WASM when you have FASM?
Posted on 2003-02-17 02:50:04 by Maverick
Bkauler,

Thanks for the info!:alright:
Posted on 2003-02-17 03:03:31 by Vortex
Download "cm_core_nt.zip" to get WASM the linker and most of the normal tools. No idea on the syntax yet. If you run WASM and WLINK wiith the "/?" help option, you at least get the switches for assembling and compiling.

Regards,

hutch@movsd.com
Posted on 2003-02-17 04:21:26 by hutch--

WASM /?


Watcom Assembler Version 11.0c
Copyright by Sybase, Inc., and its subsidiaries, 1992, 2000.
All rights reserved. Watcom is a trademark of Sybase, Inc.
Usage: wasm [options] asm_file [options] [@env_var]
Options: ( /option is also supported )
-{0,1,2,3,4,5}{p}{r,s}
-0 8086 instructions
-1 80186 instructions
-2 80286 instructions
-3 80386 instructions
-4 80486 instructions
-5 pentium instructions
add p protect mode
add r register calling conventions
add s stack calling conventions
ie: /2 /3s /4pr /5p
-bt=<os> set the build target to <os>
-c disable outputting of data in code records
-d<name>[=text] define text macro
-d1 line number debugging support
-e stop reading ASM file at END directive
-e<number> set error limit number
-fr=<file_name> set error file name
(Press return to continue)
-fo=<file_name> set object file name
-fi=<file_name> force <file_name> to be included
-fpc calls to floating-point library
-fpi inline 80x87 instructions with emulation
-fpi87 inline 80x87 instructions
-fp0 floating-point for 8087
-fp2 floating-point for 287
-fp3 floating-point for 387
-fp5 floating-point for Pentium
-i=<directory> add directory to list of include directories
-j or -s force signed types to be used for signed values
-m{t,s,m,c,l,h,f} memory model:
(Tiny, Small, Medium, Compact, Large, Huge, Flat)
-nd=<name> set data segment name
-nm=<name> set module name
-nt=<name> set name of text segment
-o allow C form of octal constants
-zq or -q operate quietly
-? print this message
-w<number> set warning level number
-we treat all warnings as errors


WLINK /?


WATCOM Linker Version 11.0c
Copyright by Sybase, Inc., and its subsidiaries, 1985, 2000.
All rights reserved. Watcom is a trademark of Sybase, Inc.
usage: wlink {directive}

commands valid for all executable formats:

directive ::= "File" obj_spec{","obj_spec}
| "Name" exe_file
| "OPtion" option{","option}
| "Library" library_file{","library_file}
| "OPTLIB" library_file{","library_file}
| "Path" path_name{";"path_name}
| "LIBPath" path_name{";"path_name}
| "LIBFile" obj_file{","obj_file}
| "Debug" dbtype [dblist] | dblist
| "MODTrace" module_name{","module_name}
| "SYMTrace" symbol_name{","symbol_name}
| "SYStem" system_name
| "SYStem Begin" system_name directive {directive} "End"
| "FORMat" form
| "REFerence" symbol_name{","symbol_name}
| "@" directive_file
| "#" comment
press any key to continue

commands valid for all executable formats (continued):

| "Alias" alias"="symbol_name{","alias"="symbol_name}
| "DISAble" msg_num{","msg_num}
| "SOrt" ["GLobal"] ["ALPhabetical"]
| "LANGuage" ("JApanese" | "CHinese" | "KOrean")
| "STARTLINK"
| "ENDLINK"
| "MODFile" obj_file{","obj_file}
obj_spec ::= obj_file["("obj_member")"] | library_file["("lib_member")"]
dbtype ::= "Watcom" | "Dwarf" | "Codeview"
dblist ::= dboption{","dboption}
dboption ::= "LInes" | "Types" | "LOcals" | "All"
option ::= "ARTificial" | "[NO]CAChe" | "[NO]Caseexact" | "CVPack"
| "Dosseg" | "ELiminate" | "INCremental[=file_name]"
| "MANGlednames" | "Map"["="map_file] | "MAXErrors="n | "NAMELen="n
| "NODefaultlibs" | "OSName="string | "Quiet" | "[NO]REDefsok"
| "STack"=n | "START="symbol_name | "STATics"
| "SYMFile"["="symbol_file], | "[NO]Undefsok" | "Verbose"
| "VFRemoval"

commands valid for the MS-DOS executable format only:

form ::= "Dos" ["COM"]
directive ::= "NEWsegment"
option ::= "PACKCode="n | "PACKData="n

commands valid for the OS/2 and DOS/4G Systems executable formats only:

form ::= "OS2" ["FLat"|"LE"|"LX"] ["PHYSdevice" | "VIRTdevice"
| ["DLl"["INITGlobal"|"INITInstance" ["TERMInstance"|"TERMGlobal"]]
| "PM" | "PMCompatible" | "FULLscreen"]
directive ::= "NEWsegment"
| "SEGment" segdesc{","segdesc}
| "IMPort" import{","import}
| "EXPort" export{","export}
| "EXPort" "="wlib_directive_file
segdesc ::= segspec segmodel {segmodel}
segspec ::= seg_name | "Class" class_name | "TYpe" ("CODE" | "DATA")
import ::= entryname module["."(extname | ordinal)]
option ::= "Alignment="n | "DEscription" description | "Heapsize="n
| "IMPFile"[=file_name] | "IMPLib"[=file_name]
| ("MANYautodata" | "NOautodata" | "ONEAutodata")
| "MODName="module_name | "NEWFiles" | "OFFset="n
| "OLDlibrary="dll_name | "PACKCode="n | "PACKData="n | "PROTmode"
| "RESource="res_file_name | "STUB="stub_name
| "VERSion="major.[minor]
export ::= entryname["."ordinal]["="internal]["RESident"]["PRIVATE"][iopl]
segmodel ::= ("PReload" | "LOadoncall") | ("SHared" | "NONShared")
| ("EXECUTEOnly" | "EXECUTERead" | "READOnly" | "READWrite")
| ("Iopl" | "NOIopl") | ("CONforming" | "NONConforming")
| ("PERManent" | "NONPERManent") | "INValid" | "RESident"
| "CONTiguous" | "DYNamic"


commands valid for the Microsoft Windows executable formats only:

form ::= "WIndows" ["DLl"["INITGlobal" | "INITInstance"]] [MEMory] [FOnt]
directive ::= "NEWsegment"
| "SEGment" segdesc{","segdesc}
| "IMPort" import{","import}
| "EXPort" export{","export}
| "EXPort" "="wlib_directive_file
segdesc ::= segspec segmodel {segmodel}
segspec ::= seg_name | "Class" class_name | "TYpe" ("CODE" | "DATA")
import ::= entryname module["."(extname | ordinal)]
option ::= "Alignment="n | "DEscription" description | "Heapsize="n
| "IMPFile"[=file_name] | "IMPLib"[=file_name]
| ("MANYautodata" | "NOautodata" | "ONEAutodata")
| "MODName="module_name | "OLDlibrary="dll_name | "PACKCode="n
| "PACKData="n | "RESource="res_file_name | "RWReloccheck"
| "STUB="stub_name | "VERSion="major.[minor]
export ::= entryname["."ordinal]["="internal]["RESident"]["PRIVATE"]
segmodel ::= ("PReload" | "LOadoncall") | ("SHared" | "NONShared")
| ("EXECUTEOnly" | "EXECUTERead" | "READOnly" | "READWrite")
| ("MOVeable" | "FIXed") | "DIScardable"


commands valid for the Microsoft Windows NT executable formats only:

form ::= "WIndows NT" ["TNT"]
["DLl"["INITGlobal"|"INITInstance" ["TERMInstance"|"TERMGlobal"]]
directive ::= "RUntime" runoption["="major["."minor]]
| "SEGment" segdesc{","segdesc}
| "IMPort" import{","import}
| "EXPort" export{","export}
| "EXPort" "="wlib_directive_file
| "COMmit" commitopt{","commitopt}
segdesc ::= segspec segmodel {segmodel}
segspec ::= seg_name | "Class" class_name | "TYpe" ("CODE" | "DATA")
import ::= entryname module["."(extname | ordinal)]
option ::= "Alignment="n | "DEscription" description | "Heapsize="n
| "IMPFile"[=file_name] | "IMPLib"[=file_name]
| "MODName="module_name | "NOSTDCall" | "OBJAlign="n | "OFFset="n
| "OLDlibrary="dll_name | "RESource="res_file_name
| "STUB="stub_name | "VERSion="major.[minor]
export ::= entryname["."ordinal]["="internal]["PRIVATE"]
segmodel ::= ("SHared" | "NONShared") | ("PAGEable" | "NONPageable")
runoption ::= ("NATive" | "WINdows" | "CONsole" | "POSix" | "OS2" | "DOSstyle")
commitopt ::= "STack="n | "Heap="n


commands valid for the Phar Lap executable formats only:

form ::= "PHARlap" ["EXTended" | "REX" | "SEGmented"]
directive ::= "RUntime" runoption{","runoption}
option ::= "MAXData="n | "MINData="n | "OFFset="n | "STUB="stub_name
runoption ::= "MINReal="n | "MAXReal="n | "CALLBufs="n | "MINIBuf="n
| "MAXIBuf="n | "NISTack="n | "ISTKsize="n | "PRIVileged"
| "REALBreak="(n | symbol_name ) | "UNPRIVileged"


commands valid for the Novell Netware executable format only:

form ::= "NOVell" ["NLM" | "LAN" | "DSK" | "NAM"] description
directive ::= "MODUle" module_name{","module_name}
| "IMPort" import{","import}
| "EXPort" export{","export}
| "Debug" "Novell" ["ONLyexports"] ["REFerenced"]
option ::= "CHeck="symbol_name | "COPYRight" [string] | "CUSTom="file_name
| "EXit="symbol_name | "HElp="file_name | "IMPFile="file_name
| "IMPLib"[=file_name] | "MESsages"[=file_name] | "MULTILoad"
| "NLMFlags="value | "PSeudopreemption" | "REentrant"
| "SCReenname" description | "SHArelib="file_name | "SYnchronize"
| "THReadname" name | "VERSion="major[.minor[.revision]]
| "XDCdata="file_name
import ::= entryname
export ::= entryname


commands valid for the QNX executable format only:

form ::= "QNX" ["FLat"]
directive ::= "SEGment" segdesc{","segdesc}
| "NEWsegment"
option ::= "Heapsize="n | "LInearrelocs" | "LOnglived" | "NORelocs"
| "OFFset="n | "PACKCode="n | "PACKData="n | "PRIVilege"=n
| "RESource"("="res_file_name | string)
segdesc ::= segspec segmodel {segmodel}
segspec ::= seg_name | "Class" class_name | "TYpe" ("CODE" | "DATA")
segmodel ::= "EXECUTEOnly" | "EXECUTERead" | "READOnly" | "READWrite"


commands valid for the ELF executable format only:

form ::= "ELF" ["DLl"]
directive ::= "MODUle" module_name{","module_name}
| "IMPort" import{","import}
| "EXPort" export{","export}
option ::= "Alignment="n | "EXPORTAll" | "EXTRASections="n | "OBJAlign="n
| "OFFSet="n
import ::= entryname
export ::= entryname
Posted on 2003-02-17 07:40:23 by Maverick
Hi,

for win32 asm coding I only use WASM. Since it is a professional all-in-one solution
I can recommend it to anyone. If you have to handle large projects (5 MBytes of
sources and more) WASM/WLINK works quite fine. There are only a few bugs and
they can be by-passed easily.

The only thing I miss is SSE/SSE2 and x86-64 support.

Give it a try.

Bye Miracle
Posted on 2003-02-17 07:49:23 by miracle
I have wrote this thread already im middle of last year :)

I have already my own version of the Watcom IDE:
with 16 instead of 4 recent file entries in the file menu and with a new style file dialog instead of the old fahioned in the
original version, took me 2 hours to "dive" among mountains of open source codes...
Posted on 2003-02-17 07:54:47 by beaster

for win32 asm coding I only use WASM.


Miracle,what are the differences between Masm and Wasm? (the asm syntax,manipulation of libraries etc.)

Regards,

Vortex
Posted on 2003-02-17 08:02:34 by Vortex
Hi Vortex,

hard to say since I don't know MASM that well.
But first of all there are only a few people which use Watcom, that
way to get help is a bit harder. Especially the MASM macro stuff
(if eax == 0 else stuff etc.) is not available I guess. Even the invoke macro
for WASM is not written yet. Maybe there is someone who tries the MASM macros
with WASM. You have to take care by yourself which kind of structure a register
points to. The count and type of arguments passed to functions is
your job too.

On the other hand if you are looking for a good coding environment
UltraEdit and Open Watcon are just working smooth. If you ever tried
M$ Visual C debugger and IDE you are ready to enter the next stage and
start professional development :)

In other words, if you depend on the macro stuff keep MASM.

Bye Miracle
Posted on 2003-02-17 08:27:10 by miracle
Thanks Miracle for the info.:alright:

Regards,

Vortex
Posted on 2003-02-17 08:34:11 by Vortex
I don't quite understand how you'd link an obj file with wlink...its command line parameters are kind of strange...anyone know how?

Error! E3033: directive error near "test.obj"
Posted on 2003-02-17 10:14:04 by kairon
try this:

wl system nt file test.obj libpath c:\cache\libs library kernel32.lib d all

means:

system: nt
file: insert your file
libpath: path with some libfiles
library: used libraries
d: debug info

use the watcom provided libfiles, or build your own with the wlib tool, like this:

wlib kernel32.lib +kernel32.dll

-> will create a lib for the kernel32.dll library
Posted on 2003-02-17 10:20:29 by beaster
K, thanks. WASM is pretty cool, and is compatible to MASM very much though I noticed if you do something like

TESTSTRUC STRUC
test db ?
TESTSTRUC ENDS

mov ,0


then MASM starts to choke on the mov ,0 while WASM does not, same without the brackets as well. I wish there was some documentation on WASM though :(
Posted on 2003-02-17 14:00:47 by kairon
MASM works fine with mov ,0 - but you must define a variable as well as declare the structure
Posted on 2003-02-17 17:27:45 by eGo
What is:

Warning! W1023: no starting address found, using 00401000
?

Also, WLINK is linking very odd code when i tell it what to link, its almost like its completely ignoring my output cause its putting the program into an endless loop of code I didnt even make. I don't think this is a problem on WASM's side cause the obj file size grows bigger as I insert new code, and it looks like the .obj output is correct, but something is wrong on WLINK's side. :(
Posted on 2003-02-17 18:12:21 by kairon
The result:Masm+link is the best for asm coders!:alright:
Posted on 2003-02-18 02:06:50 by Vortex
use "op start=xxx" as linker option.

where xxx is your starting label, e.g. WinMain or just Start
if not given, the start address is set to the begin of the ode segment.
Posted on 2003-02-18 05:47:24 by beaster