Library Clause
  
    
    
     
   
   Formal Definition
  
   A library clause defines logical
   names for design libraries in the host environment. 
  
   Simplified Syntax
  
   library library_name; 
  
   Description
  
   The library clause defines 
   the logical names of design libraries, which are used by the design 
   units. A library is a storage facility for previously analysed design 
   units. In practice, this relates mostly to packages. 
  
   When a package is to be used in a design, it has to be made visible 
   to the design. In order to specify it, the library
    clause (making the library visible) and use
    clause (making particular declarations visible) must be used. 
   See use clause for more details. 
  
   There are two predefined libraries, which are used implicitly in 
   every design: STD and WORK. The first of them contains standard 
   packages STANDARD and TEXTIO. The other is a working library, where 
   all user-created and analysed design units are stored. 
  
   User-specified packages are stored in the working library WORK. 
  
   Examples
  
   library IEEE; 
   use IEEE.Std_Logic_1164.all; 
  
     
   Such declarations as in the above example must precede each design 
   entity, which uses any of the declarations in the package Std_Logic_1164. 
  
   Important Notes
  
   - 
   
    A library specified in a library clause of the primary design unit 
    (entity, configuration or package) is visible in each secondary unit 
    (architecture or package body) associated to it. 
    - 
   
    Library STD (containing packages STANDARD and TEXTIO) need not to be 
    specified. Both packages are automatically included in every design unit. 
    - 
   
    Package Std_Logic_1164 is specified in the library IEEE. The library
     IEEE clause must be used in design units, which will use this package. 
    - 
   
    Library clause may contain more than one library names separated by commas. 
     
  
    
 
    |