Welcome to Linux Knowledge Base and Tutorial
"The place where you learn linux"
Linux Tracker

 Create an AccountHome | Submit News | Your Account  

Tutorial Menu
Linux Tutorial Home
Table of Contents

· Introduction to Operating Systems
· Linux Basics
· Working with the System
· Shells and Utilities
· Editing Files
· Basic Administration
· The Operating System
· The X Windowing System
· The Computer Itself
· Networking
· System Monitoring
· Solving Problems
· Security
· Installing and Upgrading
· Linux and Windows

Man Pages
Linux Topics
Test Your Knowledge

Site Menu
Site Map
Copyright Info
Terms of Use
Privacy Info
Masthead / Impressum
Your Account

Private Messages

News Archive
Submit News
User Articles
Web Links


The Web

Who's Online
There are currently, 61 guest(s) and 0 member(s) that are online.

You are an Anonymous user. You can register for free by clicking here




       evltc   sourcefile  [-f | --func]  [-n | --noto]
               [-c | --cpp]  [cpp_options]


       evltc  binfile.to


       The evltc command reads the formatting template specifica­
       tion(s) in sourcefile and creates a binary  template  file
       for  each  specification.   sourcefile  may not define two
       templates with the same event_type, even if they  are  for
       different  facilities.   Binary  files  are created in the
       directory where sourcefile resides.

       If the name of the specified  file  ends  in  .to,  it  is
       assumed  to be a binary template file.  It is read, and if
       it contains an event-record  template,  the  corresponding
       sample call to the evl_log_write() function is printed, as
       with -f.  In this case, the -f and -n options  (if  speci­
       fied) are ignored, and any cpp-related options are flagged
       as errors.

       The binary file for  an  event-record  template  is  named
       eventtype.to,  where  eventtype  is  the hexadecimal event
       type.  For a facility's default template, the binary  file
       is named default.to.

       The  binary  file  for  a struct template is named struct­

       If the source file contains any errors,  no  binary  files
       are produced, and error messages are written to stderr.

       The algorithm for finding a struct template that is refer­
       enced by another template is as follows:

       (1) The struct_path from the import statement is converted
       into  a  relative  pathname  by replacing all periods with
       slashes  and  appending  .to.   For  example,   gui.graph­
       ics.point becomes gui/graphics/point.to.

       (2)  This relative pathname is applied to each of the fol­
       lowing directories in turn until a file is found:
        (a) the directory in which the  current  template  source
       file resides.
        (b) the directories specified in the EVLTMPLPATH environ­
       ment variable (a colon-delimited list of directories).  If
       the  EVLTMPLPATH  environment variable is not defined, the
       directories /var/evlog/templates/$LANG and /var/evlog/tem­
       plates are searched, in that order.
              matches the template.

       -n, --noto
              Compile the template source and  report  errors  as
              appropriate,  but  do not write out the binary tem­
              plate file(s).

       -c, --cpp
              Run  sourcefile   through   the   C   preprocessor,
              /lib/cpp,  and compile the result.  The contents of
              sourcefile are unchanged.

       -D  macro[=defn]
              Passed to the C preprocessor.  Implies -c.

       -U  macro
              Passed to the C preprocessor.  Implies -c.

       -I  dir
              Passed to the C preprocessor.  Implies -c.


       Example 1.

       Suppose the file VolMgr.t contains the following text.

       /* Start of first template */
       struct sourceInfo;
       attributes {
             string sourceFile;  int lineNumber;
       %sourceFile%: %lineNumber%:

       /* Start of second template */
       facility "VolMgr"; event_type 0x456;
       attributes {
             struct sourceInfo srcInfo;
             string volumeName;  ulong vsize;
       Created volume %volumeName% with size %vsize%.

       /* Start of third template */
       facility "VolMgr"; event_type 0x789;
       attributes {
             struct sourceInfo srcInfo;
             string diskName;  string diskGroup;
       in the file SCSIadap.t:

       /* HEADER SECTION */
          facility "LOCAL1";
          event_type 0x3115;
          const {
                string  repair_action = "Replace SCSI adapter";

          attributes {
               char    unit_ser_no[8]        "%s";
               ushort  lun                   "%u";
               char    sense_bytes[12]       "%t";
          /* For the next attribute, the various segments of
           * the format string are automatically concatenated
           * into a single string.
               uchar  recovery_stat  "%b/0x40/INTERFACE_WAS_RESET/"
          /* The final attribute specification says to display the
           * rest of the bytes in dump format.
          char            extra_data[_R_]     "%t";

          SCSI interface error: Adapter Ser Num/LUN = %unit_ser_no%/%lun%

          Recovery Status: %recovery_stat%
          Sense Bytes:

          Recommended repair action:


       The command
              evltc SCSIadap.t -f
       will create the file 0x3115.to in the same directory
       as SCSIadap.t and the following will be displayed
       (on stdout):

              evl_log_write(LOG_LOCAL1, 12565 /* 0x3115 */, severity, flags,
                         "char[]", 8, unit_ser_no,
                         "ushort", lun,
                         "char[]", 12, sense_bytes,

         [definition of struct statusRegister's attributes and format]
       import chipSet.fpu.statusRegister; /* LEGAL [unless chipSet/fpu
                                          specifies the current directory] */
       import chipSet.fpu.dataRegisters;
       attributes {
         struct statusRegister cpuStatus;      /* refers to struct
                                               defined in this file */
         struct chipSet.fpu.statusRegister fpuStatus;
         struct dataRegisters dataRegs;

       However, the following example has an illegal sequence of statements:

       struct statusRegister;
         [definition of struct statusRegister's attributes and format]
       import statusRegister;   /* ILLEGAL */


       /var/evlog/templates -  Formatting template repository

                         6 December 2002                 EVLTC(1)

An undefined database error occurred. SELECT distinct pages.pagepath,pages.pageid FROM pages, page2command WHERE pages.pageid = page2command.pageid AND commandid =


More information about the site can be found in the FAQ



Security Code
Security Code
Type Security Code

Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name.

Help if you can!

Amazon Wish List

Did You Know?
The Linux Tutorial can use your help.


Tell a Friend About Us

Bookmark and Share

Web site powered by PHP-Nuke

Is this information useful? At the very least you can help by spreading the word to your favorite newsgroups, mailing lists and forums.
All logos and trademarks in this site are property of their respective owner. The comments are property of their posters. Articles are the property of their respective owners. Unless otherwise stated in the body of the article, article content (C) 1994-2013 by James Mohr. All rights reserved. The stylized page/paper, as well as the terms "The Linux Tutorial", "The Linux Server Tutorial", "The Linux Knowledge Base and Tutorial" and "The place where you learn Linux" are service marks of James Mohr. All rights reserved.
The Linux Knowledge Base and Tutorial may contain links to sites on the Internet, which are owned and operated by third parties. The Linux Tutorial is not responsible for the content of any such third-party site. By viewing/utilizing this web site, you have agreed to our disclaimer, terms of use and privacy policy. Use of automated download software ("harvesters") such as wget, httrack, etc. causes the site to quickly exceed its bandwidth limitation and are therefore expressly prohibited. For more details on this, take a look here

PHP-Nuke Copyright © 2004 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.
Page Generation: 0.11 Seconds