Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Makefile

 
Jiafan Zhou
Ranch Hand
Posts: 193
Fedora Linux Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I know that Ant has big advantage over a normal build process like Makefile.

Whereas still a lot of project use Makefile as their building tool..and I am not familiar with the Makfile and I appreciate any explanation on the Makefile..

for example:
if I have the following Makefile:


How does this Makefile work?

Kind regards,
Jiafan
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24212
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm in the minority, I know, but I don't feel that Ant does have any advantages over make except for the portability issue: Ant will work on a stock Windows distribution, whereas make would need a whole set of supporting tools like the Cygwin environment to be useful. But if your development platform is not Windows (and I honestly feel sorry for people stuck developing on Windows) then Make can do a lot more things, a lot more easily, than Ant can. Sadly, most Java developers are on Windows.

In any case, as far as this file goes, it really doesn't do anything except include some other (presumably much larger) Makefile that does do something.
[ September 21, 2006: Message edited by: Ernest Friedman-Hill ]
 
Jiafan Zhou
Ranch Hand
Posts: 193
Fedora Linux Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

A nice introduction for MakeFile, Ernest. I dont believe that you have posted over 10 thousand threads in the Javaranch..

You can write a book for that amount.

Could you or anybody else introduce me a book on Makefile..because I need to be more familiar with this building tool.

Thanks,
Jiafan
 
Anand Hariharan
Rancher
Posts: 272
C++ Debian VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Ernest Friedman-Hill:
I'm in the minority, I know, but I don't feel that Ant does have any advantages over make except for the portability issue: Ant will work on a stock Windows distribution, whereas make would need a whole set of supporting tools like the Cygwin environment to be useful. But if your development platform is not Windows (and I honestly feel sorry for people in that position) then Make can do a lot more things, a lot more easily, than Ant can. Sadly, most Java developers are on Windows.


Very insightful. Thank you.

I have spent several years wrestling with Makefiles, but have not a clue on Ant. A certain individual found me to be "immature" -- saying that I dabble with needlessly low level stuff and find happiness in doing so, only in knowing that I am in the minority (i.e., that I can solve problems with Make that few other people can, and (his contention was that) my knowing this is what gives me happiness).

Also, people find me old-fashioned for using MinGW/MSYS and Vim whenever I work on a Windows box.

sincerely,
- Anand Hariharan
 
Jiafan Zhou
Ranch Hand
Posts: 193
Fedora Linux Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you makefile expert guys introduce me some tutorial to get start with makefile please?

Regards,
Jiafan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic