Quoting Keith MARSHALL <keith.marshall@...>:
> Noor Fatma wrote:
>> $(LIBFILE) : $(OBJFILE) $(MAKEFILE)
>> $(LD) --entry=0x409 $(OBJOUT)\galx86.obj -llibUSER32
>> cannot find llibUSER32
> What have you set $(LD) to? A common error is to try to invoke
> `ld' directly. This way, it doesn't know the proper paths to
> search for system libraries, unless you specify them explicitly.
> If you have `LD = ld', you should change it to `LD = gcc', (or to
> `LD = g++', if you are linking C++ code). That will pass the
> correct paths to `ld'.
> Note that you may also need to specify linker specific flags in
> the form, e.g. `-Wl,--entry=0x409'.
> Also note that GCC's default object file extension is `.o', not
> `.obj', but I assume you have your reasons for overriding that.
And also, the library name given to the linker needs to be given
without the lib prefix. With -llibUSER32 the linker is looking for a
file in the library paths for one of liblibUSER32.dll.a,
liblibUSER32.a, libUSER32.dll and libUSER32.lib. You would need to
specify -luser32 to ld for it to find the library file.