flat assembler
Message board for the users of flat assembler.

Index > Windows > 1.69.34

Author
Thread Post new topic Reply to topic
JM1130



Joined: 25 Oct 2011
Posts: 3
JM1130 28 Oct 2011, 23:28
I am new to assembly programming and recently downloaded fasm 1.69.34 for windows. I had the 1.69.31 version before. When i try to use files such as 'win32axp.inc' with the include instruction before it, it gives me a 'file not found' error. What am I doing wrong?
Post 28 Oct 2011, 23:28
View user's profile Send private message Reply with quote
Enko



Joined: 03 Apr 2007
Posts: 676
Location: Mar del Plata
Enko 28 Oct 2011, 23:40
you should edit FASMW.INI
Code:
[Environment]
Include=C:\fasm\INCLUDE
    

Put in Include, the directory where INCLUDE folder is located

The other option is to add to windows enviorment variable PATH the include directory.
Post 28 Oct 2011, 23:40
View user's profile Send private message Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4324
Location: Now
edfed 29 Oct 2011, 01:56
on fasmw 1.69.31, and now fasmw 1.69.34:
Code:
[environment]
include=c:/fool
include=c:/fasmw/include
    

it doesn't work, it don't give a simple way to build a fasm full working environment.

later, i'd like to add
Code:
include=c:/opengl
include=c:/etc...
    

but environment seems to just use the first include= occurence.

that's would be really nice to let it work, in order to include files from many different librairies, without bothering where they are. Smile
Post 29 Oct 2011, 01:56
View user's profile Send private message Visit poster's website Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 8268
Location: Kraków, Poland
Tomasz Grysztar 29 Oct 2011, 08:19
This is an environment variable, the fact that you are able to set it up from .INI file is just for your convenience, but still the same rules apply, as for the environment variables.
INCLUDE variable is semicolon-separated, as this is standard for such environment variables:
Code:
[Environment]
include=c:/fasmw/include;c:/opengl    
Post 29 Oct 2011, 08:19
View user's profile Send private message Visit poster's website Reply with quote
typedef



Joined: 25 Jul 2010
Posts: 2909
Location: 0x77760000
typedef 29 Oct 2011, 12:28
Here's a program that I made that solves that.

Just put it where your FASM bundle is at and run it. it will update FASMW.INI or create a new one if it does not exist.

NOTE: As of FASM 16931 (But works with current one)

Code:
format pe gui 4.0

entry start

include 'win32ax.inc'

section '.blob' code readable executable writeable

path rb 100h
ini  db 'INCLUDE'
buff rb 110h
iniFile rb 100h

key db 'Include',0
env db 'Environment',0

start:
 push path
   push 100h
   call [GetCurrentDirectory]

      ;ini file section
   cinvoke wsprintf,buff,'%s\INCLUDE',path    ;OK

       ;ini file location
  cinvoke wsprintf,iniFile,'%s\FASMW.INI',path ;OK

     ;Attempt a fix
      invoke WritePrivateProfileString,env,key,buff,iniFile
ret

section '.idata' import data readable

library user32,'user32.dll',\
 kernel32,'kernel32.dll'

include 'api/kernel32.inc'
include 'api/user32.inc'
    
Post 29 Oct 2011, 12:28
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2023, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.