www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/10/25/21:49:30

Message-ID: <3BD8BDA4.5080408@earthlink.net>
From: "Micah J. Kimbrough" <sciencecenter AT earthlink DOT net>
Organization: The Community Science Center
User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:0.9.2) Gecko/20010726 Netscape6/6.1
X-Accept-Language: en-us
MIME-Version: 1.0
Newsgroups: comp.os.msdos.djgpp
Subject: Problem linking with gcc
Lines: 134
Date: Fri, 26 Oct 2001 01:37:14 GMT
NNTP-Posting-Host: 168.191.184.176
X-Complaints-To: abuse AT earthlink DOT net
X-Trace: newsread2.prod.itd.earthlink.net 1004060234 168.191.184.176 (Thu, 25 Oct 2001 18:37:14 PDT)
NNTP-Posting-Date: Thu, 25 Oct 2001 18:37:14 PDT
X-Received-Date: Thu, 25 Oct 2001 18:33:24 PDT (newsmaster1.prod.itd.earthlink.net)
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Hello,
     I am trying to compile and link a program with gcc that came with 
djcpp. I tried entering the link command manually like gcc.exe -o 
file.exe file.o file.o file.o ... etc. -lm  and I modified the makefile 
to use gcc and ran it as well and it still will not link under Windows 
98 dos shell. What it is seems to be doing is cutting off the link 
command even when running the make file. This is the error I get: 
gcc.exe: fil No such file or directory (ENOENT). Notice that file.o is 
fil, I meant to do that because it is cutting off the actual file name 
when I run make. I can add parameters to the makefile and manually and 
it cuts it off at a different place.

Any help would be appreciated.
Thank You,
Micah J. Kimbrough


This is the Makefile


TARGET = "NT386"

PACKAGE = quake
PROGRAM = quake

#
# parser.y generates y.tab.h for lexical.c, so parser.o must come first
#

OBJECTS = \
    parser.o \
    lexical.o \
    array.o \
    atom.o \
    hash.o \
    builtin.o \
    code.o \
    dict.o \
    execute.o \
    fileio.o \
    iostack.o \
    list.o \
    name.o \
    operator.o \
    path.o \
    quake.o \
    table.o \
    stack.o \
    strng.o \
    utils.o

SRC = ../src
LOCAL = .

SOURCES = \
    $(SRC)/parser.c \
    $(SRC)/lexical.c \
    $(SRC)/array.c \
    $(SRC)/atom.c \
    $(SRC)/hash.c \
    $(SRC)/builtin.c \
    $(SRC)/code.c \
    $(SRC)/dict.c \
    $(SRC)/execute.c \
    $(SRC)/fileio.c \
    $(SRC)/iostack.c \
    $(SRC)/list.c \
    $(SRC)/name.c \
    $(SRC)/operator.c \
    $(SRC)/path.c \
    $(SRC)/quake.c \
    $(SRC)/table.c \
    $(SRC)/stack.c \
    $(SRC)/strng.c \
    $(SRC)/utils.c

MAKEFILE = $(SRC)/makefile

DEBUG_DEFINES = # -DDEBUG_RANGE_CHECKING -DDEBUG_MALLOC -DHASH_PROFILE 
-DYYDEBUG

# If DEBUG_MALLOC is enabled include thes following two lines ...
#    INCLUDES = -I. -I$(SRC) -I../dbmalloc
#    LIBRARIES = -L../dbmalloc -ldbmalloc -lm
# ... otherwise, these line
INCLUDES = -I. -I$(SRC)
LIBRARIES = -lm -lc

DEFINES = -DTARGET_$(TARGET) $(DEBUG_DEFINES)

CC = gcc
## need
##   CC = cc -posix -Wno-precomp   on NEXT
##   CC = gcc                      on VAX and HPPA
##   CDEBUG = ""                   on HP300

YACC = bison -y
COPT =
CDEBUG = -g
CFLAGS = $(COPT) $(CDEBUG) $(INCLUDES) $(DEFINES)
YFLAGS = -d

all: $(PROGRAM)

$(PROGRAM): $(OBJECTS) $(MAKEFILE)
    $(CC) $(CFLAGS) $(OBJECTS) $(LIBRARIES) -o $@

clean:
    -rm -f $(PROGRAM) $(OBJECTS)

depend: $(MAKEFILE) $(SOURCES)
    makedepend -f$(MAKEFILE) $(INCLUDES) $(DEFINES) $(SOURCES)

array.o:    $(SRC)/array.c;    $(CC) -c $(CFLAGS) $(SRC)/array.c
atom.o:     $(SRC)/atom.c;     $(CC) -c $(CFLAGS) $(SRC)/atom.c
builtin.o:  $(SRC)/builtin.c;  $(CC) -c $(CFLAGS) $(SRC)/builtin.c
code.o:     $(SRC)/code.c;     $(CC) -c $(CFLAGS) $(SRC)/code.c
dict.o:     $(SRC)/dict.c;     $(CC) -c $(CFLAGS) $(SRC)/dict.c
execute.o:  $(SRC)/execute.c;  $(CC) -c $(CFLAGS) $(SRC)/execute.c
fileio.o:   $(SRC)/fileio.c;   $(CC) -c $(CFLAGS) $(SRC)/fileio.c
hash.o:     $(SRC)/hash.c;     $(CC) -c $(CFLAGS) $(SRC)/hash.c
iostack.o:  $(SRC)/iostack.c;  $(CC) -c $(CFLAGS) $(SRC)/iostack.c
lexical.o:  $(SRC)/lexical.c;  $(CC) -c $(CFLAGS) $(SRC)/lexical.c
list.o:     $(SRC)/list.c;     $(CC) -c $(CFLAGS) $(SRC)/list.c
name.o:     $(SRC)/name.c;     $(CC) -c $(CFLAGS) $(SRC)/name.c
operator.o: $(SRC)/operator.c; $(CC) -c $(CFLAGS) $(SRC)/operator.c
parser.o:   $(SRC)/parser.c;   $(CC) -c $(CFLAGS) $(SRC)/parser.c
path.o:     $(SRC)/path.c;     $(CC) -c $(CFLAGS) $(SRC)/path.c
quake.o:    $(SRC)/quake.c;    $(CC) -c $(CFLAGS) $(SRC)/quake.c
stack.o:    $(SRC)/stack.c;    $(CC) -c $(CFLAGS) $(SRC)/stack.c
strng.o:    $(SRC)/strng.c;    $(CC) -c $(CFLAGS) $(SRC)/strng.c
table.o:    $(SRC)/table.c;    $(CC) -c $(CFLAGS) $(SRC)/table.c
utils.o:    $(SRC)/utils.c;    $(CC) -c $(CFLAGS) $(SRC)/utils.c

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019