Hello all, and merry christmas from France !
My problem : i want to include a dll into my program and use dll functions.
I think of include dll in resource rcdata but after...
Second question : is it possible to use obj files (like minilzo.obj) ?
thanx for any help...
			
			
			
				
this may help http://www.ionicwind.com/forums/index.php/topic,1361.msg12771.html#msg12771 
			
			
			
				Thanx Copex for help.
Not easy but it works.
I look if its possible with obj files.
Thanx again.
			
			
			
				Zaphod, loading a .obj file is not so easy as loading dll from memory, because .obj file may import symbols not exported from dll's, and there is no info from which module a symbol is imported. Really, you'll need a mini-linker to load object files, and a function names table.
If you wish to use only data stored in object files, then this will be no problem. But to call code from .obj files when if the object file is importing symbols, then I think, the easiest way to "link" it would be using dbghelp.dll to translate function names to function addresses or offsets.
			
			
			
				Sapero, thanx for explanation.
Too difficult for me.
I give an example of use obj files in purebasic :
ImportC "minilzo.obj"
lzo1x_1_compress(*Source.l, SourceLength.l, *Dest.l, DestLength.l,*WorkMem.l)
lzo1x_decompress(*Source.l, SourceLength.l, *Dest.l, DestLength.l, *WorkMem.l)
lzo1x_decompress_safe(*Source.l, SourceLength.l, *Dest.l, DestLength.l,*WorkMem.l)
lzo_adler32(Adler.l, *Buf.l, Len.l)
;
lzo_version()
lzo_version_string()
lzo_version_date()
EndImport
			
			
			
				In ebasic just replace ImportC with $use, or add your .obj file to project. An obj file has the same format as .o file.