This file is indexed.

/usr/share/yelp-xsl/xslt/docbook/common/db-profile.xsl is in yelp-xsl 3.10.1-1.

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

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
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
<?xml version='1.0' encoding='UTF-8'?><!-- -*- indent-tabs-mode: nil -*- -->
<!--
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your option) any
later version.

This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
details.

You should have received a copy of the GNU Lesser General Public License
along with this program; see the file COPYING.LGPL.  If not, write to the
Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA.
-->

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                xmlns:str="http://exslt.org/strings"
                exclude-result-prefixes="str"
                version="1.0">

<!--!!==========================================================================
DocBook Profiling
Support for DocBook effectivity attributes
:Revision:version="3.10" date="2013-08-12" status="final"

This stylesheet contains utilities for handling conditional processing
in DocBook documents.
-->


<!--@@==========================================================================
db.profile.arch
The list of architectures for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{arch} attribute for conditional processing.
-->
<xsl:param name="db.profile.arch" select="''"/>


<!--@@==========================================================================
db.profile.audience
The list of audiences for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{audience} attribute for conditional processing.
-->
<xsl:param name="db.profile.audience" select="''"/>


<!--@@==========================================================================
db.profile.condition
The list of application-specific conditions for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{condition} attribute for conditional processing.
-->
<xsl:param name="db.profile.condition" select="''"/>


<!--@@==========================================================================
db.profile.conformance
The list of conformance characteristics for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{conformance} attribute for conditional processing.
-->
<xsl:param name="db.profile.conformance" select="''"/>


<!--@@==========================================================================
db.profile.os
The list of operating systems for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{os} attribute for conditional processing.
-->
<xsl:param name="db.profile.os" select="''"/>


<!--@@==========================================================================
db.profile.outputformat
The list of output formats for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{outputformat} attribute for conditional processing.
-->
<xsl:param name="db.profile.os" select="''"/>


<!--@@==========================================================================
db.profile.revision
The list of editorial revisions for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{revision} attribute for conditional processing.
-->
<xsl:param name="db.profile.revision" select="''"/>


<!--@@==========================================================================
db.profile.security
The list of security levels for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{security} attribute for conditional processing.
-->
<xsl:param name="db.profile.security" select="''"/>


<!--@@==========================================================================
db.profile.userlevel
The list of user experience levels for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{userlevel} attribute for conditional processing.
-->
<xsl:param name="db.profile.userlevel" select="''"/>


<!--@@==========================================================================
db.profile.vendor
The list of vendors for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{vendor} attribute for conditional processing.
-->
<xsl:param name="db.profile.vendor" select="''"/>


<!--@@==========================================================================
db.profile.wordsize
The list of word sizes for conditional processing.
:Revision:version="3.10" date="2013-08-12" status="final"

This parameter takes a semicolon-separated list of values to match against the
#{wordsize} attribute for conditional processing.
-->
<xsl:param name="db.profile.wordsize" select="''"/>


<!--**==========================================================================
db.profile.test
Test if an element should be shown based on profiling attributes.
:Revision:version="3.10" date="2013-08-12" status="final"
$node: The element to check the condition for.

This template looks at all the profiling attributes of the element ${node}:
#{arch}, #{audience}, #{condition}, #{conformance}, #{os}, #{outputformat},
#{revision}, #{security}, #{userlevel}, #{vendor}, and #{wordsize}. It returns
the string #{"true"} if all attributes present match the corresponding parameter
in this stylesheet. Attributes and parameters can both be lists, separated by
semicolons. An attribute matches a parameter if there is at least one value in
common between the two.
-->
<xsl:template name="db.profile.test">
  <xsl:param name="node" select="."/>

  <xsl:variable name="testnot">
    <xsl:if test="$node/@arch != '' and $db.profile.arch != ''">
      <xsl:variable name="testarch">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@arch"/>
          <xsl:with-param name="value" select="$db.profile.arch"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testarch = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@audience != '' and $db.profile.audience != ''">
      <xsl:variable name="testaudience">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@audience"/>
          <xsl:with-param name="value" select="$db.profile.audience"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testaudience = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@condition != '' and $db.profile.condition != ''">
      <xsl:variable name="testcondition">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@condition"/>
          <xsl:with-param name="value" select="$db.profile.condition"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testcondition = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@conformance != '' and $db.profile.conformance != ''">
      <xsl:variable name="testconformance">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@conformance"/>
          <xsl:with-param name="value" select="$db.profile.conformance"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testconformance = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@os != '' and $db.profile.os != ''">
      <xsl:variable name="testos">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@os"/>
          <xsl:with-param name="value" select="$db.profile.os"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testos = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@outputformat != '' and $db.profile.outputformat != ''">
      <xsl:variable name="testoutputformat">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@outputformat"/>
          <xsl:with-param name="value" select="$db.profile.outputformat"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testoutputformat = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@revision != '' and $db.profile.revision != ''">
      <xsl:variable name="testrevision">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@revision"/>
          <xsl:with-param name="value" select="$db.profile.revision"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testrevision = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@security != '' and $db.profile.security != ''">
      <xsl:variable name="testsecurity">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@security"/>
          <xsl:with-param name="value" select="$db.profile.security"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testsecurity = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@userlevel != '' and $db.profile.userlevel != ''">
      <xsl:variable name="testuserlevel">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@userlevel"/>
          <xsl:with-param name="value" select="$db.profile.userlevel"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testuserlevel = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@vendor != '' and $db.profile.vendor != ''">
      <xsl:variable name="testvendor">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@vendor"/>
          <xsl:with-param name="value" select="$db.profile.vendor"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testvendor = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>

    <xsl:if test="$node/@wordsize != '' and $db.profile.wordsize != ''">
      <xsl:variable name="testwordsize">
        <xsl:call-template name="_db.profile.test.compare">
          <xsl:with-param name="attr" select="$node/@wordsize"/>
          <xsl:with-param name="value" select="$db.profile.wordsize"/>
        </xsl:call-template>
      </xsl:variable>
      <xsl:if test="$testwordsize = ''">
        <xsl:text>x</xsl:text>
      </xsl:if>
    </xsl:if>
  </xsl:variable>

  <xsl:if test="$testnot = ''">
    <xsl:text>true</xsl:text>
  </xsl:if>
</xsl:template>

<!--#* _db.profile.test.compare -->
<xsl:template name="_db.profile.test.compare">
  <xsl:param name="attr"/>
  <xsl:param name="value"/>
  <xsl:variable name="attr_" select="concat(';', $attr, ';')"/>
  <xsl:for-each select="str:split($value, ';')">
    <xsl:if test="contains($attr_, concat(';', ., ';'))">
      <xsl:text>1</xsl:text>
    </xsl:if>
  </xsl:for-each>
</xsl:template>

</xsl:stylesheet>