PORTING APLMT TO A NEW PLATFORM
==============================================================================
General instructions porting APLMT to a target  platform.  NOTE: ONLY the
intefaces listed in this file have dependencies on the target platform and
require porting.


Porting the System Interfaces (aplmt/system/*api.h)
------------------------------------------------------------------------------
1. Create a new platform specific directory tree under the apl/targets/
   directory.

2. The following interfaces must be implemented:
        aplmt/system/sysapi.h

3. Create a 'platform/' directory to contain the 'mapping' header files that
   are created in step 4.  

4. Create a 'mapping' header file for each of the above the interface files. 
   Each mapping file is responsible for providing concrete definitions for
   all of the methods, types, constants, etc. 'declared' in the interface 
   file.  See the following directories for example mappings:
        aplmt/platmappings/posix/userapp 
        aplmt/platmappings/xmk/minimal 

5. Create an 'adaptor' code that is require to map the APLMT interface to the
   underlying platform OS/Kernel.  Typically, this code is placed in a
   sub-directory in the aplmt/system directory tree, but it can reside 
   anywhere.



Porting the OS/Kernel (aplmt/os/*api.h)
------------------------------------------------------------------------------
1. The following interfaces must be implemented:
        aplmt/os/kernelapi.h
        aplmt/os/mutexapi.h
        aplmt/os/semaapi.h
        aplmt/os/privateapi.h

2. If not using the 'platform/' directory created in step 3 from porting the
   system interface, create a 'platform/' directory to contain the 'mapping' 
   header files that are created in step 3.  
   Note: There can be multiple 'platform/' directories.  The only requirement 
         is that there is one and only 'mapping' header file per interface 
         file.

3. Create a 'mapping' header file for each of the above the interface files. 
   Each mapping file is responsible for providing concrete definitions for
   all of the methods, types, constants, etc. 'declared' in the interface 
   file.  See the following directories for example mappings:
        aplmt/platmappings/posix/userapp 
        aplmt/platmappings/xmk/minimal 

4. Create an 'adaptor' code that is require to map the APL interface to the
   underlying platform OS/Kernel.  Typically, this code is placed in a
   sub-directory in the aplmt/mt directory tree, but it can reside anywhere.


Porting the logging interfaces (aplmt/logging/*api.h)
------------------------------------------------------------------------------
The logging intefaces are 'partially' dependent on the target platform.  For
the most part the logging interfaces are built on top of the kernel and
system intefaces.  However, there are some exceptions.  For example, the
XSLOG interface has methods such as: Aplmt_xsLogThread(), Aplmt_xsLogSysTime().  
These method ARE dependent on the platform's implementation of the SYSMT
interface (aplmt/system/sys.h). 

1. The following interfaces have platform dependences:
        aplmt/logging/xslogapi.h

2. If not using the 'platform/' directory created in step 3 from porting the
   system interface, create a 'platform/' directory to contain the 'mapping' 
   header files that are created in step 3.  
   Note: There can be multiple 'platform/' directories.  The only requirement 
         is that there is one and only 'mapping' header file per interface 
         file.

3. Create a 'mapping' header file for each of the above the interface files. 
   Each mapping file is responsible for providing concrete definitions for
   all of the methods, types, constants, etc. 'declared' in the interface 
   file.  See the following directories for example mappings:
        aplmt/platmappings/posix/userapp 
        aplmt/platmappings/xmk/minimal 

4. Create an 'adaptor' code that is require to map the APL interface to the
   underlying platform OS/Kernel.  Typically, this code is placed in a
   sub-directory in the aplmt/logging directory tree, but it can reside 
   anywhere.
