Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Help with Linux makefile

  1. #1
    Junior Member
    Join Date
    Jun 2010
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Help with Linux makefile

    Hello there..

    After four days of attempts.. I have yet to complete what should be a VERY VERY simple task.
    Creating a linux makefile..

    I have created a project on Windows using Netbeans.. never having experience in Linux, my professor will not accept anything but a makefile that will run in a Linux environment..

    I have resorted to using a friend's laptop for a few days since he is running Ubuntu.
    I installed Java sdk.. I have gotten as far as navigating to the directory and able to do a

    Javac Main.java Course.java Rooms.java CSVParser.java CSVReader.java

    and that compiles with warnings but no errors.. I then tried to run
    Java main

    but that failed saying it cannot find the class..

    RapidShare: 1-CLICK Web hosting - Easy Filehosting

    Here is a link to my netbeans project.. Any pointers or suggestions is GREATLY appreciated. Also, here is the makefile I am attempting to use..
    JFLAGS = -g
    JC = javac
    .SUFFIXES:	.java	.class
    .java.class:
    	$(JC)	$(JFLAGS)	$*.java
    CLASSES = \
    	Main.java \
    	Course.java \
    	Rooms.java \
    	CSVParser.java \
    	CSVReader.java 
     
    default: classes
     
    classes: $(CLASSES:.java=.class)
     
     
     
    clean: 
    	$(RM) *.class

    Please help!!

    P.S. I have posted this on two other java forums but no luck


  2. #2
    Member
    Join Date
    May 2010
    Posts
    38
    Thanks
    1
    Thanked 8 Times in 7 Posts

    Default Re: Help with Linux makefile

    Why not give him a JAR file with the executable attribute set? That way all he has to do is double click it.

    If your teacher wants the source code, tell your teacher you're doing what most java developers out there do and include a separate file called src.zip which has your entire netbeans project folder.

Similar Threads

  1. miniBuilder on Linux- java errors
    By nwtjv in forum Exceptions
    Replies: 0
    Last Post: March 25th, 2010, 06:54 AM
  2. Under Windows OS, how to call *.EXE produced in Linux OS?
    By tony_lincoln in forum What's Wrong With My Code?
    Replies: 2
    Last Post: March 19th, 2010, 12:51 AM
  3. Executing Linux Commands with Java GUI
    By linuxrockers in forum AWT / Java Swing
    Replies: 2
    Last Post: February 15th, 2010, 10:57 PM
  4. getting files in the linux server
    By Truffy in forum Java Networking
    Replies: 36
    Last Post: June 22nd, 2009, 06:32 PM