Author Topic: Can't find any included file in \masm32\includes  (Read 23529 times)

localhost

  • Guest
Can't find any included file in \masm32\includes
« on: December 09, 2012, 02:36:43 AM »
I just installed masm32 on windows, all went weel, but any .asm that includes a file from \masm32 won't work.

Code: [Select]
C:\masmprojects>ml  /c  /Zd  /coff file.asm
Microsoft (R) Macro Assembler Version 6.14.8444
Copyright (C) Microsoft Corp 1981-1997.  All rights reserved.

 Assembling: file.asm
file.asm(5) : fatal error A1000: cannot open file : \masm32\includes\masm32rt.inc

file.asm

Code: [Select]
;inkb - dedndave

;--------------------------------------------------------------------------

      include \masm32\includes\masm32rt.inc

        .data

AscChar     db ?,13,10,0
WordCounter db ?

;--------------------------------------------------------------------------

        .code

start   proc
       
mov WordCounter, 0
print   chr$('Huo Codec - Copyright (c) 2012'),13,10
echo test

startLoop:
        add WordCounter, 1
call    crt__getch
add     al     , 2
mov     AscChar, al
invoke  StdOut , offset AscChar
;print   offset AscChar
;print   str$(offset AscChar)

invoke  locate, WordCounter, 1
cmp     al, 5
;cmp    AscChar, 'q'
;jz      endLoop
        ;je      endLoop
jne     startLoop
;jmp     startLoop

    ;INVOKE crt__getch
    ;.IF (eax == 0) || (eax == 0E0h)
    ;    INVOKE crt__getch
    ;.ENDIF


endLoop:

start   endp

end     start

I think something isn't configured correctly but I have no idea what it might be.

dedndave

  • Member
  • *****
  • Posts: 8827
  • Still using Abacus 2.0
    • DednDave
Re: Can't find any included file in \masm32\includes
« Reply #1 on: December 09, 2012, 02:44:07 AM »
the folder name does not end with an "s"
\masm32\includes\masm32rt.inc
\masm32\include\masm32rt.inc

localhost

  • Guest
Re: Can't find any included file in \masm32\includes
« Reply #2 on: December 09, 2012, 03:01:34 AM »
Code: [Select]
Assembling: file.asm
file.asm(5) : fatal error A1000: cannot open file : \masm32\include\masm32rt.inc

Every where I look it uses that same path to include files, but it won't work for  me. I installed masm on drive D, so if I try to include D:\masm32\etc, it works, but then all .inc files include other files with \masm32 and I get the same error for each include.

dedndave

  • Member
  • *****
  • Posts: 8827
  • Still using Abacus 2.0
    • DednDave
Re: Can't find any included file in \masm32\includes
« Reply #3 on: December 09, 2012, 03:10:08 AM »
the masm32 folder should be installed in the root of whichever drive you are assembling from
and - the files you are building should be on the same drive

is that the case ?

it's ok to use a folder like this...
C:\masmprojects

but, the masm32 folder must then be
C:\masm32

Magnum

  • Member
  • *****
  • Posts: 2354
Re: Can't find any included file in \masm32\includes
« Reply #4 on: December 09, 2012, 03:10:56 AM »
I am getting the same error.

I will look into it.

Andy
Take care,
                   Andy

Ubuntu-mate-18.04-desktop-amd64

http://www.goodnewsnetwork.org

localhost

  • Guest
Re: Can't find any included file in \masm32\includes
« Reply #5 on: December 09, 2012, 03:11:28 AM »
the masm32 folder should be installed in the root of whichever drive you are assembling from
and - the files you are building should be on the same drive

is that the case ?

Ah... that might be it.

localhost

  • Guest
Re: Can't find any included file in \masm32\includes
« Reply #6 on: December 09, 2012, 03:13:39 AM »
Yes, that's the problem. I installed masm on drive D, but was trying to compile from drive C. Thank you!

Magnum

  • Member
  • *****
  • Posts: 2354
Re: Can't find any included file in \masm32\includes
« Reply #7 on: December 09, 2012, 03:13:44 AM »
Did you do it with Console Build All ?

Andy
Take care,
                   Andy

Ubuntu-mate-18.04-desktop-amd64

http://www.goodnewsnetwork.org

henryhuo

  • Guest
Re: Can't find any included file in \masm32\includes
« Reply #8 on: January 25, 2013, 06:36:52 PM »
\masm32\include\masm32rt.inc


c:\ ?
d:\?

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 7541
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Can't find any included file in \masm32\includes
« Reply #9 on: January 25, 2013, 07:53:18 PM »
Guys, MASM32 is designed to only work on the partition it is installed on so that it does not interfere with other installations like C compilers, other assembler etc ....
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

dedndave

  • Member
  • *****
  • Posts: 8827
  • Still using Abacus 2.0
    • DednDave
Re: Can't find any included file in \masm32\includes
« Reply #10 on: January 25, 2013, 11:51:12 PM »
in other words, the project you are assembling must be on the same drive as the masm32 folder
and - it makes things easier if you installed the masm32 package into the root of that drive

let me see....
hotkey   :P

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 7541
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Can't find any included file in \masm32\includes
« Reply #11 on: January 26, 2013, 02:19:16 AM »
It will only install in the masm32 folder on the partition of your choice, if you then move it, it won't work as the paths will be incorrect.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

Vortex

  • Member
  • *****
  • Posts: 2336
Re: Can't find any included file in \masm32\includes
« Reply #12 on: January 26, 2013, 06:35:36 AM »
Hi localhost,

Moving the source files to the partition hosting the Masm32 installation is the best solution. If you wish to use different partitions :

Code: [Select]
set CurrDrive=%~d0

set CurrPath=%~p0

set FullPath=%CurrDrive%%CurrPath%

D:

cd \

\masm32\bin\ml /Fo%FullPath%WriteConsole.obj /c /coff %FullPath%WriteConsole.asm
\masm32\bin\polink /SUBSYSTEM:CONSOLE %FullPath%WriteConsole.obj /OUT:%FullPath%WriteConsole.exe

%CurrDrive%

Assumptions :

Source code -> C:\example ( or any other directory in C: )
Masm32 -> D:\masm32