Import newer scripts upstream

This commit is contained in:
Pierre Pronchery 2020-09-28 08:12:02 +02:00
parent 86fd374797
commit b9ee35b2cd

View File

@ -61,6 +61,22 @@ _error()
} }
#gtkdoc_fixxref
_gtkdoc_fixxref()
{
module="$1"
moduledir="$2"
htmldir="$3"
outputdir="$4"
(cd "$outputdir" &&
$DEBUG $GTKDOC_FIXXREF \
--module="$module" \
--module-dir="$moduledir" \
--html-dir="$htmldir") || exit 2
}
#gtkdoc_mkdb #gtkdoc_mkdb
_gtkdoc_mkdb() _gtkdoc_mkdb()
{ {
@ -75,6 +91,19 @@ _gtkdoc_mkdb()
} }
#gtkdoc_mkhtml
_gtkdoc_mkhtml()
{
module="$1"
path="$2"
driver="$3"
outputdir="$4"
(cd "$outputdir" &&
$DEBUG $GTKDOC_MKHTML --path "$path" "$module" "$driver")
}
#gtkdoc_mktmpl #gtkdoc_mktmpl
_gtkdoc_mktmpl() _gtkdoc_mktmpl()
{ {
@ -184,13 +213,16 @@ while [ $# -gt 0 ]; do
output="${OBJDIR}gtkdoc/html" output="${OBJDIR}gtkdoc/html"
$DEBUG $MKDIR -- "$output" || exit 2 $DEBUG $MKDIR -- "$output" || exit 2
driver="$MODULE-docs.xml" driver="$MODULE-docs.xml"
if [ -n "$OBJDIR" ]; then oldpath="$PWD"
$DEBUG $CP -- "gtkdoc/$driver" "${OBJDIR}gtkdoc" \ [ -n "$OBJDIR" ] && for file in \
|| exit 2 "gtkdoc/$driver" \
fi "gtkdoc/xml/gtkdocentities.ent"; do
(cd "$output" && [ -f "$file" ] || continue
$DEBUG $GTKDOC_MKHTML "$MODULE" \ $DEBUG $CP -- "$file" \
"../$driver") "${OBJDIR}$file" || exit 2
done
_gtkdoc_mkhtml "$MODULE" "${oldpath%/*}" "../$driver" \
"$output"
#detect when gtk-doc is not available #detect when gtk-doc is not available
res=$? res=$?
if [ $res -eq 127 ]; then if [ $res -eq 127 ]; then
@ -201,11 +233,7 @@ while [ $# -gt 0 ]; do
exit 2 exit 2
fi fi
output="${OBJDIR}gtkdoc" output="${OBJDIR}gtkdoc"
(cd "$output" && _gtkdoc_fixxref "$MODULE" "html" "$instdir" "$output"
$DEBUG $GTKDOC_FIXXREF \
--module="$MODULE" \
--module-dir="html" \
--html-dir="$instdir") || exit 2
;; ;;
gtkdoc/tmpl.stamp) gtkdoc/tmpl.stamp)
output="tmpl" output="tmpl"