News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

How do you enable Pelle's tools ?

Started by grofaz, September 08, 2008, 08:51:49 PM

Previous topic - Next topic

PBrennick

Michael,
Please try again. This version is using an entirely different approach where I am checking the state of the menu selections and building the strings accordingly. Works fine on XP so there is hope.

-- Paul
The GeneSys Project is available from:
The Repository or My crappy website

MichaelW

OK, that appears to have fixed the problem. I can now get the editor to use poasm and jwasm, as well as porc and polink. I have not used poasm in a while so I'm not sure how it should behave, but in the time I spent on it I could not find a source that poasm could successfully assemble. Here are some typical results:

Calling the Assembler.

\GeneSys\bin\poasm.exe C:\GeneSys\examples\ConsoleApps\Pi\Pi.asm

\GeneSys\include\windows.inc(18306): error: Invalid use of 'align'.
\GeneSys\include\windows.inc(18306): error: Invalid use of 'dword'.
\GeneSys\include\windows.inc(29706): error: Redefinition of symbol 'GUID'.
\GeneSys\macros\macros.asm(173): error: Invalid use of '%'.
\GeneSys\macros\macros.asm(175): error: Invalid use of '%'.
\GeneSys\macros\macros.asm(176): error: Invalid use of ''.
\GeneSys\macros\macros.asm(179): error: Invalid use of 'endm'.
\GeneSys\macros\macros.asm(311): error: Invalid use of '%'.
\GeneSys\macros\macros.asm(314): error: Invalid use of '%'.
C:\GeneSys\examples\ConsoleApps\Pi\Pi.asm(24): error: Too many parameters to 'SeeYa'.
C:\GeneSys\examples\ConsoleApps\Pi\Pi.asm(23): error: Expected 'identifier'.
C:\GeneSys\examples\ConsoleApps\Pi\Pi.asm(24): error: Invalid use of 'ENDIF'.
C:\GeneSys\examples\ConsoleApps\Pi\Pi.asm(24): error: Invalid use of 'ENDIF'.
C:\GeneSys\examples\ConsoleApps\Pi\Pi.asm(24): error: Invalid use of ','.
C:\GeneSys\examples\ConsoleApps\Pi\Pi.asm(24): error: Unterminated conditional code (IF-ENDIF).

Errors occurred while assembling. The Build process is halted.

Errors occurred while linking. The Build process failed.


Calling the Assembler.

\GeneSys\bin\poasm.exe C:\GeneSys\examples\Invoke\invoke.asm

\GeneSys\include\windows.inc(18306): error: Invalid use of 'align'.
\GeneSys\include\windows.inc(18306): error: Invalid use of 'dword'.
\GeneSys\include\windows.inc(29706): error: Redefinition of symbol 'GUID'.
C:\GeneSys\examples\Invoke\invoke.inc(11): error: Invalid use of '%'.
C:\GeneSys\examples\Invoke\invoke.inc(12): error: Invalid use of '%'.
C:\GeneSys\examples\Invoke\invoke.inc(15): error: Invalid use of '%'.
C:\GeneSys\examples\Invoke\invoke.asm(49): error: Invalid use of 'wc'.
C:\GeneSys\examples\Invoke\invoke.asm(49): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(49): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(49): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(49): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(49): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(48): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(53): error: Invalid use of 'AppName'.
C:\GeneSys\examples\Invoke\invoke.asm(53): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(53): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(53): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(53): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(53): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(52): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(53): error: Invalid use of ','.
C:\GeneSys\examples\Invoke\invoke.asm(58): error: Invalid use of 'msg'.
C:\GeneSys\examples\Invoke\invoke.asm(58): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(58): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(58): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(58): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(58): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(57): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(60): error: Invalid use of 'msg'.
C:\GeneSys\examples\Invoke\invoke.asm(60): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(60): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(60): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(60): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(60): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(59): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(61): error: Invalid use of 'msg'.
C:\GeneSys\examples\Invoke\invoke.asm(61): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(61): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(61): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(61): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(61): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(60): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(35): error: Symbol 'WndProc' is undefined.
C:\GeneSys\examples\Invoke\invoke.asm(73): error: Invalid use of 'ps'.
C:\GeneSys\examples\Invoke\invoke.asm(73): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(73): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(73): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(73): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(73): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(72): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(73): error: Invalid use of ','.
C:\GeneSys\examples\Invoke\invoke.asm(75): error: Invalid use of 'rect'.
C:\GeneSys\examples\Invoke\invoke.asm(75): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(75): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(75): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(75): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(75): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(74): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(75): error: Invalid use of ','.
C:\GeneSys\examples\Invoke\invoke.asm(76): error: Invalid use of 'or'.
C:\GeneSys\examples\Invoke\invoke.asm(76): error: Invalid use of '1'.
C:\GeneSys\examples\Invoke\invoke.asm(77): error: Invalid use of 'ps'.
C:\GeneSys\examples\Invoke\invoke.asm(77): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(77): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(77): error: Invalid use of ')'.
C:\GeneSys\examples\Invoke\invoke.asm(77): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(77): error: Invalid use of ''.
C:\GeneSys\examples\Invoke\invoke.asm(76): error: Invalid use of '{line-break}'.
C:\GeneSys\examples\Invoke\invoke.asm(77): error: Invalid use of ','.
C:\GeneSys\examples\Invoke\invoke.asm(67): warning: Symbol 'ps' is never used.
C:\GeneSys\examples\Invoke\invoke.asm(68): warning: Symbol 'rect' is never used.
C:\GeneSys\examples\Invoke\invoke.asm(35): error: Symbol 'WinMain.WndProc' is undefined.

