Mail Archives: djgpp/2003/09/02/11:17:31
Hi!!!
I am using a make file for creating a bin file out of many C files. I
am using win2k cmd shell
with djpp gcc version 3.1 installed with GNU Make version 3.79. The
version of ld is 2.13.
My src for the makefile is
----------
objects = kernel32.o pic.o stdio.o keyboard.o gdt.o string.o idt.o
asm_c.o screen.o writexy.o
login.o
allobjects = $(objects) asm.o
header = include/stdio.h \
include/pic.h \
include/gdt.h \
include/types.h \
include/string.h \
include/idt.h \
include/asm.h \
include/screen.h \
include/keyboard.h \
include/keydefs.h \
include/login.h \
include/writexy.h
kernel32.bin : $(objects) asm.o
ld -Ttext=0x9000 -o kernel32 $(allobjects) -e 0x0
objcopy -R .note -R .comment -S -O binary kernel32 kernel32.bin
$(objects) : $(header)
asm.o :
nasm -f coff asm.asm
--------------
Now if i run "make" it returns the error
make: execvp: ld: Invalid argument
make: *** [kernel32.bin] Error 127
I removed the login.o from the compilation( objects variable ) and
added the functions from
login.c in kernel32.c, so that it will be included in kernel32.o, and
the binary file gets
created smoothly in that way. Does ld have any maximum number of files
limitation which can be
included to it from the command line or the make file??
I tried to remove all the .o files in the directory and started a
fresh make, and even that didnt
seem to work.
I am really stuck with this.!!! Any help will be really appreciated.
Regards,
R Karthick
- Raw text -