File: gtkdoc-mkhtml.in

package info (click to toggle)
gtk-doc 1.3-4
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 988 kB
  • ctags: 20
  • sloc: perl: 5,673; sh: 701; lisp: 118; makefile: 87
file content (53 lines) | stat: -rw-r--r-- 1,038 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/bin/sh
#

usage="\
Usage: gtkdoc-mkhtml MODULE DRIVER_FILE"

if test "x$1" = "x--version"; then
      echo "@VERSION@"
      exit 0
fi

if test $# -ne 2; then
      echo "${usage}" 1>&2
      exit 1
fi

module=$1
document=$2

prefix=@prefix@
gtkdocdir=@datadir@/gtk-doc/data

declaration=$gtkdocdir/gtk-doc.dcl

if head -n 1 $document | grep "<?xml" > /dev/null; then
  is_xml=true
else
  is_xml=false
fi

# Delete the old index.sgml file, if it exists.
if test -f index.sgml; then
      rm -f index.sgml
fi

if $is_xml; then
  @XSLTPROC@ --nonet --xinclude \
      --stringparam gtkdoc.bookname $module \
      --stringparam gtkdoc.version "@VERSION@" \
      $gtkdocdir/gtk-doc.xsl $document || exit $?
else
  @JADE@ -t @SGML_FORMAT_TYPE@ -w no-idref -d $gtkdocdir/gtk-doc.dsl \
      -V "gtkdoc-bookname=$module" -V "gtkdoc-version=@VERSION@" \
      $gtkdocdir/gtk-doc.dcl $document || exit $?
fi

# copy navigation images to html directory ...
cp -f $gtkdocdir/*.png .
cp -f $gtkdocdir/*.css .


echo "timestamp" > ../html.stamp