# $Id$ # $Name$ use strict; use diagnostics; my $gedcom_ref_doc="http://www.gendex.com/gedcom55/55gcch2.htm"; my $inputfile ="$ENV{srcdir}/../include/gom.h"; my $outputfile ="gomxref.html"; my $ext_link = "interface.html"; my $generated = ""; my $main_structs = ""; my $sub_structs=""; my $index = ""; my $section = ""; open INPUT, $inputfile or die "Can't read $inputfile\n"; open OUTPUT, ">$outputfile" or die "Can't write $outputfile\n"; sub gedcom_link { my ($sublink) = @_; if ($sublink) { return "(?)"; } else { return ""; } } while () { my $gedc_ref = ""; $section = "sub" if m|^/\* Sub-structures \*/|; $section = "main" if m|^/\* Main structures \*/|; $section = "" if m|^/\* Functions \*/|; $generated = $1 if m|^/\* [\$]Id: (.*?) \$ \*/|; next if m|^/\*|; if ($section ne "") { chomp; if (s|\s*/\* (.*?) \*/\s*$||) { $gedc_ref = $1; } if (m|^struct (.*) \{|) { s|^struct (.*?) \{|struct $1 \{|; if ($section eq "main") { $index .= "
The following links are fast links to the main structures in the Gedcom object model:
$main_structs
$sub_structs