[Insight-users] Programmer work space

Neil Killeen Neil.Killeen@atnf.csiro.au
Mon, 3 Mar 2003 13:28:47 +1100 (EST)


Hi all

Having developed a toy-medical imaging platform that
uses itk and vtk, I now would like to get on with
fleshing it out properly and open it for business.

The main remaining issue for me is how to manage programmer work spaces.

So:

. I have created a system along the lines of

   /oursystem/code/applications/app1
                              /app2
                 /modules     /module1
                              /module2

             /binary/linux  /lib
                            /bin
                    /sun4sol/lib
                            /bin


etc.

. This filesystem will be administered via cvs

. Regular (daily/weekly) builds will regenerate the various platforms (linux and solaris
   here)

. Now I have a team of developers who I wish to share this system and
  develop with it.  How is the best way to manage their work space ?

  I imagine that

  - Each programmer maintains a parallel copy of the code tree
    presumably via cvs.  It is only populated by the pieces of code
    that they are working on.


    /myhome/oursystem/code/modules/module1
                                  /module2/segment.cxx
                                           segment.h
                          /applications/app1
                                       /app2/segmenter.cxx

   So here the programmer is only working on class 'segment' in module2
   and application 'segmenter' in app2, which uses this module.


  - Each programmer has their own binary output location in their
    directory tree

    /myhome/oursystem/code/...

                     /binary/linux/lib
                                  /bin

  - To build and test their code, the programmer should presumably
    be able to link with what ever library they have built locally
    plus the system libraries.

    So for example, if the programmer is working in module2 on class
    'segment' and wishes to test application 'segmenter'

    They should be able to build module2.a from segment.cxx; the system
    looks for all  code and include files  in their local tree
    first, and then  in the /oursystem/code  tree if its not there.
    I.e. they should  only need to populate the piece of the code tree that they
    are working on.  The  resultant library goes to their personal binary
    output location.

    Then when they link segmenter, it uses the library (module2.a) in
    their  own binary tree plus the system ones in /oursystem/binary/lib/*.a

    I.e. I want to avoid every programmer having to have a copy of the
    entire system which they are forever buildng and keeping up to date.




Is this the way ITK for example, manages development ?   If so,
I have no idea how to configure the system (CMake) so that
it recognizes system and programmer workspaces, building
appropriately.

The brute force way would appear to be that in the programmers
binary directory, the top-level CMakeCache.txt file would
need to be reconfigured in some way - it would need to reference
their own code tree as well as the system one.

I have not seen any documentation on this subject, for example,
in the documents on making your own project.

Hoping this is  easier than I seem to be making it...


regards
Neil