Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Java MakeFile doesnt make in Linux

Status
Not open for further replies.

devilhimself

Programmer
Nov 17, 2003
4
US
I have a makefile which on successful make should create the class files of the appropriate Java source code.

When I give 'make -f applet.mak' following at the Linux prompt, I get the following message:

: No such file or directoryrc/web/applet/AppletProxy.java: line 1: /*
/home/vivarkey/102000/wtg/src/web/applet/AppletProxy.java: line 2: syntax error near unexpected token `('
/home/vivarkey/102000/wtg/src/web/applet/AppletProxy.java: line 2: ` * Copyright (c) 1998-1999 by 'XYZ Corporation. All rights reserved.
make: *** [/home/vivarkey/Build102000/release/lib/web/applet/AppletProxy.class] Error 2


It actually reads the commenst in the Java source code and then throws up errors.

Please advise on how to make the compile successful.
The following is the makefile I have.


#Start of applet.mak--------------------------->
include globals.mak

CMDLINE= -d $(CLASSDIR) $(JAVACFLAGS) -classpath $(CLASSPATH)

PACKAGE=web/applet
SOURCEDIR=$(SRCHOME)/$(PACKAGE)
TARGETDIR=$(CLASSDIR)/$(PACKAGE)

.SUFFIXES: .java .class

CLASSES = \
$(TARGETDIR)/AppletProxy.class \
$(TARGETDIR)/DBConnection.class \

all: bin $(CLASSES)

$(TARGETDIR)/%.class : $(SOURCEDIR)/%.java
javac $(CMDLINE) $?
clean:
rm -f $(TARGETDIR)/*.class
bin:
if [ ! -d $(TARGETDIR) ]; then
mkdir $(TARGETDIR);
fi
#<----------------------Finish
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top