News:

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

Problem with include files

Started by OzzY, February 08, 2008, 08:29:23 PM

Previous topic - Next topic

OzzY

Hi jorgon!
I downloaded the ECGO.ZIP from http://www.jorgon.freeserve.co.uk/ and when I try to assemble the following code:

#include "C:\ASM\GoASM\Include\Windows.inc"

.code
start:
invoke MessageBox, 0, 'Hello world', 'GoASm', MB_OK
invoke ExitProcess, 0


I get this error:
Quote

GoAsm.Exe Version 0.56.4 - Copyright Jeremy Gordon 2001/7 - JG@JGnet.co.uk

Warning .......................
Line 19 of the include file C:\ASM\GoASM\Include\Windows.inc:-
Could not open file:-
#Include windef.inc

Error!
Line 5 of assembler source file (test.asm):-
Use square brackets to address memory, ADDR or OFFSET to get address:-
MB_OK

OBJ file not made
Of course it doesn't recognize the MB_OK symbol because it isn't including properly the files.
So, I think it's a bug?

With EasyCode it works OK. But it automatically includes the files for me. But if I want to use other editor and compile from the command line I get this error.

Any idea?

donkey

Hi OzzY,

The older INC files are no longer supported, I have changed over to header (.H) files, however the file Windows.INC does not have any dependencies and does not have any #include lines in it so I am not sure where you got your file, it certainly wasn't one of mine. If you like you can download the current header project which has most definitions up to and including Windows Vista. First be sure to set the INCLUDE environment variable to the path of where you save the files then use the following "standard" configuration...

#DEFINE IDISPATCH_DEFINED
#DEFINE IUNKNOWN_DEFINED

#DEFINE NOMCX
#DEFINE NOIME
#DEFINE NOTV
#DEFINE NONETWORK
#DEFINE NOSERVICE
#DEFINE NOCON
#DEFINE NOOLE
#DEFINE NOCARD
#DEFINE NORADASM
#DEFINE NOZLIB
#DEFINE NODONKEY
#DEFINE CCUSEORDINALS

#include "WINDOWS.H"
#include "Commctrl.h"


The header (.H) files are much more complete and accurate than the old Windows.INC file and follow the documentation at MSDN more closely.

The header files are available for download from my website...

www.assembler.ca

Donkey
"Ahhh, what an awful dream. Ones and zeroes everywhere...[shudder] and I thought I saw a two." -- Bender
"It was just a dream, Bender. There's no such thing as two". -- Fry
-- Futurama

Donkey's Stable

OzzY

Hi Donkey!
Thanks for the answer!
I got the include files from this package: http://www.jorgon.freeserve.co.uk/ECGo.zip which is used with EasyCode IDE.

I'll try your include files to see if it solves the problem.

EDIT: Your include files solved my problem after i added the INCLUDE environment variable.
Problem solved!
Thanks!

jorgon

Hi OzzY

I just looked inside the ECGo.zip file because of your comments.

The contents of this (the include files) are provided to me from time to time by Ramon Sala who wrote the EasyCode IDE.  Then I add the latest version of the Go tools and create the resulting zip file.

Looking inside the file, windef.inc is definitely there and is one of the nested includes referred to in Windows.inc.  Do you think you may have rubbed it out or changed its name by mistake?

Author of the "Go" tools (GoAsm, GoLink, GoRC, GoBug)

OzzY

Hello!

I haven't changed it. Just unzipped it.
From EasyCode it really works because it already include them for me. But if I try to #include them myself and compile from command line I get the error above.

Ramon Sala

Hi Ozzy,

The Windows.inc file includes other files, so the problem is with the environment variables. You can solve this problem by including the file using the "Project->Add Include file" menu and delete the <#include "C:\ASM\GoASM\Include\Windows.inc"> line. After that, it should compile fine.

Ramon
Greetings from Catalonia