- create the java project in eclipse
- open eclipse.
- click file, new, project...
- choose java project.
- type a project name
- un-check use default location and click browse to find the root of your java project which contains your makefile
- click finish
- add make as a builder
- click on the project in the package explorer.
- click project, and then click properties.
- click builders, and then click new.
- choose program and click ok.
- in the location textbox, type "/usr/bin/make" (w/o quotes).
- warning: if this is not the location of the "make" program on your computer, determine the location by typing "whereis make" in a terminal window.
- in the working directory section choose browse workspace.
- choose your project, and click ok.
- under arguments, type "all", or the appropriate label in your makefile, plus any other arguments you wish to pass to make.
every programmer should have a blog. here is what i have to contribute to the blogosphere which makes coding 10x easier for me.
2012-04-28
using a makefile in an eclipse java project
if you have java code and rely on a makefile to compile, you can configure eclipse to build your project using your makefile as follows:
Subscribe to:
Post Comments (Atom)
Yes. Definitely worked for me. I have a lot of nested projects in a complex folder hierarchy that are all built with "make -f . Your instructions helped me to invoke the make and get them built. Thanks!
ReplyDeletegreat, this was exactly what I was looking for. Thanks! :)
ReplyDeleteThanks for the help. I'm in the Coursera compilers course ( https://class.coursera.org/compilers/ ) and this just helped me to get my virtual machine setup to work on the assignment in eclipse instead of gedit as I had been working.
ReplyDeleteworks great :) thanks :)
ReplyDeleteThanks. this works great for my group's development needs. :)
ReplyDeleteThis was very helpful!!!
ReplyDeleteYes. Definitely works for me!
ReplyDeleteGreat. Worked for me too! Thanks
ReplyDeleteThis comment has been removed by a blog administrator.
ReplyDeleteThis comment has been removed by a blog administrator.
ReplyDeletehi I have been searching for this information, In the warning message on 5th step, what is a terminal window...because I could not find the location of make file in my system. Thanks.
ReplyDeletehello, please see here:
Deletehttps://help.ubuntu.com/community/UsingTheTerminal
unfortunately because there are so many different flavors of linux, there's no easy way to explain how to open the terminal for command line access.
This also worked for me too, Thanks a ton.
ReplyDeleteThis comment has been removed by a blog administrator.
ReplyDelete