Recent

Author Topic: How to use FPDOC MAKESKEL to include INC files as well?  (Read 2467 times)

avra

  • Hero Member
  • *****
  • Posts: 2590
    • Additional info
How to use FPDOC MAKESKEL to include INC files as well?
« on: September 30, 2021, 11:22:30 am »
I used MAKESKEL to generate skelethon XML for FPDOC like this:
Code: [Select]
makeskel --package=syshelpers --input=m:\Lazarus\testing\SysHelpers\syshelpers.pas --output=syshelpers.xmland XML file was created. However, I also need to somehow include 4 *.inc files into the same XML skelethon (if that would be the proper way for my goal of having everything in a single XML). How can I achieve this?
« Last Edit: September 30, 2021, 11:28:01 am by avra »
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

avra

  • Hero Member
  • *****
  • Posts: 2590
    • Additional info
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #1 on: September 30, 2021, 03:37:10 pm »
Silly me, it seams that inclusion is automatic since all *.inc files are already referenced in the main unit.  :D
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 12896
  • FPC developer.
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #2 on: September 30, 2021, 03:49:15 pm »
Afaik the input parameter is like a commandline, you can also pass paths there. See manual, excerpt:

Quote from: "fpdoc manual
This option tells FPDoc what input file should be used. The argument can be just a filename, but can also be a complete compiler command-line with options that concern the scanning of the Pascal source: defines, include files, syntax options, as they would be specified to the Free Pascal compiler when compiling the file. If a complete command is used, then it should be enclosed in single or double quotes, so the shell will not break them in parts.

avra

  • Hero Member
  • *****
  • Posts: 2590
    • Additional info
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #3 on: March 23, 2022, 10:48:46 am »
I am back to documenting syshelpers, and I am using makeskel to create xml doc template like this:

Quote
makeskel --package=rtl --input=c:\Prg\Lazarus\TrunkAll\fpcsrc\packages\rtl-objpas\src\inc\syshelpers.pp --output=syshelpers.xml

It is not quite clear to me if I should use --package=rtl or --package=syshelpers in the above example. Please advise.
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 12896
  • FPC developer.
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #4 on: March 23, 2022, 11:02:06 am »
See package as a CHM. If it goes into the same CHM, it has the same package. If not, it is a different package.

I'd simply choose some unique package name, so it is simple to change with a substitution later, if needed.

avra

  • Hero Member
  • *****
  • Posts: 2590
    • Additional info
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #5 on: March 23, 2022, 11:07:40 am »
See package as a CHM. If it goes into the same CHM, it has the same package. If not, it is a different package.
When I open RTL CHM I see that it holds sysutils unit among others. I think that syshelpers unit should be there as well. In such a case I should use --package=rtl, right?
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 12896
  • FPC developer.
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #6 on: March 23, 2022, 11:34:36 am »
I checked and it is in rtl-objpas, so yes, RTL.

Thaddy

  • Hero Member
  • *****
  • Posts: 19258
  • Glad to be alive.
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #7 on: March 23, 2022, 01:25:01 pm »
Same conclusion as Marco: Checked.
objects are fine constructs. You can even initialize them with constructors.

avra

  • Hero Member
  • *****
  • Posts: 2590
    • Additional info
Re: How to use FPDOC MAKESKEL to include INC files as well?
« Reply #8 on: March 24, 2022, 08:48:26 am »
Thanks, it is clear now  8)
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

 

TinyPortal © 2005-2018