[MERGE] SourceLayout: src/base, take 0

From: Alex Rousskov <rousskov_at_measurement-factory.com>
Date: Thu, 19 Feb 2009 00:23:33 -0700


    In preparation for src/{ICAP,eCAP} move to src/adaptation, I needed
to move AsyncJob.* files away from src/ICAP/. I have decided to put them
into the new src/base directory until a better place is found. While
adding src/base, I discovered and started to fix a few problems with
adding more src/ subdirectories.

These changes are small steps towards a nice layout. I wanted to post
them anyway because they affect a couple of strange places in our
Makefiles (e.g., src/ip found in the top-level Makefile and seemingly
bogus cf_gen dependencies).

I also wanted to ask whether AsyncJob and related Async* classes belong
to src/base/ or their own subdirectory. If we want a separate dir,
should we use src/jobs/ or perhaps src/calls (keeping in mind that not
all calls are between jobs and that jobs do more than just async calls)?
Probably not src/async as that clashes with I/O APIs.

Detailed change log is below.

Thank you,


=== modified file 'Makefile.am'

Removed src/ip from the top-level SUBDIRS list. That directory is not
a top-level subdirectory and it is already listed in src/Makefile.am.

The commit message introducing the change talked about libip being a "POD
library". I do not know what that is, but, hopefully, we do not really
need to
make this kind of exceptions for any src/ libraries.

=== added file 'src/common.am'

Copied common Makefile.am stuff seen in a few Makefile.ams to a single
Makefile "header". This avoids evil code duplication. This file should be
included by most Makefile.ams inside src/. Needs more work as some of the
copied code is questionable and more code can probably be extracted
here. See

TODO: The .h dependency test script part seems pretty universal, but if
many subdirs need to customize it, we may want to put it into a separate
Makefile "header".

=== modified file 'src/AsyncJobCalls.h'
=== modified file 'src/BodyPipe.h'
=== modified file 'src/Server.h'
=== modified file 'src/adaptation/AccessCheck.h'
=== modified file 'src/adaptation/Initiate.h'
=== modified file 'src/adaptation/Initiator.h'
=== modified file 'src/client_side.h'
=== modified file 'src/client_side_request.h'

Moved src/ICAP/AsyncJob.* to src/base/ to prepare for the src/ICAP move to

=== added dir 'src/base'
=== added dir 'src/base/Makefile.am'
=== modified file 'src/Makefile.am'
=== modified file 'configure.in'

Added src/base directory for fundamental, commonly-used code pieces that are
not large enough to warrant their own directories. Currently base/ contains
the beginning of AsyncCalls hierarchy, which may eventually get its own

=== modified file 'src/Makefile.am'

Reduced cf_gen dependencies so that it can be built before subdirectories,
as, apparently, required by BUILT_SOURCES.

Moved some libraries that are used by virtually all executables to
The list will probably grow as we try to reduce the insane complexity of the
current Makefile.am.

Received on Thu Feb 19 2009 - 07:23:31 MST

This archive was generated by hypermail 2.2.0 : Thu Feb 19 2009 - 12:00:03 MST