views:

1294

answers:

8
+14  A: 

I've had good success with SCons. It's built with Python and the build scripts are actually Python scripts themselves, which gives a great deal of expressive power. From the web site:

SCons is an Open Source software construction tool—that is, a next-generation build tool. Think of SCons as an improved, cross-platform substitute for the classic Make utility with integrated functionality similar to autoconf/automake and compiler caches such as ccache. In short, SCons is an easier, more reliable and faster way to build software.

Greg Hewgill
+10  A: 

I have heard good things about CMake which tries to solve the same problems. Here is the wikipedia article

epatel
Using it for a long time and no major issues.
Anonymous
I would suggest the same thing. I made myself this question some time ago, and came to conclusion that CMake is the right answer.
Juliano
Thanks, it looks like Cmake will do exactly what I need. These days, if I even WHISPER 'autoconf' villagers with torches and pitchforks show up at my desk :|
Tim Post
+1  A: 

I have had a look at CMake, which looks like a good alternative unless you are cross-compiling. If you are doing native compilation, you should try it

shodanex
A: 

There's a python version of make being created at Mozilla - pymake - which presumably supports cross-platform use.

Pete Kirkham
+7  A: 

There are a lot of different alternative Makefile generators and build systems out there:

Also available, but not stringently targeted on C/C++:

  • Premake
  • Ant (for Java)
  • Rake (for Ruby)
  • (Definitely more, I just don't know them all...)

But after listing these all, autotools have the great advantage of not requiring any other dependency for the end-user. A configure script is only generated once by the developer and does not require anything special on the user end, as it is a shell script. The tools listed above have to be installed before anyone can build your source and they even might have dependencies themselves.

Raim
A configure script needs a sh compatible shell, which is something special on a windows machine.
Caotic
So what is the point if you need additional software anyway on Windows? No difference if you install python or some shell.
Raim
A: 

For building C/C++ software from ANT or maven you might be interested in terp. It includes a portable C++ compiler task that works with many C++ compilers on many platforms.

+3  A: 

I'm getting chance to be downovted but, I must admit, that unforutnatly there is no real replacement of autotools. CMake, SCons, bjam are nice but, when it comes to some serious job... it is quite clear that autotools are suprior, not because CMake can't do the same, it is just much harder.

For example, CMake, the most popular alternative to autotools

  • No support of gettext. This may be real problem when you need to manage a lot of translations and translated source code.
  • No support of uninstall target. It is quite unplesant to find out, that you can't uninstall the program you installed.
  • No automatic build of both shared and static libraries.
  • Documentations is very limited and bad.

And so on.

There are still many other points. Unfortunaly, there is no real high quality replacement of autotools. On the other hand, if you develop of Windows and for Visual Studio, then you can't use autotools and you need to choose CMake that provides such tools.

Artyom
+1  A: 

How about simply using Make and pkg-config?

Here is a Makefile template to get you started.

Less is more people.

hendry