This file is indexed.

/usr/bin/dunedoxynize is in libdune-common-dev 2.2.1-2.

This file is owned by root:root, with mode 0o755.

The actual contents of the file can be viewed below.

  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
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
#!/bin/sh

if [ "x$DEBUG" = "xyes" ]; then
  set -x
fi

DOXYOUT=${1:-doc/doxygen/Doxyfile.in}
OUTDIR=`dirname "$DOXYOUT"`
DOXYDIR="doc/doxygen/"

find_doxystyle()
{
  for i in `dirname $0`/../doc/doxygen/Doxystyle `dirname $0`/../share/dune-common/doc/doxygen/Doxystyle; do
    if [ -f "$i" ]; then
      export DOXYSTYLE=$i
      return 0
    fi
  done
  return 1
}

test_doxylocal()
{
  while [ -n "$1" ]; do
    if [ -f "$1/dune.module" ]; then
      return 0
    fi
    shift
  done
  return 1
}

parse_doxyfile()
{
  # Doxylocal is used _as is_
  if [ "$2" = "Doxylocal" ]; then
    cat $1/$DOXYDIR/$2
    return
  fi

  local FILE=$1/$DOXYDIR/$2
  local FOUND=0
  local line

  # find lines that match the pattern
  set `grep -n '^ *\(INPUT\|EXAMPLE_PATH\|IMAGE_PATH\|PREDEFINED\|EXCLUDE\|EXAMPLE_PATTERNS\) *[+=]' $FILE | cut -d: -f1`

  # search lines in $@ and proceeding lines
  grep -n . $FILE |
  sed -e 's/\\/\\\\/g' |
  while read line; do
    if [ "${line%%:*}" -eq "${1:-0}" ]; then
      FOUND=1
      # subst = by += if necessary
      start="${line%%=*}"
      case "$start" in
        *+) ;;
        *)  line="$start+=${line#*=}" ;;
      esac
      shift
    fi
    if [ $FOUND -eq 1 ]; then
      echo "$line"
    else
      continue
    fi
    # check for trailing '\'
    case "$line" in
      *\\) FOUND=1 ;;
      *)   FOUND=0 ;;
    esac
  done | sed -e 's/^[0-9]*://'
}

parse_doxylocal()
{
  if echo $1 | grep -q "^/"; then
    srcdir=$1/$DOXYDIR
    top_srcdir=$1
    parse_doxyfile $1 $2 | sed -e "s!@\(abs_\)*srcdir@!$srcdir!" -e "s!@\(abs_\)*top_srcdir@!$top_srcdir!";
  else
    parse_doxyfile $1 $2
  fi
}

get_module_name()
{
  grep "^Module:" $1/dune.module | sed -e 's/^Module: *//'
}

generate_doxyout()
{
  echo "Generating $DOXYOUT from "
  echo "    global style"
  cat $DOXYSTYLE > $DOXYOUT
  while [ -n "$1" ]; do
    for DOXY in Doxylocal Doxyfile.in Doxyfile; do
	  if [ "$1/$DOXYDIR/$DOXY" -ef "$DOXYOUT" ]; then continue; fi
      if [ -f "$1/$DOXYDIR/$DOXY" ]; then
        echo "    and `get_module_name $1` config"
        parse_doxylocal $1 $DOXY >> $DOXYOUT
        break
      fi
    done
    shift
  done
  echo "    ... done"
}

generate_doxylocal()
{
  echo "Generating $DOXYOUT from "
  for DOXY in Doxyfile.in Doxyfile; do
    if [ -f "$1/$DOXYDIR/$DOXY" ]; then
      echo "    `get_module_name .` $DOXY"
      parse_doxylocal . $DOXY > $DOXYOUT
      break
    fi
  done
  echo "    ... done"
}

# make sure we are in dune module
if ! [ -f dune.module ]; then
  echo "Error: dunedoxynize must be called from the top_srcdir of your module"
  exit 1
fi

# don't do anything if we have old style Doxyfile or Doxyfile.in, but no Doxylocal
if [ $# -eq 0 ] && ! [ -f "$DOXYDIR/Doxylocal" ]; then
  for DOXY in Doxyfile.in Doxyfile; do
    if [ -f "$DOXYDIR/$DOXY" ]; then
      echo "Warning: module still uses handwritten $DOXY"
      echo "         You can transform it to an initial Doxylocal by calling"
      echo "         dune-common/bin/dunedoxynize doc/doxygen/Doxylocal ."
      echo "         in the top source directory of this module"
      exit 0
    fi
  done
  exit 0
fi

# quit if your module doesn't have any documentation
if ! [ -d "$OUTDIR" ]; then
  if [ $# -eq 0 ]; then
    exit 0
  else
    echo "Error: output directory $OUTDIR does not exist."
    exit 0
  fi
fi

# search for doxygen style
if ! find_doxystyle; then
  echo "Error: dunedoxynize global style not found"
  exit 1
fi

# drop the parameter of the output file
if [ $# -gt 0 ]; then
  shift
fi

# make sure that there is at least one Doxylocal file
if ! test_doxylocal "${@:-.}" && [ $# -gt 0 ]; then
  echo "Error: you didn't supply any valid Doxylocal file"
  exit 1
fi

if [ "`basename $DOXYOUT`" = "Doxylocal" ]; then
  generate_doxylocal "${@:-.}"
else
  generate_doxyout "${@:-.}"
fi