Errors occurred while assembling. The Build process is halted.

Errors occurred while linking. The Build process failed.

eschew obfuscation

Vortex

Hi MichaelW,

Thanks for the testings. The reason why Poasm fails is that all the GeneSys examples are designed to be assembled with ml.exe . Poasm's macro system is not like Masm's and the master include file window.inc was designed to be used with ml.xe

PBrennick

Hi Michael,
This is great news. Vortex is correct in that PoASM is only a 'near' compatible to ml.exe. JWasm, however, will assemble all those examples flawlessly. In fact, the GeneSys Editor, itself, has been assembled many times with JWasm and it is the largest program I have ever written.

One think I wonder about; in the windows help file, I often encounter many APIs that state, "Now works with NT." I wonder if this is the problem, you having a very old version of NT?

BTW: would you like me to post the code that failed and the code that works? I have no clue why the failed code fails. It does have some APIs (setting CheckMarks within the blocks but they seem to work fine.

-- Paul
The GeneSys Project is available from:
The Repository or My crappy website

MichaelW

Mostly, I would like to know the API functions that are involved or might be involved.
eschew obfuscation

PBrennick

Michael,

I would say it would have to be CheckMenuItem.

I have to be careful here because I can only know for sure what worked and what did not work. There are three .if blocks, each triggered by a menu selection. All three of them (PoASM, PoRC and PoLink) use CheckMenuItem. Two of them work and one did not. The only structural difference between the three is that the block triggered by IDM_POASM has three instances of CheckMenuItem whereas the other two has two instances. The reason for this is because setting the PoASM checkmark has to reset the JWasm checkmark. Now, the toggling of all three works correctly but in the case of setting the PoASM checkmark, the hPoASM flag refuses to set (the same happens with JWasm). So when the AssembleIt procedure runs and the string is built, since neither of the hPoASM and hJWasm flags are set the strings associated with them never gets built and the default (ml.exe) is used instead. That is the scenario.

I wonder if the usage of three instances of CheckMenuItem in the .if block somehow causes a problem when used by Windows 2000. It is possible, I suppose, maybe the stack decays because of the version of the API used by your OS. The whole thing does not make a whole lot of sense to me but I am forced to live with the reality that there is something funky about old versions of the CheckMenuItem API.

I am still using the toggling method but hPoASM and hJWasm, although still there, are not used anywhere in the program any longer and are scheduled for removal. Instead, in the AssembleIt procedure, I am testing the MF_CHECKED flag using the GetMenuState API. This evidently solves the problem.

You tell me, I have a headache.  :red

-- Paul
The GeneSys Project is available from:
The Repository or My crappy website