This file is indexed.

/usr/share/cmake/Modules/ManageZanataScript.cmake is in cmake-fedora 2.7.2-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
# - Manage Zanata Script
# Zanata related scripts to be invoked in command line.

MACRO(MANAGE_ZANATA_SCRIPT_PRINT_USAGE)
    MESSAGE("Manage Zanata script: This script is not recommend for end users

cmake -D cmd=zanata_xml_download
      -D url=<zanata_server_url>
      -D project=<project_id>
      -D version=<version_id>
      [-D zanata_xml=<zanata.xml>]
      [-D \"<var>=<value>\"]
    -P <CmakeModulePath>/ManageZanataScript.cmake

    Download zanata.xml from Zanata Server
    Options:
        url: Zanata server URL (e.g. https://translate.zanata.org/zanata/)
	    This should be indentical to what is written in zanata.ini.
	project: project ID in Zanata.
	version: version ID in Zanata.
	zanata_xml: (Optional) zanata.xml output file. 
            Default: zanata.xml

cmake -D cmd=zanata_xml_map
      [-D \"locales=<locale1;locale2...>\"]
      [-D system_locales=1]
      [-D po_dir=<po_dir> ]
      [-D trans_dir=<trans_dir> ]
      [-D zanata_xml=<zanata.xml>]
      [-D zanata_xml_in=<zanata.xml>]
      [-D \"<var>=<value>\"]
    -P <CmakeModulePath>/ManageZanataScript.cmake

    Map the zanata server locales with client translation files,
    so it will output correctly.
    Options:
        system_locales: use system locales in /usr/share/locale.
        locales: client-side locales to be mapped.
	po_dir: (Deprecated) Use trans_dir instead
	trans_dir: (Optional) Specify base directory of translation files.
	zanata_xml: (Optional) zanata.xml output file.
	     Default: zanata.xml
	zanata_xml_in: (Optional) zanata.xml input file.
	     Default: zanata.xml

cmake -D cmd=zanata_xml_make
      -D url=<zanata_server_url>
      -D project=<project_id>
      -D version=<version_id>
      [-D \"locales=<locale1;locale2...>\"]
      [-D system_locales=1]
      [-D po_dir=<po_dir> ]
      [-D trans_dir=<trans_dir> ]
      [-D zanata_xml=<zanata.xml>]
      [-D \"<var>=<value>\"]
    -P <CmakeModulePath>/ManageZanataScript.cmake

    Make a working zanata.xml.
    Options:
        url: Zanata server URL (e.g. https://translate.zanata.org/zanata/)
	    This should be indentical to what is written in zanata.ini.
	po_dir: (Deprecated) Use trans_dir instead
	trans_dir: (Optional) Specify base directory of translation files.
	project: project ID in Zanata.
	version: version ID in Zanata.
	system_locales: use system locales in /usr/share/locale.
	locales: client-side locales to be mapped.
	zanata_xml: (Optional) zanata.xml output file.
	     Default: zanata.xml
	"
	)
ENDMACRO(MANAGE_ZANATA_SCRIPT_PRINT_USAGE)

MACRO(ZANATA_XML_DOWNLOAD_CHECK)
    SET(_requirementMet 1)
    IF(NOT url)
	M_MSG("${M_ERROR}" "Requires url")
	SET(_requirementMet 0)
    ENDIF()
    IF(NOT project)
	M_MSG("${M_ERROR}" "Requires project")
	SET(_requirementMet 0)
    ENDIF()
    IF(NOT version)
	M_MSG("${M_ERROR}" "Requires version")
	SET(_requirementMet 0)
    ENDIF()
    IF(NOT _requirementMet)
	RETURN()
    ENDIF()
    IF(NOT zanata_xml)
	SET(zanata_xml "zanata.xml")
    ENDIF()
    ZANATA_ZANATA_XML_DOWNLOAD("${zanata_xml}" "${url}" "${project}" "${version}")
ENDMACRO()

MACRO(ZANATA_XML_MAP_CHECK)
    SET(_requirementMet 1)
    IF(NOT zanata_xml_in)
	SET(zanata_xml_in "zanata.xml")
    ENDIF()

    IF(NOT EXISTS ${zanata_xml_in})
	M_MSG("${M_ERROR}" "File not exists: ${zanata_xml_in}")
	SET(_requirementMet 0)
    ENDIF()

    IF(NOT zanata_xml)
	SET(zanata_xml "zanata.xml")
    ENDIF()

    IF(NOT _requirementMet)
	RETURN()
    ENDIF()

    IF(NOT "${po_dir}" STREQUAL "")
	SET(trans_dir "${po_dir}")
    ENDIF()

    IF("${trans_dir}" STREQUAL "")
	SET(trans_dir ".")
    ENDIF()

    SET(extOptions "")
    IF("${system_locales}" STREQUAL "1")
	LIST(APPEND extOptions "SYSTEM_LOCALES")
    ELSEIF(NOT "${locales}" STREQUAL "")
	LIST(APPEND extOptions "LOCALES" "${locales}")
    ENDIF()
    ZANATA_ZANATA_XML_MAP("${zanata_xml}" "${zanata_xml_in}" "${trans_dir}" ${extOptions})
ENDMACRO()

FUNCTION(ZANATA_XML_MAKE_CHECK)
    IF(NOT zanata_xml)
	SET(zanata_xml "zanata.xml")
    ENDIF()
    SET(zanata_xml_in "${zanata_xml}")

    IF(NOT EXISTS "${zanata_xml_in}")
	ZANATA_XML_DOWNLOAD_CHECK()
    ENDIF()

    ZANATA_XML_MAP_CHECK()
ENDFUNCTION()

SET(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS ON)

#######################################
# Determine CMAKE_FEDORA_MODULE_DIR
#

## It is possible that current dir is in NO_PACK/FedPkg/<prj>
LIST(INSERT CMAKE_MODULE_PATH 0
    ${CMAKE_SOURCE_DIR}/Modules ${CMAKE_SOURCE_DIR}/cmake-fedora/Modules 
    ${CMAKE_SOURCE_DIR}/../../../Modules
    ${CMAKE_SOURCE_DIR}/../../../cmake-fedora/Modules
    ${CMAKE_SOURCE_DIR}
    )

IF(CMAKE_SCRIPT_MODE_FILE)
    GET_FILENAME_COMPONENT(CMAKE_FEDORA_SCRIPT_DIR ${CMAKE_SCRIPT_MODE_FILE}
	PATH)
    LIST(INSERT CMAKE_MODULE_PATH 0 "${CMAKE_FEDORA_SCRIPT_DIR}")
ENDIF()

IF(cmake_fedora_module_dir)
    LIST(INSERT CMAKE_MODULE_PATH 0 "${cmake_fedora_module_dir}")
ENDIF()

INCLUDE(ManageMessage RESULT_VARIABLE MANAGE_MODULE_PATH)
IF(NOT MANAGE_MODULE_PATH)
    MESSAGE(FATAL_ERROR "ManageMessage.cmake cannot be found in ${CMAKE_MODULE_PATH}")
ENDIF()
GET_FILENAME_COMPONENT(CMAKE_FEDORA_MODULE_DIR 
    "${MANAGE_MODULE_PATH}" PATH)

INCLUDE(ManageEnvironmentCommon)
INCLUDE(ManageString)
INCLUDE(ManageVariable)
INCLUDE(ManageVersion)
INCLUDE(ManageZanata)

IF(NOT DEFINED cmd)
    MANAGE_ZANATA_SCRIPT_PRINT_USAGE()
ELSE()
    IF("${cmd}" STREQUAL "zanata_xml_download")
	ZANATA_XML_DOWNLOAD_CHECK()
    ELSEIF("${cmd}" STREQUAL "zanata_xml_map")
	ZANATA_XML_MAP_CHECK()
    ELSEIF("${cmd}" STREQUAL "zanata_xml_make")
	ZANATA_XML_MAKE_CHECK()
    ELSE()
	MANAGE_ZANATA_SCRIPT_PRINT_USAGE()
	M_MSG(${M_FATAL} "Invalid sub-command ${cmd}")
    ENDIF()
ENDIF()