  INIIMGCIR: Image Initialization and Circularity? 
 The Question is:
 
I'm getting an error when I try to run a COBOL compiled exe program.
 
%IMGACT-F-INIIMGCIR, cannot initialize image involved in a circularity
 
I have never seen this error before and I'm wondering if you could shed some
light on it??
 
Thanks,
Scott Hughes
 
 
 The Answer is:
 
  The image activator is required to activate images and to call image
  initialization routines (LIB$INITIALIZE psects) in the appropriate
  order -- INIIMGCIR indicates that the image activator cannot determine
  the order, and has in fact found a loop.
 
  The image activator accomplishes "image fixup" in two passes.  On the
  first pass, address references within each image are relocated, based
  on where each image is located in process virtual address space.  On the
  second pass, references between images are fixed up.  By the, the process
  virtual address for all routines and static data have been resolved, so
  order is insignificant.
 
  However, the image activator carefully maintains a list of images by
  reference order -- which is unrelated to load order.  Only images with
  initialization routines need be represented in this list.  Circular
  references in images means the image activator cannot determine a
  correct ordering for this list.
 
  For example, if an initialization routine in image A calls a routine in
  image B, then the initialization routine for B must be called before the
  initialization routine in A.  The image activator cannot determine if the
  initialization routine in A might actually call any routine in B -- much
  less whether any routine called might be sensitive to initialization
  having been run.  So, OpenVMS assumes the worst case and produces an
  error, rather than generating what could be sporadic results.
 
  In other words, even if you think there are no dependencies in the code,
  real dependencies can exist.  Even when there is no actual circular
  dependency, there could be some dependencies on activation order.
 
