cvs commit: modperl-docs/src/devel/core_explained core_explained.pod

2001-11-29 Thread stas
stas01/11/29 08:26:32

  Modified:src/devel/core_explained core_explained.pod
  Log:
  - document the BOOT= directive in the map file
  
  Revision  ChangesPath
  1.8   +36 -3 modperl-docs/src/devel/core_explained/core_explained.pod
  
  Index: core_explained.pod
  ===
  RCS file: /home/cvs/modperl-docs/src/devel/core_explained/core_explained.pod,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- core_explained.pod2001/11/22 15:43:58 1.7
  +++ core_explained.pod2001/11/29 16:26:32 1.8
  @@ -156,7 +156,40 @@
   
   =item * CBOOT
   
  -META: complete
  +The CBOOT directive tells the XS generator, whether to add the boot
  +function to the autogenerated XS file or not. If the value of CBOOT
  +is not true or it's simply not declared, the boot function won't be
  +added.
  +
  +If the value is true, a boot function will be added to the XS file.
  +Note, that this function is not declared in the map file.
  +
  +The boot function name must be constructed from three parts:
  +
  +  'mpxs_' . MODULE . '_BOOT'
  +
  +where CMODULE is the one declared with CMODULE= in the map file.
  +
  +For example if we want to have an XS boot function for a class
  +CAPR::IO, we create this function in Ixs/APR/IO/APR__IO.h:
  +
  +  static void mpxs_APR__IO_BOOT(pTHX)
  +  {
  + /* boot code here */
  +  }
  +
  +and now we add the CBOOT=1 declaration to the
  +Ixs/maps/modperl_functions.map file:
  +
  +  MODULE=APR::IO PACKAGE=APR::IO BOOT=1
  +
  +When Imake xs_generate is run (after running Imake source_scan),
  +it autogenerates IWrap/APR/IO/IO.xs and amongst other things will
  +include:
  +
  +  BOOT:
  +  mpxs_APR__IO_BOOT(aTHXo);
  +
   
   =item * CISA
   
  @@ -164,8 +197,8 @@
   
   =back
   
  -Every function definition is declared on a separate line, using the
  -following format:
  +Every function definition is declared on a separate line (use C\ if
  +the line is too long), using the following format:
   
 C function name | Dispatch function name | Argspec | Perl alias
   
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: modperl-docs/src/devel/core_explained core_explained.pod

2001-11-22 Thread stas
stas01/11/22 07:43:58

  Modified:src/devel/core_explained core_explained.pod
  Log:
  xs_generate is running from Makefile.PL only if MP_GENERATE_XS=1
  
  Revision  ChangesPath
  1.7   +4 -3  modperl-docs/src/devel/core_explained/core_explained.pod
  
  Index: core_explained.pod
  ===
  RCS file: /home/cvs/modperl-docs/src/devel/core_explained/core_explained.pod,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- core_explained.pod2001/11/21 04:39:52 1.6
  +++ core_explained.pod2001/11/22 15:43:58 1.7
  @@ -228,8 +228,8 @@
   converted into Ixs/tables/current/ModPerl/FunctionTable.pm.
   
   If you don't want to do a visual check on how XS code will be
  -generated, just rebuild the project starting with Cperl
  -Makefile.PL. Otherwise run:
  +generated, just rebuild the project starting with Cperl Makefile.PL
  +MP_GENERATE_XS=1. Otherwise run:
   
 % make xs_generate
   
  @@ -239,7 +239,8 @@
   =head2 XS generation process
   
   As mentioned before XS code is generated in the IWrapXS directory
  -either during Cperl Makefile.PL via xs_generate() or explicitly via:
  +either during Cperl Makefile.PL via xs_generate() if
  +CMP_GENERATE_XS=1 is used or explicitly via:
   
 % make xs_generate
   
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]