Hi Andreas
Andreas Ntaflos wrote: > Hello list, > > I think this shouldn't be too difficult, but I couldn't find it in the > automake manual (possibly because I don't know exactly what to look > for). > > My project consists of $(topdir)/src/server and $(topdir)/src/client. > Issuing `./configure && make' in $(topdir) correctly builds server and > client, two otherwise unrelated programs. > > I would like to be able to issue `make' to build both (current > behaviour) as well as `make server' and `make client' to build them > separately if I want to do so. > > I'd appreciate it if anyone could point me to the right section in TFM > or give me clues how to configure my project for the desired behaviour. > > Thanks in advance! > > Andreas > A suggestion is to add convenience targets in your Makefile.am : client : $(MAKE) -C src/client all server : $(MAKE) -C src/server all both : client server (not really needed, since make all will do that anyway) If the client and server *really* have a separate code base, you can also have two projects instead of one, so that distributing a tarball with fixes on only one side can be done independently of the other, but see below. A reason to have client and server code in the same project is when a common library is used by both, for example to implement the protocol between the two (common header file + code or an XML schema for the messages or *something*), so that this code is not duplicated. In that case, the client and server code base are not so independent, they both depends on the common protocol, so likely there are 3 major subdirectories in the code base (client, server, protocol). client : protocol $(MAKE) -C src/client all server : protocol $(MAKE) -C src/server all protocol : $(MAKE) -C src/protocol all Hope this helps, Marc Alff.