xen-vtx-unstable
changeset 6781:8ca0f98ba8e2
merge?
line diff
1.1 --- a/.hgignore Tue Sep 13 15:32:38 2005 +0000 1.2 +++ b/.hgignore Tue Sep 13 15:33:37 2005 +0000 1.3 @@ -19,6 +19,7 @@ 1.4 ^docs/.*\.toc$ 1.5 ^docs/figs/xenserver\.eps$ 1.6 ^docs/html/.*$ 1.7 +^docs/api/.*$ 1.8 ^docs/interface/WARNINGS$ 1.9 ^docs/interface/images\.pl$ 1.10 ^docs/interface/images\.tex$ 1.11 @@ -60,8 +61,6 @@ 1.12 ^pristine-.*$ 1.13 ^ref-.*$ 1.14 ^tools/.*/build/lib.*/.*\.py$ 1.15 -^tools/Makefile\.smh$ 1.16 -^tools/balloon/balloon$ 1.17 ^tools/blktap/Makefile\.smh$ 1.18 ^tools/blktap/blkcow$ 1.19 ^tools/blktap/blkcowgnbd$ 1.20 @@ -85,8 +84,7 @@ 1.21 ^tools/blktap/ublkback/ublkback$ 1.22 ^tools/blktap/xen/.*$ 1.23 ^tools/check/\..*$ 1.24 -^tools/cmdline/.*$ 1.25 -^tools/cmdline/xen/.*$ 1.26 +^tools/examples/xmexample\.vmx$ 1.27 ^tools/console/xenconsoled$ 1.28 ^tools/console/xenconsole$ 1.29 ^tools/debugger/pdb/pdb$ 1.30 @@ -109,8 +107,6 @@ 1.31 ^tools/firmware/vmxassist/roms\.h$ 1.32 ^tools/firmware/vmxassist/vmxassist$ 1.33 ^tools/firmware/vmxassist/vmxloader$ 1.34 -^tools/gdb/gdb-6\.2\.1-linux-i386-xen/.*$ 1.35 -^tools/gdb/gdb-6\.2\.1/.*$ 1.36 ^tools/ioemu/config-host\..*$ 1.37 ^tools/ioemu/keysym_adapter_sdl\.h$ 1.38 ^tools/ioemu/keysym_adapter_vnc\.h$ 1.39 @@ -141,12 +137,9 @@ 1.40 ^tools/vnet/vnet-module/\..*\.cmd$ 1.41 ^tools/vnet/vnet-module/\.tmp_versions/.*$ 1.42 ^tools/vnet/vnet-module/vnet_module\.mod\..*$ 1.43 -^tools/vnetd/vnetd$ 1.44 ^tools/vtpm/vtpm* 1.45 ^tools/vtpm/tpm_emulator-* 1.46 ^tools/vtpm_manager/manager/vtpm_managerd 1.47 -^tools/web-shutdown\.tap$ 1.48 -^tools/x2d2/minixend$ 1.49 ^tools/xcutils/xc_restore$ 1.50 ^tools/xcutils/xc_save$ 1.51 ^tools/xenstat/xentop/xentop$
2.1 --- a/Makefile Tue Sep 13 15:32:38 2005 +0000 2.2 +++ b/Makefile Tue Sep 13 15:33:37 2005 +0000 2.3 @@ -35,8 +35,8 @@ ifeq ($(XEN_TARGET_X86_PAE),y) 2.4 export pae=y 2.5 endif 2.6 2.7 -.PHONY: all dist install xen kernels tools docs world clean mkpatches mrproper 2.8 -.PHONY: kbuild kdelete kclean 2.9 +.PHONY: all dist install xen kernels tools dev-docs docs world clean 2.10 +.PHONY: mkpatches mrproper kbuild kdelete kclean 2.11 2.12 # build and install everything into the standard system directories 2.13 install: install-xen install-kernels install-tools install-docs 2.14 @@ -66,6 +66,9 @@ kernels: 2.15 docs: 2.16 sh ./docs/check_pkgs && $(MAKE) -C docs install || true 2.17 2.18 +dev-docs: 2.19 + $(MAKE) -C docs dev-docs 2.20 + 2.21 # Build all the various kernels and modules 2.22 kbuild: kernels 2.23 2.24 @@ -123,7 +126,7 @@ help: 2.25 @echo ' install-xen - build and install the Xen hypervisor' 2.26 @echo ' install-tools - build and install the control tools' 2.27 @echo ' install-kernels - build and install guest kernels' 2.28 - @echo ' install-docs - build and install documentation' 2.29 + @echo ' install-docs - build and install user documentation' 2.30 @echo '' 2.31 @echo 'Building targets:' 2.32 @echo ' dist - build and install everything into local dist directory' 2.33 @@ -133,7 +136,8 @@ help: 2.34 @echo ' tools - build and install tools' 2.35 @echo ' kernels - build and install guest kernels' 2.36 @echo ' kbuild - synonym for make kernels' 2.37 - @echo ' docs - build and install docs' 2.38 + @echo ' docs - build and install user documentation' 2.39 + @echo ' dev-docs - build developer-only documentation' 2.40 @echo '' 2.41 @echo 'Cleaning targets:' 2.42 @echo ' clean - clean the Xen, tools and docs (but not'
6.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 6.2 +++ b/docs/Doxyfile Tue Sep 13 15:33:37 2005 +0000 6.3 @@ -0,0 +1,1218 @@ 6.4 +# Doxyfile 1.4.2 6.5 + 6.6 +# This file describes the settings to be used by the documentation system 6.7 +# doxygen (www.doxygen.org) for a project 6.8 +# 6.9 +# All text after a hash (#) is considered a comment and will be ignored 6.10 +# The format is: 6.11 +# TAG = value [value, ...] 6.12 +# For lists items can also be appended using: 6.13 +# TAG += value [value, ...] 6.14 +# Values that contain spaces should be placed between quotes (" ") 6.15 + 6.16 +#--------------------------------------------------------------------------- 6.17 +# Project related configuration options 6.18 +#--------------------------------------------------------------------------- 6.19 + 6.20 +# The PROJECT_NAME tag is a single word (or a sequence of words surrounded 6.21 +# by quotes) that should identify the project. 6.22 + 6.23 +PROJECT_NAME = Xen Python Tools 6.24 + 6.25 +# The PROJECT_NUMBER tag can be used to enter a project or revision number. 6.26 +# This could be handy for archiving the generated documentation or 6.27 +# if some version control system is used. 6.28 + 6.29 +PROJECT_NUMBER = 6.30 + 6.31 +# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) 6.32 +# base path where the generated documentation will be put. 6.33 +# If a relative path is entered, it will be relative to the location 6.34 +# where doxygen was started. If left blank the current directory will be used. 6.35 + 6.36 +OUTPUT_DIRECTORY = api/tools/python 6.37 + 6.38 +# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 6.39 +# 4096 sub-directories (in 2 levels) under the output directory of each output 6.40 +# format and will distribute the generated files over these directories. 6.41 +# Enabling this option can be useful when feeding doxygen a huge amount of 6.42 +# source files, where putting all generated files in the same directory would 6.43 +# otherwise cause performance problems for the file system. 6.44 + 6.45 +CREATE_SUBDIRS = NO 6.46 + 6.47 +# The OUTPUT_LANGUAGE tag is used to specify the language in which all 6.48 +# documentation generated by doxygen is written. Doxygen will use this 6.49 +# information to generate all constant output in the proper language. 6.50 +# The default language is English, other supported languages are: 6.51 +# Brazilian, Catalan, Chinese, Chinese-Traditional, Croatian, Czech, Danish, 6.52 +# Dutch, Finnish, French, German, Greek, Hungarian, Italian, Japanese, 6.53 +# Japanese-en (Japanese with English messages), Korean, Korean-en, Norwegian, 6.54 +# Polish, Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, 6.55 +# Swedish, and Ukrainian. 6.56 + 6.57 +OUTPUT_LANGUAGE = English 6.58 + 6.59 +# This tag can be used to specify the encoding used in the generated output. 6.60 +# The encoding is not always determined by the language that is chosen, 6.61 +# but also whether or not the output is meant for Windows or non-Windows users. 6.62 +# In case there is a difference, setting the USE_WINDOWS_ENCODING tag to YES 6.63 +# forces the Windows encoding (this is the default for the Windows binary), 6.64 +# whereas setting the tag to NO uses a Unix-style encoding (the default for 6.65 +# all platforms other than Windows). 6.66 + 6.67 +USE_WINDOWS_ENCODING = NO 6.68 + 6.69 +# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will 6.70 +# include brief member descriptions after the members that are listed in 6.71 +# the file and class documentation (similar to JavaDoc). 6.72 +# Set to NO to disable this. 6.73 + 6.74 +BRIEF_MEMBER_DESC = YES 6.75 + 6.76 +# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend 6.77 +# the brief description of a member or function before the detailed description. 6.78 +# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the 6.79 +# brief descriptions will be completely suppressed. 6.80 + 6.81 +REPEAT_BRIEF = YES 6.82 + 6.83 +# This tag implements a quasi-intelligent brief description abbreviator 6.84 +# that is used to form the text in various listings. Each string 6.85 +# in this list, if found as the leading text of the brief description, will be 6.86 +# stripped from the text and the result after processing the whole list, is 6.87 +# used as the annotated text. Otherwise, the brief description is used as-is. 6.88 +# If left blank, the following values are used ("$name" is automatically 6.89 +# replaced with the name of the entity): "The $name class" "The $name widget" 6.90 +# "The $name file" "is" "provides" "specifies" "contains" 6.91 +# "represents" "a" "an" "the" 6.92 + 6.93 +ABBREVIATE_BRIEF = 6.94 + 6.95 +# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then 6.96 +# Doxygen will generate a detailed section even if there is only a brief 6.97 +# description. 6.98 + 6.99 +ALWAYS_DETAILED_SEC = NO 6.100 + 6.101 +# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all 6.102 +# inherited members of a class in the documentation of that class as if those 6.103 +# members were ordinary class members. Constructors, destructors and assignment 6.104 +# operators of the base classes will not be shown. 6.105 + 6.106 +INLINE_INHERITED_MEMB = NO 6.107 + 6.108 +# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full 6.109 +# path before files name in the file list and in the header files. If set 6.110 +# to NO the shortest path that makes the file name unique will be used. 6.111 + 6.112 +FULL_PATH_NAMES = YES 6.113 + 6.114 +# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag 6.115 +# can be used to strip a user-defined part of the path. Stripping is 6.116 +# only done if one of the specified strings matches the left-hand part of 6.117 +# the path. The tag can be used to show relative paths in the file list. 6.118 +# If left blank the directory from which doxygen is run is used as the 6.119 +# path to strip. 6.120 + 6.121 +STRIP_FROM_PATH = 6.122 + 6.123 +# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of 6.124 +# the path mentioned in the documentation of a class, which tells 6.125 +# the reader which header file to include in order to use a class. 6.126 +# If left blank only the name of the header file containing the class 6.127 +# definition is used. Otherwise one should specify the include paths that 6.128 +# are normally passed to the compiler using the -I flag. 6.129 + 6.130 +STRIP_FROM_INC_PATH = 6.131 + 6.132 +# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter 6.133 +# (but less readable) file names. This can be useful is your file systems 6.134 +# doesn't support long names like on DOS, Mac, or CD-ROM. 6.135 + 6.136 +SHORT_NAMES = NO 6.137 + 6.138 +# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen 6.139 +# will interpret the first line (until the first dot) of a JavaDoc-style 6.140 +# comment as the brief description. If set to NO, the JavaDoc 6.141 +# comments will behave just like the Qt-style comments (thus requiring an 6.142 +# explicit @brief command for a brief description. 6.143 + 6.144 +JAVADOC_AUTOBRIEF = YES 6.145 + 6.146 +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen 6.147 +# treat a multi-line C++ special comment block (i.e. a block of //! or /// 6.148 +# comments) as a brief description. This used to be the default behaviour. 6.149 +# The new default is to treat a multi-line C++ comment block as a detailed 6.150 +# description. Set this tag to YES if you prefer the old behaviour instead. 6.151 + 6.152 +MULTILINE_CPP_IS_BRIEF = NO 6.153 + 6.154 +# If the DETAILS_AT_TOP tag is set to YES then Doxygen 6.155 +# will output the detailed description near the top, like JavaDoc. 6.156 +# If set to NO, the detailed description appears after the member 6.157 +# documentation. 6.158 + 6.159 +DETAILS_AT_TOP = YES 6.160 + 6.161 +# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented 6.162 +# member inherits the documentation from any documented member that it 6.163 +# re-implements. 6.164 + 6.165 +INHERIT_DOCS = YES 6.166 + 6.167 +# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC 6.168 +# tag is set to YES, then doxygen will reuse the documentation of the first 6.169 +# member in the group (if any) for the other members of the group. By default 6.170 +# all members of a group must be documented explicitly. 6.171 + 6.172 +DISTRIBUTE_GROUP_DOC = NO 6.173 + 6.174 +# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce 6.175 +# a new page for each member. If set to NO, the documentation of a member will 6.176 +# be part of the file/class/namespace that contains it. 6.177 + 6.178 +SEPARATE_MEMBER_PAGES = NO 6.179 + 6.180 +# The TAB_SIZE tag can be used to set the number of spaces in a tab. 6.181 +# Doxygen uses this value to replace tabs by spaces in code fragments. 6.182 + 6.183 +TAB_SIZE = 8 6.184 + 6.185 +# This tag can be used to specify a number of aliases that acts 6.186 +# as commands in the documentation. An alias has the form "name=value". 6.187 +# For example adding "sideeffect=\par Side Effects:\n" will allow you to 6.188 +# put the command \sideeffect (or @sideeffect) in the documentation, which 6.189 +# will result in a user-defined paragraph with heading "Side Effects:". 6.190 +# You can put \n's in the value part of an alias to insert newlines. 6.191 + 6.192 +ALIASES = 6.193 + 6.194 +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C 6.195 +# sources only. Doxygen will then generate output that is more tailored for C. 6.196 +# For instance, some of the names that are used will be different. The list 6.197 +# of all members will be omitted, etc. 6.198 + 6.199 +OPTIMIZE_OUTPUT_FOR_C = NO 6.200 + 6.201 +# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java sources 6.202 +# only. Doxygen will then generate output that is more tailored for Java. 6.203 +# For instance, namespaces will be presented as packages, qualified scopes 6.204 +# will look different, etc. 6.205 + 6.206 +OPTIMIZE_OUTPUT_JAVA = YES 6.207 + 6.208 +# Set the SUBGROUPING tag to YES (the default) to allow class member groups of 6.209 +# the same type (for instance a group of public functions) to be put as a 6.210 +# subgroup of that type (e.g. under the Public Functions section). Set it to 6.211 +# NO to prevent subgrouping. Alternatively, this can be done per class using 6.212 +# the \nosubgrouping command. 6.213 + 6.214 +SUBGROUPING = YES 6.215 + 6.216 +#--------------------------------------------------------------------------- 6.217 +# Build related configuration options 6.218 +#--------------------------------------------------------------------------- 6.219 + 6.220 +# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in 6.221 +# documentation are documented, even if no documentation was available. 6.222 +# Private class members and static file members will be hidden unless 6.223 +# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES 6.224 + 6.225 +EXTRACT_ALL = YES 6.226 + 6.227 +# If the EXTRACT_PRIVATE tag is set to YES all private members of a class 6.228 +# will be included in the documentation. 6.229 + 6.230 +EXTRACT_PRIVATE = YES 6.231 + 6.232 +# If the EXTRACT_STATIC tag is set to YES all static members of a file 6.233 +# will be included in the documentation. 6.234 + 6.235 +EXTRACT_STATIC = YES 6.236 + 6.237 +# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) 6.238 +# defined locally in source files will be included in the documentation. 6.239 +# If set to NO only classes defined in header files are included. 6.240 + 6.241 +EXTRACT_LOCAL_CLASSES = YES 6.242 + 6.243 +# This flag is only useful for Objective-C code. When set to YES local 6.244 +# methods, which are defined in the implementation section but not in 6.245 +# the interface are included in the documentation. 6.246 +# If set to NO (the default) only methods in the interface are included. 6.247 + 6.248 +EXTRACT_LOCAL_METHODS = NO 6.249 + 6.250 +# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all 6.251 +# undocumented members of documented classes, files or namespaces. 6.252 +# If set to NO (the default) these members will be included in the 6.253 +# various overviews, but no documentation section is generated. 6.254 +# This option has no effect if EXTRACT_ALL is enabled. 6.255 + 6.256 +HIDE_UNDOC_MEMBERS = NO 6.257 + 6.258 +# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all 6.259 +# undocumented classes that are normally visible in the class hierarchy. 6.260 +# If set to NO (the default) these classes will be included in the various 6.261 +# overviews. This option has no effect if EXTRACT_ALL is enabled. 6.262 + 6.263 +HIDE_UNDOC_CLASSES = NO 6.264 + 6.265 +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all 6.266 +# friend (class|struct|union) declarations. 6.267 +# If set to NO (the default) these declarations will be included in the 6.268 +# documentation. 6.269 + 6.270 +HIDE_FRIEND_COMPOUNDS = NO 6.271 + 6.272 +# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any 6.273 +# documentation blocks found inside the body of a function. 6.274 +# If set to NO (the default) these blocks will be appended to the 6.275 +# function's detailed documentation block. 6.276 + 6.277 +HIDE_IN_BODY_DOCS = NO 6.278 + 6.279 +# The INTERNAL_DOCS tag determines if documentation 6.280 +# that is typed after a \internal command is included. If the tag is set 6.281 +# to NO (the default) then the documentation will be excluded. 6.282 +# Set it to YES to include the internal documentation. 6.283 + 6.284 +INTERNAL_DOCS = NO 6.285 + 6.286 +# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate 6.287 +# file names in lower-case letters. If set to YES upper-case letters are also 6.288 +# allowed. This is useful if you have classes or files whose names only differ 6.289 +# in case and if your file system supports case sensitive file names. Windows 6.290 +# and Mac users are advised to set this option to NO. 6.291 + 6.292 +CASE_SENSE_NAMES = YES 6.293 + 6.294 +# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen 6.295 +# will show members with their full class and namespace scopes in the 6.296 +# documentation. If set to YES the scope will be hidden. 6.297 + 6.298 +HIDE_SCOPE_NAMES = NO 6.299 + 6.300 +# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen 6.301 +# will put a list of the files that are included by a file in the documentation 6.302 +# of that file. 6.303 + 6.304 +SHOW_INCLUDE_FILES = YES 6.305 + 6.306 +# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] 6.307 +# is inserted in the documentation for inline members. 6.308 + 6.309 +INLINE_INFO = YES 6.310 + 6.311 +# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen 6.312 +# will sort the (detailed) documentation of file and class members 6.313 +# alphabetically by member name. If set to NO the members will appear in 6.314 +# declaration order. 6.315 + 6.316 +SORT_MEMBER_DOCS = YES 6.317 + 6.318 +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the 6.319 +# brief documentation of file, namespace and class members alphabetically 6.320 +# by member name. If set to NO (the default) the members will appear in 6.321 +# declaration order. 6.322 + 6.323 +SORT_BRIEF_DOCS = NO 6.324 + 6.325 +# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be 6.326 +# sorted by fully-qualified names, including namespaces. If set to 6.327 +# NO (the default), the class list will be sorted only by class name, 6.328 +# not including the namespace part. 6.329 +# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. 6.330 +# Note: This option applies only to the class list, not to the 6.331 +# alphabetical list. 6.332 + 6.333 +SORT_BY_SCOPE_NAME = NO 6.334 + 6.335 +# The GENERATE_TODOLIST tag can be used to enable (YES) or 6.336 +# disable (NO) the todo list. This list is created by putting \todo 6.337 +# commands in the documentation. 6.338 + 6.339 +GENERATE_TODOLIST = YES 6.340 + 6.341 +# The GENERATE_TESTLIST tag can be used to enable (YES) or 6.342 +# disable (NO) the test list. This list is created by putting \test 6.343 +# commands in the documentation. 6.344 + 6.345 +GENERATE_TESTLIST = YES 6.346 + 6.347 +# The GENERATE_BUGLIST tag can be used to enable (YES) or 6.348 +# disable (NO) the bug list. This list is created by putting \bug 6.349 +# commands in the documentation. 6.350 + 6.351 +GENERATE_BUGLIST = YES 6.352 + 6.353 +# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or 6.354 +# disable (NO) the deprecated list. This list is created by putting 6.355 +# \deprecated commands in the documentation. 6.356 + 6.357 +GENERATE_DEPRECATEDLIST= YES 6.358 + 6.359 +# The ENABLED_SECTIONS tag can be used to enable conditional 6.360 +# documentation sections, marked by \if sectionname ... \endif. 6.361 + 6.362 +ENABLED_SECTIONS = 6.363 + 6.364 +# The MAX_INITIALIZER_LINES tag determines the maximum number of lines 6.365 +# the initial value of a variable or define consists of for it to appear in 6.366 +# the documentation. If the initializer consists of more lines than specified 6.367 +# here it will be hidden. Use a value of 0 to hide initializers completely. 6.368 +# The appearance of the initializer of individual variables and defines in the 6.369 +# documentation can be controlled using \showinitializer or \hideinitializer 6.370 +# command in the documentation regardless of this setting. 6.371 + 6.372 +MAX_INITIALIZER_LINES = 30 6.373 + 6.374 +# Set the SHOW_USED_FILES tag to NO to disable the list of files generated 6.375 +# at the bottom of the documentation of classes and structs. If set to YES the 6.376 +# list will mention the files that were used to generate the documentation. 6.377 + 6.378 +SHOW_USED_FILES = YES 6.379 + 6.380 +# If the sources in your project are distributed over multiple directories 6.381 +# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy 6.382 +# in the documentation. 6.383 + 6.384 +SHOW_DIRECTORIES = YES 6.385 + 6.386 +# The FILE_VERSION_FILTER tag can be used to specify a program or script that 6.387 +# doxygen should invoke to get the current version for each file (typically from the 6.388 +# version control system). Doxygen will invoke the program by executing (via 6.389 +# popen()) the command <command> <input-file>, where <command> is the value of 6.390 +# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file 6.391 +# provided by doxygen. Whatever the progam writes to standard output 6.392 +# is used as the file version. See the manual for examples. 6.393 + 6.394 +FILE_VERSION_FILTER = 6.395 + 6.396 +#--------------------------------------------------------------------------- 6.397 +# configuration options related to warning and progress messages 6.398 +#--------------------------------------------------------------------------- 6.399 + 6.400 +# The QUIET tag can be used to turn on/off the messages that are generated 6.401 +# by doxygen. Possible values are YES and NO. If left blank NO is used. 6.402 + 6.403 +QUIET = YES 6.404 + 6.405 +# The WARNINGS tag can be used to turn on/off the warning messages that are 6.406 +# generated by doxygen. Possible values are YES and NO. If left blank 6.407 +# NO is used. 6.408 + 6.409 +WARNINGS = YES 6.410 + 6.411 +# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings 6.412 +# for undocumented members. If EXTRACT_ALL is set to YES then this flag will 6.413 +# automatically be disabled. 6.414 + 6.415 +WARN_IF_UNDOCUMENTED = YES 6.416 + 6.417 +# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for 6.418 +# potential errors in the documentation, such as not documenting some 6.419 +# parameters in a documented function, or documenting parameters that 6.420 +# don't exist or using markup commands wrongly. 6.421 + 6.422 +WARN_IF_DOC_ERROR = YES 6.423 + 6.424 +# This WARN_NO_PARAMDOC option can be abled to get warnings for 6.425 +# functions that are documented, but have no documentation for their parameters 6.426 +# or return value. If set to NO (the default) doxygen will only warn about 6.427 +# wrong or incomplete parameter documentation, but not about the absence of 6.428 +# documentation. 6.429 + 6.430 +WARN_NO_PARAMDOC = NO 6.431 + 6.432 +# The WARN_FORMAT tag determines the format of the warning messages that 6.433 +# doxygen can produce. The string should contain the $file, $line, and $text 6.434 +# tags, which will be replaced by the file and line number from which the 6.435 +# warning originated and the warning text. Optionally the format may contain 6.436 +# $version, which will be replaced by the version of the file (if it could 6.437 +# be obtained via FILE_VERSION_FILTER) 6.438 + 6.439 +WARN_FORMAT = "$file:$line: $text" 6.440 + 6.441 +# The WARN_LOGFILE tag can be used to specify a file to which warning 6.442 +# and error messages should be written. If left blank the output is written 6.443 +# to stderr. 6.444 + 6.445 +WARN_LOGFILE = 6.446 + 6.447 +#--------------------------------------------------------------------------- 6.448 +# configuration options related to the input files 6.449 +#--------------------------------------------------------------------------- 6.450 + 6.451 +# The INPUT tag can be used to specify the files and/or directories that contain 6.452 +# documented source files. You may enter file names like "myfile.cpp" or 6.453 +# directories like "/usr/src/myproject". Separate the files or directories 6.454 +# with spaces. 6.455 + 6.456 +INPUT = ../tools/python/xen/ 6.457 + 6.458 +# If the value of the INPUT tag contains directories, you can use the 6.459 +# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 6.460 +# and *.h) to filter out the source-files in the directories. If left 6.461 +# blank the following patterns are tested: 6.462 +# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx 6.463 +# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm 6.464 + 6.465 +FILE_PATTERNS = *.py *.c 6.466 + 6.467 +# The RECURSIVE tag can be used to turn specify whether or not subdirectories 6.468 +# should be searched for input files as well. Possible values are YES and NO. 6.469 +# If left blank NO is used. 6.470 + 6.471 +RECURSIVE = YES 6.472 + 6.473 +# The EXCLUDE tag can be used to specify files and/or directories that should 6.474 +# excluded from the INPUT source files. This way you can easily exclude a 6.475 +# subdirectory from a directory tree whose root is specified with the INPUT tag. 6.476 + 6.477 +EXCLUDE = 6.478 + 6.479 +# The EXCLUDE_SYMLINKS tag can be used select whether or not files or 6.480 +# directories that are symbolic links (a Unix filesystem feature) are excluded 6.481 +# from the input. 6.482 + 6.483 +EXCLUDE_SYMLINKS = NO 6.484 + 6.485 +# If the value of the INPUT tag contains directories, you can use the 6.486 +# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude 6.487 +# certain files from those directories. 6.488 + 6.489 +EXCLUDE_PATTERNS = 6.490 + 6.491 +# The EXAMPLE_PATH tag can be used to specify one or more files or 6.492 +# directories that contain example code fragments that are included (see 6.493 +# the \include command). 6.494 + 6.495 +EXAMPLE_PATH = 6.496 + 6.497 +# If the value of the EXAMPLE_PATH tag contains directories, you can use the 6.498 +# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp 6.499 +# and *.h) to filter out the source-files in the directories. If left 6.500 +# blank all files are included. 6.501 + 6.502 +EXAMPLE_PATTERNS = 6.503 + 6.504 +# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be 6.505 +# searched for input files to be used with the \include or \dontinclude 6.506 +# commands irrespective of the value of the RECURSIVE tag. 6.507 +# Possible values are YES and NO. If left blank NO is used. 6.508 + 6.509 +EXAMPLE_RECURSIVE = NO 6.510 + 6.511 +# The IMAGE_PATH tag can be used to specify one or more files or 6.512 +# directories that contain image that are included in the documentation (see 6.513 +# the \image command). 6.514 + 6.515 +IMAGE_PATH = 6.516 + 6.517 +# The INPUT_FILTER tag can be used to specify a program that doxygen should 6.518 +# invoke to filter for each input file. Doxygen will invoke the filter program 6.519 +# by executing (via popen()) the command <filter> <input-file>, where <filter> 6.520 +# is the value of the INPUT_FILTER tag, and <input-file> is the name of an 6.521 +# input file. Doxygen will then use the output that the filter program writes 6.522 +# to standard output. If FILTER_PATTERNS is specified, this tag will be 6.523 +# ignored. 6.524 + 6.525 +INPUT_FILTER = "sh ./Doxyfilter ../tools/python" 6.526 + 6.527 +# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern 6.528 +# basis. Doxygen will compare the file name with each pattern and apply the 6.529 +# filter if there is a match. The filters are a list of the form: 6.530 +# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further 6.531 +# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER 6.532 +# is applied to all files. 6.533 + 6.534 +FILTER_PATTERNS = 6.535 + 6.536 +# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using 6.537 +# INPUT_FILTER) will be used to filter the input files when producing source 6.538 +# files to browse (i.e. when SOURCE_BROWSER is set to YES). 6.539 + 6.540 +FILTER_SOURCE_FILES = YES 6.541 + 6.542 +#--------------------------------------------------------------------------- 6.543 +# configuration options related to source browsing 6.544 +#--------------------------------------------------------------------------- 6.545 + 6.546 +# If the SOURCE_BROWSER tag is set to YES then a list of source files will 6.547 +# be generated. Documented entities will be cross-referenced with these sources. 6.548 +# Note: To get rid of all source code in the generated output, make sure also 6.549 +# VERBATIM_HEADERS is set to NO. 6.550 + 6.551 +SOURCE_BROWSER = NO 6.552 + 6.553 +# Setting the INLINE_SOURCES tag to YES will include the body 6.554 +# of functions and classes directly in the documentation. 6.555 + 6.556 +INLINE_SOURCES = NO 6.557 + 6.558 +# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct 6.559 +# doxygen to hide any special comment blocks from generated source code 6.560 +# fragments. Normal C and C++ comments will always remain visible. 6.561 + 6.562 +STRIP_CODE_COMMENTS = YES 6.563 + 6.564 +# If the REFERENCED_BY_RELATION tag is set to YES (the default) 6.565 +# then for each documented function all documented 6.566 +# functions referencing it will be listed. 6.567 + 6.568 +REFERENCED_BY_RELATION = YES 6.569 + 6.570 +# If the REFERENCES_RELATION tag is set to YES (the default) 6.571 +# then for each documented function all documented entities 6.572 +# called/used by that function will be listed. 6.573 + 6.574 +REFERENCES_RELATION = YES 6.575 + 6.576 +# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen 6.577 +# will generate a verbatim copy of the header file for each class for 6.578 +# which an include is specified. Set to NO to disable this. 6.579 + 6.580 +VERBATIM_HEADERS = YES 6.581 + 6.582 +#--------------------------------------------------------------------------- 6.583 +# configuration options related to the alphabetical class index 6.584 +#--------------------------------------------------------------------------- 6.585 + 6.586 +# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index 6.587 +# of all compounds will be generated. Enable this if the project 6.588 +# contains a lot of classes, structs, unions or interfaces. 6.589 + 6.590 +ALPHABETICAL_INDEX = NO 6.591 + 6.592 +# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then 6.593 +# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns 6.594 +# in which this list will be split (can be a number in the range [1..20]) 6.595 + 6.596 +COLS_IN_ALPHA_INDEX = 5 6.597 + 6.598 +# In case all classes in a project start with a common prefix, all 6.599 +# classes will be put under the same header in the alphabetical index. 6.600 +# The IGNORE_PREFIX tag can be used to specify one or more prefixes that 6.601 +# should be ignored while generating the index headers. 6.602 + 6.603 +IGNORE_PREFIX = 6.604 + 6.605 +#--------------------------------------------------------------------------- 6.606 +# configuration options related to the HTML output 6.607 +#--------------------------------------------------------------------------- 6.608 + 6.609 +# If the GENERATE_HTML tag is set to YES (the default) Doxygen will 6.610 +# generate HTML output. 6.611 + 6.612 +GENERATE_HTML = YES 6.613 + 6.614 +# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. 6.615 +# If a relative path is entered the value of OUTPUT_DIRECTORY will be 6.616 +# put in front of it. If left blank `html' will be used as the default path. 6.617 + 6.618 +HTML_OUTPUT = html 6.619 + 6.620 +# The HTML_FILE_EXTENSION tag can be used to specify the file extension for 6.621 +# each generated HTML page (for example: .htm,.php,.asp). If it is left blank 6.622 +# doxygen will generate files with .html extension. 6.623 + 6.624 +HTML_FILE_EXTENSION = .html 6.625 + 6.626 +# The HTML_HEADER tag can be used to specify a personal HTML header for 6.627 +# each generated HTML page. If it is left blank doxygen will generate a 6.628 +# standard header. 6.629 + 6.630 +HTML_HEADER = 6.631 + 6.632 +# The HTML_FOOTER tag can be used to specify a personal HTML footer for 6.633 +# each generated HTML page. If it is left blank doxygen will generate a 6.634 +# standard footer. 6.635 + 6.636 +HTML_FOOTER = 6.637 + 6.638 +# The HTML_STYLESHEET tag can be used to specify a user-defined cascading 6.639 +# style sheet that is used by each HTML page. It can be used to 6.640 +# fine-tune the look of the HTML output. If the tag is left blank doxygen 6.641 +# will generate a default style sheet. Note that doxygen will try to copy 6.642 +# the style sheet file to the HTML output directory, so don't put your own 6.643 +# stylesheet in the HTML output directory as well, or it will be erased! 6.644 + 6.645 +HTML_STYLESHEET = 6.646 + 6.647 +# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, 6.648 +# files or namespaces will be aligned in HTML using tables. If set to 6.649 +# NO a bullet list will be used. 6.650 + 6.651 +HTML_ALIGN_MEMBERS = YES 6.652 + 6.653 +# If the GENERATE_HTMLHELP tag is set to YES, additional index files 6.654 +# will be generated that can be used as input for tools like the 6.655 +# Microsoft HTML help workshop to generate a compressed HTML help file (.chm) 6.656 +# of the generated HTML documentation. 6.657 + 6.658 +GENERATE_HTMLHELP = NO 6.659 + 6.660 +# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can 6.661 +# be used to specify the file name of the resulting .chm file. You 6.662 +# can add a path in front of the file if the result should not be 6.663 +# written to the html output directory. 6.664 + 6.665 +CHM_FILE = 6.666 + 6.667 +# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can 6.668 +# be used to specify the location (absolute path including file name) of 6.669 +# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run 6.670 +# the HTML help compiler on the generated index.hhp. 6.671 + 6.672 +HHC_LOCATION = 6.673 + 6.674 +# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag 6.675 +# controls if a separate .chi index file is generated (YES) or that 6.676 +# it should be included in the master .chm file (NO). 6.677 + 6.678 +GENERATE_CHI = NO 6.679 + 6.680 +# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag 6.681 +# controls whether a binary table of contents is generated (YES) or a 6.682 +# normal table of contents (NO) in the .chm file. 6.683 + 6.684 +BINARY_TOC = NO 6.685 + 6.686 +# The TOC_EXPAND flag can be set to YES to add extra items for group members 6.687 +# to the contents of the HTML help documentation and to the tree view. 6.688 + 6.689 +TOC_EXPAND = NO 6.690 + 6.691 +# The DISABLE_INDEX tag can be used to turn on/off the condensed index at 6.692 +# top of each HTML page. The value NO (the default) enables the index and 6.693 +# the value YES disables it. 6.694 + 6.695 +DISABLE_INDEX = NO 6.696 + 6.697 +# This tag can be used to set the number of enum values (range [1..20]) 6.698 +# that doxygen will group on one line in the generated HTML documentation. 6.699 + 6.700 +ENUM_VALUES_PER_LINE = 4 6.701 + 6.702 +# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be 6.703 +# generated containing a tree-like index structure (just like the one that 6.704 +# is generated for HTML Help). For this to work a browser that supports 6.705 +# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, 6.706 +# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are 6.707 +# probably better off using the HTML help feature. 6.708 + 6.709 +GENERATE_TREEVIEW = NO 6.710 + 6.711 +# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be 6.712 +# used to set the initial width (in pixels) of the frame in which the tree 6.713 +# is shown. 6.714 + 6.715 +TREEVIEW_WIDTH = 250 6.716 + 6.717 +#--------------------------------------------------------------------------- 6.718 +# configuration options related to the LaTeX output 6.719 +#--------------------------------------------------------------------------- 6.720 + 6.721 +# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will 6.722 +# generate Latex output. 6.723 + 6.724 +GENERATE_LATEX = YES 6.725 + 6.726 +# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. 6.727 +# If a relative path is entered the value of OUTPUT_DIRECTORY will be 6.728 +# put in front of it. If left blank `latex' will be used as the default path. 6.729 + 6.730 +LATEX_OUTPUT = latex 6.731 + 6.732 +# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be 6.733 +# invoked. If left blank `latex' will be used as the default command name. 6.734 + 6.735 +LATEX_CMD_NAME = latex 6.736 + 6.737 +# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to 6.738 +# generate index for LaTeX. If left blank `makeindex' will be used as the 6.739 +# default command name. 6.740 + 6.741 +MAKEINDEX_CMD_NAME = makeindex 6.742 + 6.743 +# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact 6.744 +# LaTeX documents. This may be useful for small projects and may help to 6.745 +# save some trees in general. 6.746 + 6.747 +COMPACT_LATEX = NO 6.748 + 6.749 +# The PAPER_TYPE tag can be used to set the paper type that is used 6.750 +# by the printer. Possible values are: a4, a4wide, letter, legal and 6.751 +# executive. If left blank a4wide will be used. 6.752 + 6.753 +PAPER_TYPE = a4wide 6.754 + 6.755 +# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX 6.756 +# packages that should be included in the LaTeX output. 6.757 + 6.758 +EXTRA_PACKAGES = 6.759 + 6.760 +# The LATEX_HEADER tag can be used to specify a personal LaTeX header for 6.761 +# the generated latex document. The header should contain everything until 6.762 +# the first chapter. If it is left blank doxygen will generate a 6.763 +# standard header. Notice: only use this tag if you know what you are doing! 6.764 + 6.765 +LATEX_HEADER = 6.766 + 6.767 +# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated 6.768 +# is prepared for conversion to pdf (using ps2pdf). The pdf file will 6.769 +# contain links (just like the HTML output) instead of page references 6.770 +# This makes the output suitable for online browsing using a pdf viewer. 6.771 + 6.772 +PDF_HYPERLINKS = YES 6.773 + 6.774 +# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of 6.775 +# plain latex in the generated Makefile. Set this option to YES to get a 6.776 +# higher quality PDF documentation. 6.777 + 6.778 +USE_PDFLATEX = YES 6.779 + 6.780 +# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. 6.781 +# command to the generated LaTeX files. This will instruct LaTeX to keep 6.782 +# running if errors occur, instead of asking the user for help. 6.783 +# This option is also used when generating formulas in HTML. 6.784 + 6.785 +LATEX_BATCHMODE = NO 6.786 + 6.787 +# If LATEX_HIDE_INDICES is set to YES then doxygen will not 6.788 +# include the index chapters (such as File Index, Compound Index, etc.) 6.789 +# in the output. 6.790 + 6.791 +LATEX_HIDE_INDICES = NO 6.792 + 6.793 +#--------------------------------------------------------------------------- 6.794 +# configuration options related to the RTF output 6.795 +#--------------------------------------------------------------------------- 6.796 + 6.797 +# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output 6.798 +# The RTF output is optimized for Word 97 and may not look very pretty with 6.799 +# other RTF readers or editors. 6.800 + 6.801 +GENERATE_RTF = NO 6.802 + 6.803 +# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. 6.804 +# If a relative path is entered the value of OUTPUT_DIRECTORY will be 6.805 +# put in front of it. If left blank `rtf' will be used as the default path. 6.806 + 6.807 +RTF_OUTPUT = rtf 6.808 + 6.809 +# If the COMPACT_RTF tag is set to YES Doxygen generates more compact 6.810 +# RTF documents. This may be useful for small projects and may help to 6.811 +# save some trees in general. 6.812 + 6.813 +COMPACT_RTF = NO 6.814 + 6.815 +# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated 6.816 +# will contain hyperlink fields. The RTF file will 6.817 +# contain links (just like the HTML output) instead of page references. 6.818 +# This makes the output suitable for online browsing using WORD or other 6.819 +# programs which support those fields. 6.820 +# Note: wordpad (write) and others do not support links. 6.821 + 6.822 +RTF_HYPERLINKS = NO 6.823 + 6.824 +# Load stylesheet definitions from file. Syntax is similar to doxygen's 6.825 +# config file, i.e. a series of assignments. You only have to provide 6.826 +# replacements, missing definitions are set to their default value. 6.827 + 6.828 +RTF_STYLESHEET_FILE = 6.829 + 6.830 +# Set optional variables used in the generation of an rtf document. 6.831 +# Syntax is similar to doxygen's config file. 6.832 + 6.833 +RTF_EXTENSIONS_FILE = 6.834 + 6.835 +#--------------------------------------------------------------------------- 6.836 +# configuration options related to the man page output 6.837 +#--------------------------------------------------------------------------- 6.838 + 6.839 +# If the GENERATE_MAN tag is set to YES (the default) Doxygen will 6.840 +# generate man pages 6.841 + 6.842 +GENERATE_MAN = NO 6.843 + 6.844 +# The MAN_OUTPUT tag is used to specify where the man pages will be put. 6.845 +# If a relative path is entered the value of OUTPUT_DIRECTORY will be 6.846 +# put in front of it. If left blank `man' will be used as the default path. 6.847 + 6.848 +MAN_OUTPUT = man 6.849 + 6.850 +# The MAN_EXTENSION tag determines the extension that is added to 6.851 +# the generated man pages (default is the subroutine's section .3) 6.852 + 6.853 +MAN_EXTENSION = .3 6.854 + 6.855 +# If the MAN_LINKS tag is set to YES and Doxygen generates man output, 6.856 +# then it will generate one additional man file for each entity 6.857 +# documented in the real man page(s). These additional files 6.858 +# only source the real man page, but without them the man command 6.859 +# would be unable to find the correct page. The default is NO. 6.860 + 6.861 +MAN_LINKS = NO 6.862 + 6.863 +#--------------------------------------------------------------------------- 6.864 +# configuration options related to the XML output 6.865 +#--------------------------------------------------------------------------- 6.866 + 6.867 +# If the GENERATE_XML tag is set to YES Doxygen will 6.868 +# generate an XML file that captures the structure of 6.869 +# the code including all documentation. 6.870 + 6.871 +GENERATE_XML = NO 6.872 + 6.873 +# The XML_OUTPUT tag is used to specify where the XML pages will be put. 6.874 +# If a relative path is entered the value of OUTPUT_DIRECTORY will be 6.875 +# put in front of it. If left blank `xml' will be used as the default path. 6.876 + 6.877 +XML_OUTPUT = xml 6.878 + 6.879 +# The XML_SCHEMA tag can be used to specify an XML schema, 6.880 +# which can be used by a validating XML parser to check the 6.881 +# syntax of the XML files. 6.882 + 6.883 +XML_SCHEMA = 6.884 + 6.885 +# The XML_DTD tag can be used to specify an XML DTD, 6.886 +# which can be used by a validating XML parser to check the 6.887 +# syntax of the XML files. 6.888 + 6.889 +XML_DTD = 6.890 + 6.891 +# If the XML_PROGRAMLISTING tag is set to YES Doxygen will 6.892 +# dump the program listings (including syntax highlighting 6.893 +# and cross-referencing information) to the XML output. Note that 6.894 +# enabling this will significantly increase the size of the XML output. 6.895 + 6.896 +XML_PROGRAMLISTING = YES 6.897 + 6.898 +#--------------------------------------------------------------------------- 6.899 +# configuration options for the AutoGen Definitions output 6.900 +#--------------------------------------------------------------------------- 6.901 + 6.902 +# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will 6.903 +# generate an AutoGen Definitions (see autogen.sf.net) file 6.904 +# that captures the structure of the code including all 6.905 +# documentation. Note that this feature is still experimental 6.906 +# and incomplete at the moment. 6.907 + 6.908 +GENERATE_AUTOGEN_DEF = NO 6.909 + 6.910 +#--------------------------------------------------------------------------- 6.911 +# configuration options related to the Perl module output 6.912 +#--------------------------------------------------------------------------- 6.913 + 6.914 +# If the GENERATE_PERLMOD tag is set to YES Doxygen will 6.915 +# generate a Perl module file that captures the structure of 6.916 +# the code including all documentation. Note that this 6.917 +# feature is still experimental and incomplete at the 6.918 +# moment. 6.919 + 6.920 +GENERATE_PERLMOD = NO 6.921 + 6.922 +# If the PERLMOD_LATEX tag is set to YES Doxygen will generate 6.923 +# the necessary Makefile rules, Perl scripts and LaTeX code to be able 6.924 +# to generate PDF and DVI output from the Perl module output. 6.925 + 6.926 +PERLMOD_LATEX = NO 6.927 + 6.928 +# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be 6.929 +# nicely formatted so it can be parsed by a human reader. This is useful 6.930 +# if you want to understand what is going on. On the other hand, if this 6.931 +# tag is set to NO the size of the Perl module output will be much smaller 6.932 +# and Perl will parse it just the same. 6.933 + 6.934 +PERLMOD_PRETTY = YES 6.935 + 6.936 +# The names of the make variables in the generated doxyrules.make file 6.937 +# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. 6.938 +# This is useful so different doxyrules.make files included by the same 6.939 +# Makefile don't overwrite each other's variables. 6.940 + 6.941 +PERLMOD_MAKEVAR_PREFIX = 6.942 + 6.943 +#--------------------------------------------------------------------------- 6.944 +# Configuration options related to the preprocessor 6.945 +#--------------------------------------------------------------------------- 6.946 + 6.947 +# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will 6.948 +# evaluate all C-preprocessor directives found in the sources and include 6.949 +# files. 6.950 + 6.951 +ENABLE_PREPROCESSING = YES 6.952 + 6.953 +# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro 6.954 +# names in the source code. If set to NO (the default) only conditional 6.955 +# compilation will be performed. Macro expansion can be done in a controlled 6.956 +# way by setting EXPAND_ONLY_PREDEF to YES. 6.957 + 6.958 +MACRO_EXPANSION = NO 6.959 + 6.960 +# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES 6.961 +# then the macro expansion is limited to the macros specified with the 6.962 +# PREDEFINED and EXPAND_AS_PREDEFINED tags. 6.963 + 6.964 +EXPAND_ONLY_PREDEF = NO 6.965 + 6.966 +# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files 6.967 +# in the INCLUDE_PATH (see below) will be search if a #include is found. 6.968 + 6.969 +SEARCH_INCLUDES = YES 6.970 + 6.971 +# The INCLUDE_PATH tag can be used to specify one or more directories that 6.972 +# contain include files that are not input files but should be processed by 6.973 +# the preprocessor. 6.974 + 6.975 +INCLUDE_PATH = 6.976 + 6.977 +# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard 6.978 +# patterns (like *.h and *.hpp) to filter out the header-files in the 6.979 +# directories. If left blank, the patterns specified with FILE_PATTERNS will 6.980 +# be used. 6.981 + 6.982 +INCLUDE_FILE_PATTERNS = 6.983 + 6.984 +# The PREDEFINED tag can be used to specify one or more macro names that 6.985 +# are defined before the preprocessor is started (similar to the -D option of 6.986 +# gcc). The argument of the tag is a list of macros of the form: name 6.987 +# or name=definition (no spaces). If the definition and the = are 6.988 +# omitted =1 is assumed. To prevent a macro definition from being 6.989 +# undefined via #undef or recursively expanded use the := operator 6.990 +# instead of the = operator. 6.991 + 6.992 +PREDEFINED = 6.993 + 6.994 +# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then 6.995 +# this tag can be used to specify a list of macro names that should be expanded. 6.996 +# The macro definition that is found in the sources will be used. 6.997 +# Use the PREDEFINED tag if you want to use a different macro definition. 6.998 + 6.999 +EXPAND_AS_DEFINED = 6.1000 + 6.1001 +# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then 6.1002 +# doxygen's preprocessor will remove all function-like macros that are alone 6.1003 +# on a line, have an all uppercase name, and do not end with a semicolon. Such 6.1004 +# function macros are typically used for boiler-plate code, and will confuse 6.1005 +# the parser if not removed. 6.1006 + 6.1007 +SKIP_FUNCTION_MACROS = YES 6.1008 + 6.1009 +#--------------------------------------------------------------------------- 6.1010 +# Configuration::additions related to external references 6.1011 +#--------------------------------------------------------------------------- 6.1012 + 6.1013 +# The TAGFILES option can be used to specify one or more tagfiles. 6.1014 +# Optionally an initial location of the external documentation 6.1015 +# can be added for each tagfile. The format of a tag file without 6.1016 +# this location is as follows: 6.1017 +# TAGFILES = file1 file2 ... 6.1018 +# Adding location for the tag files is done as follows: 6.1019 +# TAGFILES = file1=loc1 "file2 = loc2" ... 6.1020 +# where "loc1" and "loc2" can be relative or absolute paths or 6.1021 +# URLs. If a location is present for each tag, the installdox tool 6.1022 +# does not have to be run to correct the links. 6.1023 +# Note that each tag file must have a unique name 6.1024 +# (where the name does NOT include the path) 6.1025 +# If a tag file is not located in the directory in which doxygen 6.1026 +# is run, you must also specify the path to the tagfile here. 6.1027 + 6.1028 +TAGFILES = 6.1029 + 6.1030 +# When a file name is specified after GENERATE_TAGFILE, doxygen will create 6.1031 +# a tag file that is based on the input files it reads. 6.1032 + 6.1033 +GENERATE_TAGFILE = 6.1034 + 6.1035 +# If the ALLEXTERNALS tag is set to YES all external classes will be listed 6.1036 +# in the class index. If set to NO only the inherited external classes 6.1037 +# will be listed. 6.1038 + 6.1039 +ALLEXTERNALS = NO 6.1040 + 6.1041 +# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed 6.1042 +# in the modules index. If set to NO, only the current project's groups will 6.1043 +# be listed. 6.1044 + 6.1045 +EXTERNAL_GROUPS = YES 6.1046 + 6.1047 +# The PERL_PATH should be the absolute path and name of the perl script 6.1048 +# interpreter (i.e. the result of `which perl'). 6.1049 + 6.1050 +PERL_PATH = /usr/bin/perl 6.1051 + 6.1052 +#--------------------------------------------------------------------------- 6.1053 +# Configuration options related to the dot tool 6.1054 +#--------------------------------------------------------------------------- 6.1055 + 6.1056 +# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will 6.1057 +# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base 6.1058 +# or super classes. Setting the tag to NO turns the diagrams off. Note that 6.1059 +# this option is superseded by the HAVE_DOT option below. This is only a 6.1060 +# fallback. It is recommended to install and use dot, since it yields more 6.1061 +# powerful graphs. 6.1062 + 6.1063 +CLASS_DIAGRAMS = YES 6.1064 + 6.1065 +# If set to YES, the inheritance and collaboration graphs will hide 6.1066 +# inheritance and usage relations if the target is undocumented 6.1067 +# or is not a class. 6.1068 + 6.1069 +HIDE_UNDOC_RELATIONS = YES 6.1070 + 6.1071 +# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is 6.1072 +# available from the path. This tool is part of Graphviz, a graph visualization 6.1073 +# toolkit from AT&T and Lucent Bell Labs. The other options in this section 6.1074 +# have no effect if this option is set to NO (the default) 6.1075 + 6.1076 +HAVE_DOT = NO 6.1077 + 6.1078 +# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen 6.1079 +# will generate a graph for each documented class showing the direct and 6.1080 +# indirect inheritance relations. Setting this tag to YES will force the 6.1081 +# the CLASS_DIAGRAMS tag to NO. 6.1082 + 6.1083 +CLASS_GRAPH = YES 6.1084 + 6.1085 +# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen 6.1086 +# will generate a graph for each documented class showing the direct and 6.1087 +# indirect implementation dependencies (inheritance, containment, and 6.1088 +# class references variables) of the class with other documented classes. 6.1089 + 6.1090 +COLLABORATION_GRAPH = YES 6.1091 + 6.1092 +# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen 6.1093 +# will generate a graph for groups, showing the direct groups dependencies 6.1094 + 6.1095 +GROUP_GRAPHS = YES 6.1096 + 6.1097 +# If the UML_LOOK tag is set to YES doxygen will generate inheritance and 6.1098 +# collaboration diagrams in a style similar to the OMG's Unified Modeling 6.1099 +# Language. 6.1100 + 6.1101 +UML_LOOK = NO 6.1102 + 6.1103 +# If set to YES, the inheritance and collaboration graphs will show the 6.1104 +# relations between templates and their instances. 6.1105 + 6.1106 +TEMPLATE_RELATIONS = NO 6.1107 + 6.1108 +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT 6.1109 +# tags are set to YES then doxygen will generate a graph for each documented 6.1110 +# file showing the direct and indirect include dependencies of the file with 6.1111 +# other documented files. 6.1112 + 6.1113 +INCLUDE_GRAPH = YES 6.1114 + 6.1115 +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and 6.1116 +# HAVE_DOT tags are set to YES then doxygen will generate a graph for each 6.1117 +# documented header file showing the documented files that directly or 6.1118 +# indirectly include this file. 6.1119 + 6.1120 +INCLUDED_BY_GRAPH = YES 6.1121 + 6.1122 +# If the CALL_GRAPH and HAVE_DOT tags are set to YES then doxygen will 6.1123 +# generate a call dependency graph for every global function or class method. 6.1124 +# Note that enabling this option will significantly increase the time of a run. 6.1125 +# So in most cases it will be better to enable call graphs for selected 6.1126 +# functions only using the \callgraph command. 6.1127 + 6.1128 +CALL_GRAPH = NO 6.1129 + 6.1130 +# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen 6.1131 +# will graphical hierarchy of all classes instead of a textual one. 6.1132 + 6.1133 +GRAPHICAL_HIERARCHY = YES 6.1134 + 6.1135 +# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES 6.1136 +# then doxygen will show the dependencies a directory has on other directories 6.1137 +# in a graphical way. The dependency relations are determined by the #include 6.1138 +# relations between the files in the directories. 6.1139 + 6.1140 +DIRECTORY_GRAPH = YES 6.1141 + 6.1142 +# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images 6.1143 +# generated by dot. Possible values are png, jpg, or gif 6.1144 +# If left blank png will be used. 6.1145 + 6.1146 +DOT_IMAGE_FORMAT = png 6.1147 + 6.1148 +# The tag DOT_PATH can be used to specify the path where the dot tool can be 6.1149 +# found. If left blank, it is assumed the dot tool can be found in the path. 6.1150 + 6.1151 +DOT_PATH = 6.1152 + 6.1153 +# The DOTFILE_DIRS tag can be used to specify one or more directories that 6.1154 +# contain dot files that are included in the documentation (see the 6.1155 +# \dotfile command). 6.1156 + 6.1157 +DOTFILE_DIRS = 6.1158 + 6.1159 +# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width 6.1160 +# (in pixels) of the graphs generated by dot. If a graph becomes larger than 6.1161 +# this value, doxygen will try to truncate the graph, so that it fits within 6.1162 +# the specified constraint. Beware that most browsers cannot cope with very 6.1163 +# large images. 6.1164 + 6.1165 +MAX_DOT_GRAPH_WIDTH = 1024 6.1166 + 6.1167 +# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height 6.1168 +# (in pixels) of the graphs generated by dot. If a graph becomes larger than 6.1169 +# this value, doxygen will try to truncate the graph, so that it fits within 6.1170 +# the specified constraint. Beware that most browsers cannot cope with very 6.1171 +# large images. 6.1172 + 6.1173 +MAX_DOT_GRAPH_HEIGHT = 1024 6.1174 + 6.1175 +# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the 6.1176 +# graphs generated by dot. A depth value of 3 means that only nodes reachable 6.1177 +# from the root by following a path via at most 3 edges will be shown. Nodes 6.1178 +# that lay further from the root node will be omitted. Note that setting this 6.1179 +# option to 1 or 2 may greatly reduce the computation time needed for large 6.1180 +# code bases. Also note that a graph may be further truncated if the graph's 6.1181 +# image dimensions are not sufficient to fit the graph (see MAX_DOT_GRAPH_WIDTH 6.1182 +# and MAX_DOT_GRAPH_HEIGHT). If 0 is used for the depth value (the default), 6.1183 +# the graph is not depth-constrained. 6.1184 + 6.1185 +MAX_DOT_GRAPH_DEPTH = 0 6.1186 + 6.1187 +# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent 6.1188 +# background. This is disabled by default, which results in a white background. 6.1189 +# Warning: Depending on the platform used, enabling this option may lead to 6.1190 +# badly anti-aliased labels on the edges of a graph (i.e. they become hard to 6.1191 +# read). 6.1192 + 6.1193 +DOT_TRANSPARENT = NO 6.1194 + 6.1195 +# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output 6.1196 +# files in one run (i.e. multiple -o and -T options on the command line). This 6.1197 +# makes dot run faster, but since only newer versions of dot (>1.8.10) 6.1198 +# support this, this feature is disabled by default. 6.1199 + 6.1200 +DOT_MULTI_TARGETS = NO 6.1201 + 6.1202 +# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will 6.1203 +# generate a legend page explaining the meaning of the various boxes and 6.1204 +# arrows in the dot generated graphs. 6.1205 + 6.1206 +GENERATE_LEGEND = YES 6.1207 + 6.1208 +# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will 6.1209 +# remove the intermediate dot files that are used to generate 6.1210 +# the various graphs. 6.1211 + 6.1212 +DOT_CLEANUP = YES 6.1213 + 6.1214 +#--------------------------------------------------------------------------- 6.1215 +# Configuration::additions related to the search engine 6.1216 +#--------------------------------------------------------------------------- 6.1217 + 6.1218 +# The SEARCHENGINE tag specifies whether or not a search engine should be 6.1219 +# used. If set to NO the values of all tags below this one will be ignored. 6.1220 + 6.1221 +SEARCHENGINE = NO
7.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 7.2 +++ b/docs/Doxyfilter Tue Sep 13 15:33:37 2005 +0000 7.3 @@ -0,0 +1,16 @@ 7.4 +#!/bin/sh 7.5 + 7.6 +# 7.7 +# Doxyfilter <source-root> <filename> 7.8 +# 7.9 + 7.10 +dir=$(dirname "$0") 7.11 + 7.12 +PYFILTER="$dir/pythfilter.py" 7.13 + 7.14 +if [ "${2/.py/}" != "$2" ] 7.15 +then 7.16 + python "$PYFILTER" -r "$1" -f "$2" 7.17 +else 7.18 + cat "$2" 7.19 +fi
8.1 --- a/docs/Makefile Tue Sep 13 15:32:38 2005 +0000 8.2 +++ b/docs/Makefile Tue Sep 13 15:33:37 2005 +0000 8.3 @@ -8,6 +8,7 @@ DVIPS := dvips 8.4 LATEX := latex 8.5 FIG2DEV := fig2dev 8.6 LATEX2HTML := latex2html 8.7 +DOXYGEN := doxygen 8.8 8.9 pkgdocdir := /usr/share/doc/xen 8.10 8.11 @@ -18,10 +19,14 @@ DOC_HTML := $(patsubst src/%.tex,html/%/ 8.12 8.13 GFX = $(patsubst %.fig, %.eps, $(wildcard figs/*.fig)) 8.14 8.15 +.PHONY: all build dev-docs python-dev-docs ps pdf html clean install 8.16 + 8.17 all: build 8.18 build: ps pdf html 8.19 rm -f *.aux *.dvi *.bbl *.blg *.glo *.idx *.ilg *.log *.ind *.toc 8.20 8.21 +dev-docs: python-dev-docs 8.22 + 8.23 ps: $(DOC_PS) 8.24 8.25 pdf: $(DOC_PDF) 8.26 @@ -30,10 +35,18 @@ html: 8.27 @if which $(LATEX2HTML) 1>/dev/null 2>/dev/null; then \ 8.28 $(MAKE) $(DOC_HTML); fi 8.29 8.30 +python-dev-docs: 8.31 + mkdir -p api/tools/python 8.32 + @if which $(DOXYGEN) 1>/dev/null 2>/dev/null; then \ 8.33 + echo "Running doxygen to generate Python tools APIs ... "; \ 8.34 + $(DOXYGEN) Doxyfile; \ 8.35 + $(MAKE) -C api/tools/python/latex ; fi 8.36 + 8.37 clean: 8.38 rm -rf .word_count *.aux *.dvi *.bbl *.blg *.glo *.idx *~ 8.39 rm -rf *.ilg *.log *.ind *.toc *.bak core 8.40 rm -rf $(GFX) ps pdf html 8.41 + rm -rf api 8.42 8.43 install: all 8.44 rm -rf $(DESTDIR)$(pkgdocdir)
9.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 9.2 +++ b/docs/pythfilter.py Tue Sep 13 15:33:37 2005 +0000 9.3 @@ -0,0 +1,658 @@ 9.4 +#!/usr/bin/env python 9.5 + 9.6 +# pythfilter.py v1.5.5, written by Matthias Baas (baas@ira.uka.de) 9.7 + 9.8 +# Doxygen filter which can be used to document Python source code. 9.9 +# Classes (incl. methods) and functions can be documented. 9.10 +# Every comment that begins with ## is literally turned into an 9.11 +# Doxygen comment. Consecutive comment lines are turned into 9.12 +# comment blocks (-> /** ... */). 9.13 +# All the stuff is put inside a namespace with the same name as 9.14 +# the source file. 9.15 + 9.16 +# Conversions: 9.17 +# ============ 9.18 +# ##-blocks -> /** ... */ 9.19 +# "class name(base): ..." -> "class name : public base {...}" 9.20 +# "def name(params): ..." -> "name(params) {...}" 9.21 + 9.22 +# Changelog: 9.23 +# 21.01.2003: Raw (r"") or unicode (u"") doc string will now be properly 9.24 +# handled. (thanks to Richard Laager for the patch) 9.25 +# 22.12.2003: Fixed a bug where no function names would be output for "def" 9.26 +# blocks that were not in a class. 9.27 +# (thanks to Richard Laager for the patch) 9.28 +# 12.12.2003: Implemented code to handle static and class methods with 9.29 +# this logic: Methods with "self" as the first argument are 9.30 +# non-static. Methods with "cls" are Python class methods, 9.31 +# which translate into static methods for Doxygen. Other 9.32 +# methods are assumed to be static methods. As should be 9.33 +# obvious, this logic doesn't take into account if the method 9.34 +# is actually setup as a classmethod() or a staticmethod(), 9.35 +# just if it follows the normal conventions. 9.36 +# (thanks to Richard Laager for the patch) 9.37 +# 11.12.2003: Corrected #includes to use os.path.sep instead of ".". Corrected 9.38 +# namespace code to use "::" instead of ".". 9.39 +# (thanks to Richard Laager for the patch) 9.40 +# 11.12.2003: Methods beginning with two underscores that end with 9.41 +# something other than two underscores are considered private 9.42 +# and are handled accordingly. 9.43 +# (thanks to Richard Laager for the patch) 9.44 +# 03.12.2003: The first parameter of class methods (self) is removed from 9.45 +# the documentation. 9.46 +# 03.11.2003: The module docstring will be used as namespace documentation 9.47 +# (thanks to Joe Bronkema for the patch) 9.48 +# 08.07.2003: Namespaces get a default documentation so that the namespace 9.49 +# and its contents will show up in the generated documentation. 9.50 +# 05.02.2003: Directories will be delted during synchronization. 9.51 +# 31.01.2003: -f option & filtering entire directory trees. 9.52 +# 10.08.2002: In base classes the '.' will be replaced by '::' 9.53 +# 18.07.2002: * and ** will be translated into arguments 9.54 +# 18.07.2002: Argument lists may contain default values using constructors. 9.55 +# 18.06.2002: Support for ## public: 9.56 +# 21.01.2002: from ... import will be translated to "using namespace ...;" 9.57 +# TODO: "from ... import *" vs "from ... import names" 9.58 +# TODO: Using normal imports: name.name -> name::name 9.59 +# 20.01.2002: #includes will be placed in front of the namespace 9.60 + 9.61 +###################################################################### 9.62 + 9.63 +# The program is written as a state machine with the following states: 9.64 +# 9.65 +# - OUTSIDE The current position is outside any comment, 9.66 +# class definition or function. 9.67 +# 9.68 +# - BUILD_COMMENT Begins with first "##". 9.69 +# Ends with the first token that is no "##" 9.70 +# at the same column as before. 9.71 +# 9.72 +# - BUILD_CLASS_DECL Begins with "class". 9.73 +# Ends with ":" 9.74 +# - BUILD_CLASS_BODY Begins just after BUILD_CLASS_DECL. 9.75 +# The first following token (which is no comment) 9.76 +# determines indentation depth. 9.77 +# Ends with a token that has a smaller indendation. 9.78 +# 9.79 +# - BUILD_DEF_DECL Begins with "def". 9.80 +# Ends with ":". 9.81 +# - BUILD_DEF_BODY Begins just after BUILD_DEF_DECL. 9.82 +# The first following token (which is no comment) 9.83 +# determines indentation depth. 9.84 +# Ends with a token that has a smaller indendation. 9.85 + 9.86 +import getopt 9.87 +import glob 9.88 +import os.path 9.89 +import re 9.90 +import shutil 9.91 +import string 9.92 +import sys 9.93 +import token 9.94 +import tokenize 9.95 + 9.96 +from stat import * 9.97 + 9.98 +OUTSIDE = 0 9.99 +BUILD_COMMENT = 1 9.100 +BUILD_CLASS_DECL = 2 9.101 +BUILD_CLASS_BODY = 3 9.102 +BUILD_DEF_DECL = 4 9.103 +BUILD_DEF_BODY = 5 9.104 +IMPORT = 6 9.105 +IMPORT_OP = 7 9.106 +IMPORT_APPEND = 8 9.107 + 9.108 +# Output file stream 9.109 +outfile = sys.stdout 9.110 + 9.111 +# Output buffer 9.112 +outbuffer = [] 9.113 + 9.114 +out_row = 1 9.115 +out_col = 0 9.116 + 9.117 +# Variables used by rec_name_n_param() 9.118 +name = "" 9.119 +param = "" 9.120 +doc_string = "" 9.121 +record_state = 0 9.122 +bracket_counter = 0 9.123 + 9.124 +# Tuple: (row,column) 9.125 +class_spos = (0,0) 9.126 +def_spos = (0,0) 9.127 +import_spos = (0,0) 9.128 + 9.129 +# Which import was used? ("import" or "from") 9.130 +import_token = "" 9.131 + 9.132 +# Comment block buffer 9.133 +comment_block = [] 9.134 +comment_finished = 0 9.135 + 9.136 +# Imported modules 9.137 +modules = [] 9.138 + 9.139 +# Program state 9.140 +stateStack = [OUTSIDE] 9.141 + 9.142 +# Keep track of whether module has a docstring 9.143 +module_has_docstring = False 9.144 + 9.145 +# Keep track of member protection 9.146 +protection_level = "public" 9.147 +private_member = False 9.148 + 9.149 +# Keep track of the module namespace 9.150 +namespace = "" 9.151 + 9.152 +###################################################################### 9.153 +# Output string s. '\n' may only be at the end of the string (not 9.154 +# somewhere in the middle). 9.155 +# 9.156 +# In: s - String 9.157 +# spos - Startpos 9.158 +###################################################################### 9.159 +def output(s,spos, immediate=0): 9.160 + global outbuffer, out_row, out_col, outfile 9.161 + 9.162 + os = string.rjust(s,spos[1]-out_col+len(s)) 9.163 + 9.164 + if immediate: 9.165 + outfile.write(os) 9.166 + else: 9.167 + outbuffer.append(os) 9.168 + 9.169 + assert -1 == string.find(s[0:-2], "\n"), s 9.170 + 9.171 + if (s[-1:]=="\n"): 9.172 + out_row = out_row+1 9.173 + out_col = 0 9.174 + else: 9.175 + out_col = spos[1]+len(s) 9.176 + 9.177 + 9.178 +###################################################################### 9.179 +# Records a name and parameters. The name is either a class name or 9.180 +# a function name. Then the parameter is either the base class or 9.181 +# the function parameters. 9.182 +# The name is stored in the global variable "name", the parameters 9.183 +# in "param". 9.184 +# The variable "record_state" holds the current state of this internal 9.185 +# state machine. 9.186 +# The recording is started by calling start_recording(). 9.187 +# 9.188 +# In: type, tok 9.189 +###################################################################### 9.190 +def rec_name_n_param(type, tok): 9.191 + global record_state,name,param,doc_string,bracket_counter 9.192 + s = record_state 9.193 + # State 0: Do nothing. 9.194 + if (s==0): 9.195 + return 9.196 + # State 1: Remember name. 9.197 + elif (s==1): 9.198 + name = tok 9.199 + record_state = 2 9.200 + # State 2: Wait for opening bracket or colon 9.201 + elif (s==2): 9.202 + if (tok=='('): 9.203 + bracket_counter = 1 9.204 + record_state=3 9.205 + if (tok==':'): record_state=4 9.206 + # State 3: Store parameter (or base class) and wait for an ending bracket 9.207 + elif (s==3): 9.208 + if (tok=='*' or tok=='**'): 9.209 + tok='' 9.210 + if (tok=='('): 9.211 + bracket_counter = bracket_counter+1 9.212 + if (tok==')'): 9.213 + bracket_counter = bracket_counter-1 9.214 + if bracket_counter==0: 9.215 + record_state=4 9.216 + else: 9.217 + param=param+tok 9.218 + # State 4: Look for doc string 9.219 + elif (s==4): 9.220 + if (type==token.NEWLINE or type==token.INDENT or type==token.SLASHEQUAL): 9.221 + return 9.222 + elif (tok==":"): 9.223 + return 9.224 + elif (type==token.STRING): 9.225 + while tok[:1]=='r' or tok[:1]=='u': 9.226 + tok=tok[1:] 9.227 + while tok[:1]=='"': 9.228 + tok=tok[1:] 9.229 + while tok[-1:]=='"': 9.230 + tok=tok[:-1] 9.231 + doc_string=tok 9.232 + record_state=0 9.233 + 9.234 +###################################################################### 9.235 +# Starts the recording of a name & param part. 9.236 +# The function rec_name_n_param() has to be fed with tokens. After 9.237 +# the necessary tokens are fed the name and parameters can be found 9.238 +# in the global variables "name" und "param". 9.239 +###################################################################### 9.240 +def start_recording(): 9.241 + global record_state,param,name, doc_string 9.242 + record_state=1 9.243 + name="" 9.244 + param="" 9.245 + doc_string="" 9.246 + 9.247 +###################################################################### 9.248 +# Test if recording is finished 9.249 +###################################################################### 9.250 +def is_recording_finished(): 9.251 + global record_state 9.252 + return record_state==0 9.253 + 9.254 +###################################################################### 9.255 +## Gather comment block 9.256 +###################################################################### 9.257 +def gather_comment(type,tok,spos): 9.258 + global comment_block,comment_finished 9.259 + if (type!=tokenize.COMMENT): 9.260 + comment_finished = 1 9.261 + else: 9.262 + # Output old comment block if a new one is started. 9.263 + if (comment_finished): 9.264 + print_comment(spos) 9.265 + comment_finished=0 9.266 + if (tok[0:2]=="##" and tok[0:3]!="###"): 9.267 + append_comment_lines(tok[2:]) 9.268 + 9.269 +###################################################################### 9.270 +## Output comment block and empty buffer. 9.271 +###################################################################### 9.272 +def print_comment(spos): 9.273 + global comment_block,comment_finished 9.274 + if (comment_block!=[]): 9.275 + output("/** ",spos) 9.276 + for c in comment_block: 9.277 + output(c,spos) 9.278 + output("*/\n",spos) 9.279 + comment_block = [] 9.280 + comment_finished = 0 9.281 + 9.282 +###################################################################### 9.283 +def set_state(s): 9.284 + global stateStack 9.285 + stateStack[len(stateStack)-1]=s 9.286 + 9.287 +###################################################################### 9.288 +def get_state(): 9.289 + global stateStack 9.290 + return stateStack[len(stateStack)-1] 9.291 + 9.292 +###################################################################### 9.293 +def push_state(s): 9.294 + global stateStack 9.295 + stateStack.append(s) 9.296 + 9.297 +###################################################################### 9.298 +def pop_state(): 9.299 + global stateStack 9.300 + stateStack.pop() 9.301 + 9.302 + 9.303 +###################################################################### 9.304 +def tok_eater(type, tok, spos, epos, line): 9.305 + global stateStack,name,param,class_spos,def_spos,import_spos 9.306 + global doc_string, modules, import_token, module_has_docstring 9.307 + global protection_level, private_member 9.308 + global out_row 9.309 + 9.310 + while out_row + 1 < spos[0]: 9.311 + output("\n", (0, 0)) 9.312 + 9.313 + rec_name_n_param(type,tok) 9.314 + if (string.replace(string.strip(tok)," ","")=="##private:"): 9.315 + protection_level = "private" 9.316 + output("private:\n",spos) 9.317 + elif (string.replace(string.strip(tok)," ","")=="##protected:"): 9.318 + protection_level = "protected" 9.319 + output("protected:\n",spos) 9.320 + elif (string.replace(string.strip(tok)," ","")=="##public:"): 9.321 + protection_level = "public" 9.322 + output("public:\n",spos) 9.323 + else: 9.324 + gather_comment(type,tok,spos) 9.325 + 9.326 + state = get_state() 9.327 + 9.328 +# sys.stderr.write("%d: %s\n"%(state, tok)) 9.329 + 9.330 + # OUTSIDE 9.331 + if (state==OUTSIDE): 9.332 + if (tok=="class"): 9.333 + start_recording() 9.334 + class_spos = spos 9.335 + push_state(BUILD_CLASS_DECL) 9.336 + elif (tok=="def"): 9.337 + start_recording() 9.338 + def_spos = spos 9.339 + push_state(BUILD_DEF_DECL) 9.340 + elif (tok=="import") or (tok=="from"): 9.341 + import_token = tok 9.342 + import_spos = spos 9.343 + modules = [] 9.344 + push_state(IMPORT) 9.345 + elif (spos[1] == 0 and tok[:3] == '"""'): 9.346 + # Capture module docstring as namespace documentation 9.347 + module_has_docstring = True 9.348 + append_comment_lines("\\namespace %s\n" % namespace) 9.349 + append_comment_lines(tok[3:-3]) 9.350 + print_comment(spos) 9.351 + 9.352 + # IMPORT 9.353 + elif (state==IMPORT): 9.354 + if (type==token.NAME): 9.355 + modules.append(tok) 9.356 + set_state(IMPORT_OP) 9.357 + # IMPORT_OP 9.358 + elif (state==IMPORT_OP): 9.359 + if (tok=="."): 9.360 + set_state(IMPORT_APPEND) 9.361 + elif (tok==","): 9.362 + set_state(IMPORT) 9.363 + else: 9.364 + for m in modules: 9.365 + output('#include "'+m.replace('.',os.path.sep)+'.py"\n', import_spos, immediate=1) 9.366 + if import_token=="from": 9.367 + output('using namespace '+m.replace('.', '::')+';\n', import_spos) 9.368 + pop_state() 9.369 + # IMPORT_APPEND 9.370 + elif (state==IMPORT_APPEND): 9.371 + if (type==token.NAME): 9.372 + modules[len(modules)-1]+="."+tok 9.373 + set_state(IMPORT_OP) 9.374 + # BUILD_CLASS_DECL 9.375 + elif (state==BUILD_CLASS_DECL): 9.376 + if (is_recording_finished()): 9.377 + s = "class "+name 9.378 + if (param!=""): s = s+" : public "+param.replace('.','::') 9.379 + if (doc_string!=""): 9.380 + append_comment_lines(doc_string) 9.381 + print_comment(class_spos) 9.382 + output(s+"\n",class_spos) 9.383 + output("{\n",(class_spos[0]+1,class_spos[1])) 9.384 + protection_level = "public" 9.385 + output(" public:\n",(class_spos[0]+2,class_spos[1])) 9.386 + set_state(BUILD_CLASS_BODY) 9.387 + # BUILD_CLASS_BODY 9.388 + elif (state==BUILD_CLASS_BODY): 9.389 + if (type!=token.INDENT and type!=token.NEWLINE and type!=40 and 9.390 + type!=tokenize.NL and type!=tokenize.COMMENT and 9.391 + (spos[1]<=class_spos[1])): 9.392 + output("}; // end of class\n",(out_row+1,class_spos[1])) 9.393 + pop_state() 9.394 + elif (tok=="def"): 9.395 + start_recording() 9.396 + def_spos = spos 9.397 + push_state(BUILD_DEF_DECL) 9.398 + # BUILD_DEF_DECL 9.399 + elif (state==BUILD_DEF_DECL): 9.400 + if (is_recording_finished()): 9.401 + param = param.replace("\n", " ") 9.402 + param = param.replace("=", " = ") 9.403 + params = param.split(",") 9.404 + if BUILD_CLASS_BODY in stateStack: 9.405 + if len(name) > 1 \ 9.406 + and name[0:2] == '__' \ 9.407 + and name[len(name)-2:len(name)] != '__' \ 9.408 + and protection_level != 'private': 9.409 + private_member = True 9.410 + output(" private:\n",(def_spos[0]+2,def_spos[1])) 9.411 + 9.412 + if (doc_string != ""): 9.413 + append_comment_lines(doc_string) 9.414 + 9.415 + print_comment(def_spos) 9.416 + 9.417 + output_function_decl(name, params) 9.418 +# output("{\n",(def_spos[0]+1,def_spos[1])) 9.419 + set_state(BUILD_DEF_BODY) 9.420 + # BUILD_DEF_BODY 9.421 + elif (state==BUILD_DEF_BODY): 9.422 + if (type!=token.INDENT and type!=token.NEWLINE \ 9.423 + and type!=40 and type!=tokenize.NL \ 9.424 + and (spos[1]<=def_spos[1])): 9.425 +# output("} // end of method/function\n",(out_row+1,def_spos[1])) 9.426 + if private_member and protection_level != 'private': 9.427 + private_member = False 9.428 + output(" " + protection_level + ":\n",(def_spos[0]+2,def_spos[1])) 9.429 + pop_state() 9.430 +# else: 9.431 +# output(tok,spos) 9.432 + 9.433 + 9.434 +def output_function_decl(name, params): 9.435 + global def_spos 9.436 + 9.437 + # Do we document a class method? then remove the 'self' parameter 9.438 + if params[0] == 'self': 9.439 + preamble = '' 9.440 + params = params[1:] 9.441 + else: 9.442 + preamble = 'static ' 9.443 + if params[0] == 'cls': 9.444 + params = params[1:] 9.445 + 9.446 + param_string = string.join(params, ", Type ") 9.447 + 9.448 + if param_string == '': 9.449 + param_string = '(' + param_string + ');\n' 9.450 + else: 9.451 + param_string = '(Type ' + param_string + ');\n' 9.452 + 9.453 + output(preamble, def_spos) 9.454 + output(name, def_spos) 9.455 + output(param_string, def_spos) 9.456 + 9.457 + 9.458 +def append_comment_lines(lines): 9.459 + map(append_comment_line, doc_string.split('\n')) 9.460 + 9.461 +paramRE = re.compile(r'(@param \w+):') 9.462 + 9.463 +def append_comment_line(line): 9.464 + global paramRE 9.465 + 9.466 + comment_block.append(paramRE.sub(r'\1', line) + '\n') 9.467 + 9.468 +def dump(filename): 9.469 + f = open(filename) 9.470 + r = f.readlines() 9.471 + for s in r: 9.472 + sys.stdout.write(s) 9.473 + 9.474 +def filter(filename): 9.475 + global name, module_has_docstring, source_root 9.476 + 9.477 + path,name = os.path.split(filename) 9.478 + root,ext = os.path.splitext(name) 9.479 + 9.480 + if source_root and path.find(source_root) == 0: 9.481 + path = path[len(source_root):] 9.482 + 9.483 + if path[0] == os.sep: 9.484 + path = path[1:] 9.485 + 9.486 + ns = path.split(os.sep) 9.487 + else: 9.488 + ns = [] 9.489 + 9.490 + ns.append(root) 9.491 + 9.492 + for n in ns: 9.493 + output("namespace " + n + " {\n",(0,0)) 9.494 + 9.495 + # set module name for tok_eater to use if there's a module doc string 9.496 + name = root 9.497 + 9.498 +# sys.stderr.write('Filtering "'+filename+'"...') 9.499 + f = open(filename) 9.500 + tokenize.tokenize(f.readline, tok_eater) 9.501 + f.close() 9.502 + print_comment((0,0)) 9.503 + 9.504 + output("\n",(0,0)) 9.505 + 9.506 + for n in ns: 9.507 + output("} // end of namespace\n",(0,0)) 9.508 + 9.509 + if not module_has_docstring: 9.510 + # Put in default namespace documentation 9.511 + output('/** \\namespace '+root+' \n',(0,0)) 9.512 + output(' \\brief Module "%s" */\n'%(root),(0,0)) 9.513 + 9.514 + for s in outbuffer: 9.515 + outfile.write(s) 9.516 + 9.517 + 9.518 +def filterFile(filename, out=sys.stdout): 9.519 + global outfile 9.520 + 9.521 + outfile = out 9.522 + 9.523 + try: 9.524 + root,ext = os.path.splitext(filename) 9.525 + 9.526 + if ext==".py": 9.527 + filter(filename) 9.528 + else: 9.529 + dump(filename) 9.530 + 9.531 +# sys.stderr.write("OK\n") 9.532 + except IOError,e: 9.533 + sys.stderr.write(e[1]+"\n") 9.534 + 9.535 + 9.536 +###################################################################### 9.537 + 9.538 +# preparePath 9.539 +def preparePath(path): 9.540 + """Prepare a path. 9.541 + 9.542 + Checks if the path exists and creates it if it does not exist. 9.543 + """ 9.544 + if not os.path.exists(path): 9.545 + parent = os.path.dirname(path) 9.546 + if parent!="": 9.547 + preparePath(parent) 9.548 + os.mkdir(path) 9.549 + 9.550 +# isNewer 9.551 +def isNewer(file1,file2): 9.552 + """Check if file1 is newer than file2. 9.553 + 9.554 + file1 must be an existing file. 9.555 + """ 9.556 + if not os.path.exists(file2): 9.557 + return True 9.558 + return os.stat(file1)[ST_MTIME]>os.stat(file2)[ST_MTIME] 9.559 + 9.560 +# convert 9.561 +def convert(srcpath, destpath): 9.562 + """Convert a Python source tree into a C+ stub tree. 9.563 + 9.564 + All *.py files in srcpath (including sub-directories) are filtered 9.565 + and written to destpath. If destpath exists, only the files 9.566 + that have been modified are filtered again. Files that were deleted 9.567 + from srcpath are also deleted in destpath if they are still present. 9.568 + The function returns the number of processed *.py files. 9.569 + """ 9.570 + count=0 9.571 + sp = os.path.join(srcpath,"*") 9.572 + sfiles = glob.glob(sp) 9.573 + dp = os.path.join(destpath,"*") 9.574 + dfiles = glob.glob(dp) 9.575 + leftovers={} 9.576 + for df in dfiles: 9.577 + leftovers[os.path.basename(df)]=1 9.578 + 9.579 + for srcfile in sfiles: 9.580 + basename = os.path.basename(srcfile) 9.581 + if basename in leftovers: 9.582 + del leftovers[basename] 9.583 + 9.584 + # Is it a subdirectory? 9.585 + if os.path.isdir(srcfile): 9.586 + sdir = os.path.join(srcpath,basename) 9.587 + ddir = os.path.join(destpath,basename) 9.588 + count+=convert(sdir, ddir) 9.589 + continue 9.590 + # Check the extension (only *.py will be converted) 9.591 + root, ext = os.path.splitext(srcfile) 9.592 + if ext.lower()!=".py": 9.593 + continue 9.594 + 9.595 + destfile = os.path.join(destpath,basename) 9.596 + if destfile==srcfile: 9.597 + print "WARNING: Input and output names are identical!" 9.598 + sys.exit(1) 9.599 + 9.600 + count+=1 9.601 +# sys.stdout.write("%s\015"%(srcfile)) 9.602 + 9.603 + if isNewer(srcfile, destfile): 9.604 + preparePath(os.path.dirname(destfile)) 9.605 +# out=open(destfile,"w") 9.606 +# filterFile(srcfile, out) 9.607 +# out.close() 9.608 + os.system("python %s -f %s>%s"%(sys.argv[0],srcfile,destfile)) 9.609 + 9.610 + # Delete obsolete files in destpath 9.611 + for df in leftovers: 9.612 + dname=os.path.join(destpath,df) 9.613 + if os.path.isdir(dname): 9.614 + try: 9.615 + shutil.rmtree(dname) 9.616 + except: 9.617 + print "Can't remove obsolete directory '%s'"%dname 9.618 + else: 9.619 + try: 9.620 + os.remove(dname) 9.621 + except: 9.622 + print "Can't remove obsolete file '%s'"%dname 9.623 + 9.624 + return count 9.625 + 9.626 + 9.627 +###################################################################### 9.628 +###################################################################### 9.629 +###################################################################### 9.630 + 9.631 +filter_file = False 9.632 +source_root = None 9.633 + 9.634 +try: 9.635 + opts, args = getopt.getopt(sys.argv[1:], "hfr:", ["help"]) 9.636 +except getopt.GetoptError,e: 9.637 + print e 9.638 + sys.exit(1) 9.639 + 9.640 +for o,a in opts: 9.641 + if o=="-f": 9.642 + filter_file = True 9.643 + 9.644 + if o=="-r": 9.645 + source_root = os.path.abspath(a) 9.646 + 9.647 +if filter_file: 9.648 + # Filter the specified file and print the result to stdout 9.649 + filename = string.join(args) 9.650 + filterFile(os.path.abspath(filename)) 9.651 +else: 9.652 + 9.653 + if len(args)!=2: 9.654 + sys.stderr.write("%s options input output\n"%(os.path.basename(sys.argv[0]))) 9.655 + sys.exit(1) 9.656 + 9.657 + # Filter an entire Python source tree 9.658 + print '"%s" -> "%s"\n'%(args[0],args[1]) 9.659 + c=convert(args[0],args[1]) 9.660 + print "%d files"%(c) 9.661 +
40.1 --- a/tools/examples/Makefile Tue Sep 13 15:32:38 2005 +0000 40.2 +++ b/tools/examples/Makefile Tue Sep 13 15:33:37 2005 +0000 40.3 @@ -25,7 +25,7 @@ XEN_SCRIPTS += block-phy 40.4 XEN_SCRIPTS += block-file 40.5 XEN_SCRIPTS += block-enbd 40.6 40.7 -XEN_BOOT_DIR = /usr/lib/xen/boot 40.8 +XEN_BOOT_DIR = /usr/$(LIBDIR)/xen/boot 40.9 XEN_BOOT = mem-map.sxp 40.10 40.11 XEN_HOTPLUG_DIR = /etc/hotplug 40.12 @@ -37,12 +37,15 @@ build: 40.13 install: all install-initd install-configs install-scripts install-boot \ 40.14 install-hotplug 40.15 40.16 +xmexample.vmx: xmexample.vmx.in 40.17 + sed -e 's/@@LIBDIR@@/$(LIBDIR)/' < $< > $@ 40.18 + 40.19 install-initd: 40.20 [ -d $(DESTDIR)/etc/init.d ] || $(INSTALL_DIR) $(DESTDIR)/etc/init.d 40.21 $(INSTALL_PROG) $(XEND_INITD) $(DESTDIR)/etc/init.d 40.22 $(INSTALL_PROG) $(XENDOMAINS_INITD) $(DESTDIR)/etc/init.d 40.23 40.24 -install-configs: 40.25 +install-configs: $(XEN_CONFIGS) 40.26 [ -d $(DESTDIR)$(XEN_CONFIG_DIR) ] || \ 40.27 $(INSTALL_DIR) $(DESTDIR)$(XEN_CONFIG_DIR) 40.28 [ -d $(DESTDIR)$(XEN_CONFIG_DIR)/auto ] || \ 40.29 @@ -77,3 +80,4 @@ install-hotplug: 40.30 done 40.31 40.32 clean: 40.33 + $(RM) xmexample.vmx
44.1 --- a/tools/examples/xmexample.vmx Tue Sep 13 15:32:38 2005 +0000 44.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 44.3 @@ -1,96 +0,0 @@ 44.4 -# -*- mode: python; -*- 44.5 -#============================================================================ 44.6 -# Python configuration setup for 'xm create'. 44.7 -# This script sets the parameters used when a domain is created using 'xm create'. 44.8 -# You use a separate script for each domain you want to create, or 44.9 -# you can set the parameters for the domain on the xm command line. 44.10 -#============================================================================ 44.11 - 44.12 -#---------------------------------------------------------------------------- 44.13 -# Kernel image file. 44.14 -kernel = "/usr/lib/xen/boot/vmxloader" 44.15 - 44.16 -# The domain build function. VMX domain uses 'vmx'. 44.17 -builder='vmx' 44.18 - 44.19 -# Initial memory allocation (in megabytes) for the new domain. 44.20 -memory = 128 44.21 - 44.22 -# A name for your domain. All domains must have different names. 44.23 -name = "ExampleVMXDomain" 44.24 - 44.25 -# Which CPU to start domain on? 44.26 -#cpu = -1 # leave to Xen to pick 44.27 - 44.28 -# Optionally define mac and/or bridge for the network interfaces. 44.29 -# Random MACs are assigned if not given. 44.30 -#vif = [ 'mac=aa:00:00:00:00:11, bridge=xen-br0' ] 44.31 - 44.32 -#---------------------------------------------------------------------------- 44.33 -# Define the disk devices you want the domain to have access to, and 44.34 -# what you want them accessible as. 44.35 -# Each disk entry is of the form phy:UNAME,DEV,MODE 44.36 -# where UNAME is the device, DEV is the device name the domain will see, 44.37 -# and MODE is r for read-only, w for read-write. 44.38 - 44.39 -#disk = [ 'phy:hda1,hda1,r' ] 44.40 -disk = [ 'file:/var/images/min-el3-i386.img,ioemu:hda,w' ] 44.41 - 44.42 -#---------------------------------------------------------------------------- 44.43 -# Set according to whether you want the domain restarted when it exits. 44.44 -# The default is 'onreboot', which restarts the domain when it shuts down 44.45 -# with exit code reboot. 44.46 -# Other values are 'always', and 'never'. 44.47 - 44.48 -#restart = 'onreboot' 44.49 - 44.50 -#============================================================================ 44.51 - 44.52 - 44.53 -# New stuff 44.54 -device_model = '/usr/lib/xen/bin/qemu-dm' 44.55 - 44.56 -# Advanced users only. Don't touch if you don't know what you're doing 44.57 -memmap = '/usr/lib/xen/boot/mem-map.sxp' 44.58 - 44.59 -#----------------------------------------------------------------------------- 44.60 -# Disk image for 44.61 -#cdrom= 44.62 - 44.63 -#----------------------------------------------------------------------------- 44.64 -# boot on floppy (a), hard disk (c) or CD-ROM (d) 44.65 -#boot=[a|c|d] 44.66 -#----------------------------------------------------------------------------- 44.67 -# write to temporary files instead of disk image files 44.68 -#snapshot=1 44.69 - 44.70 -#---------------------------------------------------------------------------- 44.71 -# enable SDL library for graphics, default = 0 44.72 -sdl=0 44.73 - 44.74 -#---------------------------------------------------------------------------- 44.75 -# enable VNC library for graphics, default = 1 44.76 -vnc=1 44.77 - 44.78 -#---------------------------------------------------------------------------- 44.79 -# enable spawning vncviewer(only valid when vnc=1), default = 1 44.80 -vncviewer=1 44.81 - 44.82 -#---------------------------------------------------------------------------- 44.83 -# no graphics, use serial port 44.84 -#nographic=0 44.85 - 44.86 - 44.87 -#----------------------------------------------------------------------------- 44.88 -# enable audio support 44.89 -#enable-audio=1 44.90 - 44.91 - 44.92 -#----------------------------------------------------------------------------- 44.93 -# set the real time clock to local time [default=0 i.e. set to utc] 44.94 -#localtime=1 44.95 - 44.96 - 44.97 -#----------------------------------------------------------------------------- 44.98 -# start in full screen 44.99 -#full-screen=1
45.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 45.2 +++ b/tools/examples/xmexample.vmx.in Tue Sep 13 15:33:37 2005 +0000 45.3 @@ -0,0 +1,96 @@ 45.4 +# -*- mode: python; -*- 45.5 +#============================================================================ 45.6 +# Python configuration setup for 'xm create'. 45.7 +# This script sets the parameters used when a domain is created using 'xm create'. 45.8 +# You use a separate script for each domain you want to create, or 45.9 +# you can set the parameters for the domain on the xm command line. 45.10 +#============================================================================ 45.11 + 45.12 +#---------------------------------------------------------------------------- 45.13 +# Kernel image file. 45.14 +kernel = "/usr/@@LIBDIR@@/xen/boot/vmxloader" 45.15 + 45.16 +# The domain build function. VMX domain uses 'vmx'. 45.17 +builder='vmx' 45.18 + 45.19 +# Initial memory allocation (in megabytes) for the new domain. 45.20 +memory = 128 45.21 + 45.22 +# A name for your domain. All domains must have different names. 45.23 +name = "ExampleVMXDomain" 45.24 + 45.25 +# Which CPU to start domain on? 45.26 +#cpu = -1 # leave to Xen to pick 45.27 + 45.28 +# Optionally define mac and/or bridge for the network interfaces. 45.29 +# Random MACs are assigned if not given. 45.30 +#vif = [ 'mac=aa:00:00:00:00:11, bridge=xen-br0' ] 45.31 + 45.32 +#---------------------------------------------------------------------------- 45.33 +# Define the disk devices you want the domain to have access to, and 45.34 +# what you want them accessible as. 45.35 +# Each disk entry is of the form phy:UNAME,DEV,MODE 45.36 +# where UNAME is the device, DEV is the device name the domain will see, 45.37 +# and MODE is r for read-only, w for read-write. 45.38 + 45.39 +#disk = [ 'phy:hda1,hda1,r' ] 45.40 +disk = [ 'file:/var/images/min-el3-i386.img,ioemu:hda,w' ] 45.41 + 45.42 +#---------------------------------------------------------------------------- 45.43 +# Set according to whether you want the domain restarted when it exits. 45.44 +# The default is 'onreboot', which restarts the domain when it shuts down 45.45 +# with exit code reboot. 45.46 +# Other values are 'always', and 'never'. 45.47 + 45.48 +#restart = 'onreboot' 45.49 + 45.50 +#============================================================================ 45.51 + 45.52 + 45.53 +# New stuff 45.54 +device_model = '/usr/@@LIBDIR@@/xen/bin/qemu-dm' 45.55 + 45.56 +# Advanced users only. Don't touch if you don't know what you're doing 45.57 +memmap = '/usr/@@LIBDIR@@/xen/boot/mem-map.sxp' 45.58 + 45.59 +#----------------------------------------------------------------------------- 45.60 +# Disk image for 45.61 +#cdrom= 45.62 + 45.63 +#----------------------------------------------------------------------------- 45.64 +# boot on floppy (a), hard disk (c) or CD-ROM (d) 45.65 +#boot=[a|c|d] 45.66 +#----------------------------------------------------------------------------- 45.67 +# write to temporary files instead of disk image files 45.68 +#snapshot=1 45.69 + 45.70 +#---------------------------------------------------------------------------- 45.71 +# enable SDL library for graphics, default = 0 45.72 +sdl=0 45.73 + 45.74 +#---------------------------------------------------------------------------- 45.75 +# enable VNC library for graphics, default = 1 45.76 +vnc=1 45.77 + 45.78 +#---------------------------------------------------------------------------- 45.79 +# enable spawning vncviewer(only valid when vnc=1), default = 1 45.80 +vncviewer=1 45.81 + 45.82 +#---------------------------------------------------------------------------- 45.83 +# no graphics, use serial port 45.84 +#nographic=0 45.85 + 45.86 + 45.87 +#----------------------------------------------------------------------------- 45.88 +# enable audio support 45.89 +#enable-audio=1 45.90 + 45.91 + 45.92 +#----------------------------------------------------------------------------- 45.93 +# set the real time clock to local time [default=0 i.e. set to utc] 45.94 +#localtime=1 45.95 + 45.96 + 45.97 +#----------------------------------------------------------------------------- 45.98 +# start in full screen 45.99 +#full-screen=1
47.1 --- a/tools/ioemu/target-i386-dm/Makefile Tue Sep 13 15:32:38 2005 +0000 47.2 +++ b/tools/ioemu/target-i386-dm/Makefile Tue Sep 13 15:33:37 2005 +0000 47.3 @@ -3,7 +3,7 @@ include $(XEN_ROOT)/tools/Rules.mk 47.4 include config.mak 47.5 override TARGET_ARCH=i386 47.6 47.7 -INSTALL_DIR := $(DESTDIR)/usr/lib/xen/bin 47.8 +INSTALL_DIR := $(DESTDIR)/usr/$(LIBDIR)/xen/bin 47.9 TARGET_PATH=$(SRC_PATH)/target-$(TARGET_ARCH) 47.10 VPATH=$(SRC_PATH):$(TARGET_PATH):$(SRC_PATH)/hw:$(SRC_PATH)/audio 47.11 DEFINES=-I. -I$(TARGET_PATH) -I$(SRC_PATH) -I$(XEN_ROOT)/xen/include/public
51.1 --- a/tools/python/Makefile Tue Sep 13 15:32:38 2005 +0000 51.2 +++ b/tools/python/Makefile Tue Sep 13 15:33:37 2005 +0000 51.3 @@ -1,7 +1,8 @@ 51.4 - 51.5 XEN_ROOT = ../.. 51.6 include $(XEN_ROOT)/tools/Rules.mk 51.7 51.8 +.PHONY: all build install clean 51.9 + 51.10 all: build 51.11 build: 51.12 CFLAGS="$(CFLAGS)" python setup.py build
52.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 52.2 +++ b/tools/python/pylintrc Tue Sep 13 15:33:37 2005 +0000 52.3 @@ -0,0 +1,307 @@ 52.4 +# lint Python modules using external checkers. 52.5 +# 52.6 +# This is the main checker controling the other ones and the reports 52.7 +# generation. It is itself both a raw checker and an astng checker in order 52.8 +# to: 52.9 +# * handle message activation / deactivation at the module level 52.10 +# * handle some basic but necessary stats'data (number of classes, methods...) 52.11 +# 52.12 +# This checker also defines the following reports: 52.13 +# * R0001: Total errors / warnings 52.14 +# * R0002: % errors / warnings by module 52.15 +# * R0003: Messages 52.16 +# * R0004: Global evaluation 52.17 +# 52.18 +[MASTER] 52.19 +# Add <file or directory> to the black list. It should be a base name, not a 52.20 +# path. You may set this option multiple times. 52.21 +ignore=CVS 52.22 + 52.23 +# Pickle collected data for later comparisons. 52.24 +persistent=yes 52.25 + 52.26 +# Set the cache size for astng objects. 52.27 +cache-size=500 52.28 + 52.29 + 52.30 + 52.31 +[REPORTS] 52.32 +# Tells wether to display a full report or only the messages 52.33 +reports=yes 52.34 + 52.35 +# Use HTML as output format instead of text 52.36 +html=no 52.37 + 52.38 +# Use a parseable text output format, so your favorite text editor will be able 52.39 +# to jump to the line corresponding to a message. 52.40 +parseable=no 52.41 + 52.42 +# Colorizes text output using ansi escape codes 52.43 +color=no 52.44 + 52.45 +# Put messages in a separate file for each module / package specified on the 52.46 +# command line instead of printing them on stdout. Reports (if any) will be 52.47 +# written in a file name "pylint_global.[txt|html]". 52.48 +files-output=no 52.49 + 52.50 +# Python expression which should return a note less than 10 (10 is the highest 52.51 +# note).You have access to the variables errors warning, statement which 52.52 +# respectivly contain the number of errors / warnings messages and the total 52.53 +# number of statements analyzed. This is used by the global evaluation report 52.54 +# (R0004). 52.55 +evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10) 52.56 + 52.57 +# Add a comment according to your evaluation note. This is used by the global 52.58 +# evaluation report (R0004). 52.59 +comment=no 52.60 + 52.61 +# Include message's id in output 52.62 +include-ids=yes 52.63 + 52.64 + 52.65 + 52.66 +# checks for 52.67 +# * unused variables / imports 52.68 +# * undefined variables 52.69 +# * redefinition of variable from builtins or from an outer scope 52.70 +# * use of variable before assigment 52.71 +# 52.72 +[VARIABLES] 52.73 +# Enable / disable this checker 52.74 +enable-variables=yes 52.75 + 52.76 +# Tells wether we should check for unused import in __init__ files. 52.77 +init-import=no 52.78 + 52.79 +# List of variable names used for dummy variables (i.e. not used). 52.80 +dummy-variables=_,dummy 52.81 + 52.82 + 52.83 + 52.84 +# checks for : 52.85 +# * doc strings 52.86 +# * modules / classes / functions / methods / arguments / variables name 52.87 +# * number of arguments, local variables, branchs, returns and statements in 52.88 +# functions, methods 52.89 +# * required module attributes 52.90 +# * dangerous default values as arguments 52.91 +# * redefinition of function / method / class 52.92 +# * uses of the global statement 52.93 +# 52.94 +# This checker also defines the following reports: 52.95 +# * R0101: Statistics by type 52.96 +# 52.97 +[BASIC] 52.98 +# Enable / disable this checker 52.99 +enable-basic=yes 52.100 + 52.101 +# Required attributes for module, separated by a comma 52.102 +required-attributes= 52.103 + 52.104 +# Regular expression which should only match functions or classes name which do 52.105 +# not require a docstring 52.106 +no-docstring-rgx=.* 52.107 + 52.108 +# Minimal length for module / class / function / method / argument / variable 52.109 +# names 52.110 +min-name-length=1 52.111 + 52.112 +# Regular expression which should only match correct module names 52.113 +module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$ 52.114 + 52.115 +# Regular expression which should only match correct class names 52.116 +class-rgx=[A-Z_][a-zA-Z0-9]+$ 52.117 + 52.118 +# Regular expression which should only match correct function names 52.119 +function-rgx=[a-z_][A-Za-z0-9_]*$ 52.120 + 52.121 +# Regular expression which should only match correct method names 52.122 +method-rgx=[a-z_][A-Za-z0-9_]*$ 52.123 + 52.124 +# Regular expression which should only match correct argument names 52.125 +argument-rgx=[a-z_][A-Za-z0-9_]*$ 52.126 + 52.127 +# Regular expression which should only match correct variable names 52.128 +variable-rgx=[a-z_][A-Za-z0-9_]*$ 52.129 + 52.130 +# Good variable names which should always be accepted, separated by a comma 52.131 +good-names=i,j,k,ex,Run,_ 52.132 + 52.133 +# Bad variable names which should always be refused, separated by a comma 52.134 +bad-names=foo,bar,baz,toto,tutu,tata 52.135 + 52.136 +# List of builtins function names that should not be used, separated by a comma 52.137 +bad-functions=map,filter,apply,input 52.138 + 52.139 + 52.140 + 52.141 +# checks for sign of poor/misdesign: 52.142 +# * number of methods, attributes, local variables... 52.143 +# * size, complexity of functions, methods 52.144 +# 52.145 +[DESIGN] 52.146 +# Enable / disable this checker 52.147 +enable-design=yes 52.148 + 52.149 +# Maximum number of arguments for function / method 52.150 +max-args=15 52.151 + 52.152 +# Maximum number of locals for function / method body 52.153 +max-locals=15 52.154 + 52.155 +# Maximum number of return / yield for function / method body 52.156 +max-returns=6 52.157 + 52.158 +# Maximum number of branch for function / method body 52.159 +max-branchs=12 52.160 + 52.161 +# Maximum number of statements in function / method body 52.162 +max-statements=50 52.163 + 52.164 +# Maximum number of parents for a class (see R0901). 52.165 +max-parents=7 52.166 + 52.167 +# Maximum number of attributes for a class (see R0902). 52.168 +max-attributes=7 52.169 + 52.170 +# Minimum number of public methods for a class (see R0903). 52.171 +min-public-methods=2 52.172 + 52.173 +# Maximum number of public methods for a class (see R0904). 52.174 +max-public-methods=20 52.175 + 52.176 + 52.177 + 52.178 +# checks for : 52.179 +# * methods without self as first argument 52.180 +# * overriden methods signature 52.181 +# * access only to existant members via self 52.182 +# * attributes not defined in the __init__ method 52.183 +# * supported interfaces implementation 52.184 +# * unreachable code 52.185 +# 52.186 +[CLASSES] 52.187 +# Enable / disable this checker 52.188 +enable-classes=yes 52.189 + 52.190 +# List of interface methods to ignore, separated by a comma. This is used for 52.191 +# instance to not check methods defines in Zope's Interface base class. 52.192 +ignore-iface-methods=isImplementedBy,deferred,extends,names,namesAndDescriptions,queryDescriptionFor,getBases,getDescriptionFor,getDoc,getName,getTaggedValue,getTaggedValueTags,isEqualOrExtendedBy,setTaggedValue,isImplementedByInstancesOf,adaptWith,is_implemented_by 52.193 + 52.194 +# Tells wether missing members accessed in mixin class should be ignored. A 52.195 +# mixin class is detected if its name ends with "mixin" (case insensitive). 52.196 +ignore-mixin-members=yes 52.197 + 52.198 + 52.199 + 52.200 +# checks for 52.201 +# * external modules dependencies 52.202 +# * relative / wildcard imports 52.203 +# * cyclic imports 52.204 +# * uses of deprecated modules 52.205 +# 52.206 +# This checker also defines the following reports: 52.207 +# * R0401: External dependencies 52.208 +# * R0402: Modules dependencies graph 52.209 +# 52.210 +[IMPORTS] 52.211 +# Enable / disable this checker 52.212 +enable-imports=no 52.213 + 52.214 +# Deprecated modules which should not be used, separated by a comma 52.215 +deprecated-modules=regsub,string,TERMIOS,Bastion,rexec 52.216 + 52.217 +# Create a graph of every (i.e. internal and external) dependencies in the given 52.218 +# file (report R0402 must not be disabled) 52.219 +import-graph= 52.220 + 52.221 +# Create a graph of external dependencies in the given file (report R0402 must 52.222 +# not be disabled) 52.223 +ext-import-graph= 52.224 + 52.225 +# Create a graph of internal dependencies in the given file (report R0402 must 52.226 +# not be disabled) 52.227 +int-import-graph= 52.228 + 52.229 + 52.230 + 52.231 +# checks for 52.232 +# * excepts without exception filter 52.233 +# * string exceptions 52.234 +# 52.235 +[EXCEPTIONS] 52.236 +# Enable / disable this checker 52.237 +enable-exceptions=yes 52.238 + 52.239 + 52.240 + 52.241 +# checks for : 52.242 +# * unauthorized constructions 52.243 +# * strict indentation 52.244 +# * line length 52.245 +# * use of <> instead of != 52.246 +# 52.247 +[FORMAT] 52.248 +# Enable / disable this checker 52.249 +enable-format=no 52.250 + 52.251 +# Maximum number of characters on a single line. 52.252 +max-line-length=80 52.253 + 52.254 +# Maximum number of lines in a module 52.255 +max-module-lines=1000 52.256 + 52.257 +# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1 tab). 52.258 +indent-string=' ' 52.259 + 52.260 + 52.261 + 52.262 +# does not check anything but gives some raw metrics : 52.263 +# * total number of lines 52.264 +# * total number of code lines 52.265 +# * total number of docstring lines 52.266 +# * total number of comments lines 52.267 +# * total number of empty lines 52.268 +# 52.269 +# This checker also defines the following reports: 52.270 +# * R0701: Raw metrics 52.271 +# 52.272 +[METRICS] 52.273 +# Enable / disable this checker 52.274 +enable-metrics=yes 52.275 + 52.276 + 52.277 + 52.278 +# checks for: 52.279 +# * warning notes in the code like FIXME, XXX 52.280 +# * PEP 263: source code with non ascii character but no encoding declaration 52.281 +# 52.282 +[MISCELLANEOUS] 52.283 +# Enable / disable this checker 52.284 +enable-miscellaneous=yes 52.285 + 52.286 +# List of note tags to take in consideration, separated by a comma. Default to 52.287 +# FIXME, XXX, TODO 52.288 +notes=FIXME,XXX,TODO 52.289 + 52.290 + 52.291 + 52.292 +# checks for similarities and duplicated code. This computation may be 52.293 +# memory / CPU intensive, so you should disable it if you experiments some 52.294 +# problems. 52.295 +# 52.296 +# This checker also defines the following reports: 52.297 +# * R0801: Duplication 52.298 +# 52.299 +[SIMILARITIES] 52.300 +# Enable / disable this checker 52.301 +enable-similarities=yes 52.302 + 52.303 +# Minimum lines number of a similarity. 52.304 +min-similarity-lines=4 52.305 + 52.306 +# Ignore comments when computing similarities. 52.307 +ignore-comments=yes 52.308 + 52.309 + 52.310 +
54.1 --- a/tools/python/xen/sv/DomInfo.py Tue Sep 13 15:32:38 2005 +0000 54.2 +++ b/tools/python/xen/sv/DomInfo.py Tue Sep 13 15:33:37 2005 +0000 54.3 @@ -75,7 +75,7 @@ class DomGeneralTab( CompositeTab ): 54.4 54.5 class DomGenTab( GeneralTab ): 54.6 54.7 - def __init__( self, urlWriter ): 54.8 + def __init__( self, _ ): 54.9 54.10 titles = {} 54.11 54.12 @@ -103,7 +103,7 @@ class DomGenTab( GeneralTab ): 54.13 54.14 class DomSXPTab( PreTab ): 54.15 54.16 - def __init__( self, urlWriter ): 54.17 + def __init__( self, _ ): 54.18 self.dom = 0 54.19 PreTab.__init__( self, "" ) 54.20 54.21 @@ -126,7 +126,7 @@ class DomSXPTab( PreTab ): 54.22 54.23 class DomActionTab( ActionTab ): 54.24 54.25 - def __init__( self, urlWriter ): 54.26 + def __init__( self, _ ): 54.27 actions = { "shutdown" : "Shutdown", 54.28 "reboot" : "Reboot", 54.29 "pause" : "Pause", 54.30 @@ -188,19 +188,19 @@ class DomDeviceListTab( NullTab ): 54.31 54.32 title = "Device List" 54.33 54.34 - def __init__( self, urlWriter ): 54.35 + def __init__( self, _ ): 54.36 pass 54.37 54.38 class DomDeviceOptionsTab( NullTab ): 54.39 54.40 title = "Device Options" 54.41 54.42 - def __init__( self, urlWriter ): 54.43 + def __init__( self, _ ): 54.44 pass 54.45 54.46 class DomDeviceActionTab( ActionTab ): 54.47 54.48 - def __init__( self, urlWriter ): 54.49 + def __init__( self, _ ): 54.50 ActionTab.__init__( self, { "addvcpu" : "Add VCPU", "addvbd" : "Add VBD", "addvif" : "Add VIF" } ) 54.51 54.52 class DomMigrateTab( CompositeTab ): 54.53 @@ -218,7 +218,7 @@ class DomMigrateExtraTab( Sheet ): 54.54 54.55 class DomMigrateActionTab( ActionTab ): 54.56 54.57 - def __init__( self, urlWriter ): 54.58 + def __init__( self, _ ): 54.59 actions = { "migrate" : "Migrate" } 54.60 ActionTab.__init__( self, actions ) 54.61 54.62 @@ -249,7 +249,7 @@ class DomSaveExtraTab( Sheet ): 54.63 54.64 class DomSaveActionTab( ActionTab ): 54.65 54.66 - def __init__( self, urlWriter ): 54.67 + def __init__( self, _ ): 54.68 actions = { "save" : "Save" } 54.69 ActionTab.__init__( self, actions ) 54.70
57.1 --- a/tools/python/xen/xend/XendDomainInfo.py Tue Sep 13 15:32:38 2005 +0000 57.2 +++ b/tools/python/xen/xend/XendDomainInfo.py Tue Sep 13 15:33:37 2005 +0000 57.3 @@ -103,34 +103,6 @@ def shutdown_reason(code): 57.4 """ 57.5 return shutdown_reasons.get(code, "?") 57.6 57.7 -config_handlers = {} 57.8 - 57.9 -def add_config_handler(name, h): 57.10 - """Add a handler for a config field. 57.11 - 57.12 - @param name: field name 57.13 - @param h: handler: fn(vm, config, field, index) 57.14 - """ 57.15 - config_handlers[name] = h 57.16 - 57.17 -def get_config_handler(name): 57.18 - """Get a handler for a config field. 57.19 - 57.20 - returns handler or None 57.21 - """ 57.22 - return config_handlers.get(name) 57.23 - 57.24 -"""Table of handlers for devices. 57.25 -Indexed by device type. 57.26 -""" 57.27 -device_handlers = {} 57.28 - 57.29 -def add_device_handler(name, type): 57.30 - device_handlers[name] = type 57.31 - 57.32 -def get_device_handler(name): 57.33 - return device_handlers[name] 57.34 - 57.35 def dom_get(dom): 57.36 """Get info from xen for an existing domain. 57.37 57.38 @@ -382,12 +354,6 @@ class XendDomainInfo: 57.39 57.40 __repr__ = __str__ 57.41 57.42 - def getDeviceTypes(self): 57.43 - return self.controllers.keys() 57.44 - 57.45 - def getDeviceControllers(self): 57.46 - return self.controllers.values() 57.47 - 57.48 def getDeviceController(self, type, error=True): 57.49 ctrl = self.controllers.get(type) 57.50 if not ctrl and error: 57.51 @@ -596,7 +562,7 @@ class XendDomainInfo: 57.52 57.53 def sxpr_devices(self): 57.54 sxpr = [] 57.55 - for ty in self.getDeviceTypes(): 57.56 + for ty in self.controllers.keys(): 57.57 devs = self.getDeviceSxprs(ty) 57.58 sxpr += devs 57.59 if sxpr: 57.60 @@ -787,7 +753,7 @@ class XendDomainInfo: 57.61 """Release all vm devices. 57.62 """ 57.63 reboot = self.restart_pending() 57.64 - for ctrl in self.getDeviceControllers(): 57.65 + for ctrl in self.controllers.values(): 57.66 if ctrl.isDestroyed(): continue 57.67 ctrl.destroyController(reboot=reboot) 57.68 t = xstransact("%s/device" % self.path) 57.69 @@ -845,6 +811,7 @@ class XendDomainInfo: 57.70 self.store_channel = self.eventChannel("store/port") 57.71 self.console_channel = self.eventChannel("console/port") 57.72 57.73 + 57.74 def create_configured_devices(self): 57.75 devices = sxp.children(self.config, 'device') 57.76 for d in devices: 57.77 @@ -852,18 +819,20 @@ class XendDomainInfo: 57.78 if dev_config is None: 57.79 raise VmError('invalid device') 57.80 dev_type = sxp.name(dev_config) 57.81 - ctrl_type = get_device_handler(dev_type) 57.82 - if ctrl_type is None: 57.83 + 57.84 + if not controller.isDevControllerClass(dev_type): 57.85 raise VmError('unknown device type: ' + dev_type) 57.86 - self.createDevice(ctrl_type, dev_config) 57.87 - 57.88 + 57.89 + self.createDevice(dev_type, dev_config) 57.90 + 57.91 + 57.92 def create_devices(self): 57.93 """Create the devices for a vm. 57.94 57.95 @raise: VmError for invalid devices 57.96 """ 57.97 if self.rebooting(): 57.98 - for ctrl in self.getDeviceControllers(): 57.99 + for ctrl in self.controllers.values(): 57.100 ctrl.initController(reboot=True) 57.101 else: 57.102 self.create_configured_devices() 57.103 @@ -1014,7 +983,7 @@ class XendDomainInfo: 57.104 msg = "Had a bootloader specified, but can't find disk" 57.105 log.error(msg) 57.106 raise VmError(msg) 57.107 - config = sxp.merge(['vm', blconfig ], self.config) 57.108 + config = sxp.merge(['vm', blcfg ], self.config) 57.109 return config 57.110 57.111 def configure_backends(self): 57.112 @@ -1063,7 +1032,7 @@ class XendDomainInfo: 57.113 for field in sxp.children(self.config): 57.114 field_name = sxp.name(field) 57.115 field_index = index.get(field_name, 0) 57.116 - field_handler = get_config_handler(field_name) 57.117 + field_handler = config_handlers.get(field_name) 57.118 # Ignore unknown fields. Warn? 57.119 if field_handler: 57.120 v = field_handler(self, self.config, field, field_index) 57.121 @@ -1133,23 +1102,17 @@ class XendDomainInfo: 57.122 # get run-time value of vcpus and update store 57.123 self.exportVCPUSToDB(dom_get(self.id)['vcpus']) 57.124 57.125 -def vm_field_ignore(vm, config, val, index): 57.126 + 57.127 +def vm_field_ignore(_, _1, _2, _3): 57.128 """Dummy config field handler used for fields with built-in handling. 57.129 - 57.130 - @param vm: virtual machine 57.131 - @param config: vm config 57.132 - @param val: config field 57.133 - @param index: field index 57.134 + Matches the signature required by config_handlers. 57.135 """ 57.136 pass 57.137 57.138 -def vm_field_maxmem(vm, config, val, index): 57.139 - """Configure vm memory limit. 57.140 57.141 - @param vm: virtual machine 57.142 - @param config: vm config 57.143 - @param val: config field 57.144 - @param index: field index 57.145 +def vm_field_maxmem(vm, _1, val, _2): 57.146 + """Config field handler to configure vm memory limit. Matches the 57.147 + signature required by config_handlers. 57.148 """ 57.149 maxmem = sxp.child0(val) 57.150 if maxmem is None: 57.151 @@ -1160,8 +1123,10 @@ def vm_field_maxmem(vm, config, val, ind 57.152 raise VmError("invalid maxmem: " + str(maxmem)) 57.153 xc.domain_setmaxmem(vm.id, maxmem_kb = maxmem * 1024) 57.154 57.155 + 57.156 #============================================================================ 57.157 # Register image handlers. 57.158 + 57.159 from image import \ 57.160 addImageHandlerClass, \ 57.161 ImageHandler, \ 57.162 @@ -1171,43 +1136,37 @@ from image import \ 57.163 addImageHandlerClass(LinuxImageHandler) 57.164 addImageHandlerClass(VmxImageHandler) 57.165 57.166 -# Ignore the fields we already handle. 57.167 -add_config_handler('name', vm_field_ignore) 57.168 -add_config_handler('memory', vm_field_ignore) 57.169 -add_config_handler('ssidref', vm_field_ignore) 57.170 -add_config_handler('cpu', vm_field_ignore) 57.171 -add_config_handler('cpu_weight', vm_field_ignore) 57.172 -add_config_handler('restart', vm_field_ignore) 57.173 -add_config_handler('image', vm_field_ignore) 57.174 -add_config_handler('device', vm_field_ignore) 57.175 -add_config_handler('backend', vm_field_ignore) 57.176 -add_config_handler('vcpus', vm_field_ignore) 57.177 -add_config_handler('bootloader', vm_field_ignore) 57.178 + 57.179 +"""Table of handlers for field configuration. 57.180 57.181 -# Register other config handlers. 57.182 -add_config_handler('maxmem', vm_field_maxmem) 57.183 +field_name[String]: fn(vm, config, field, index) -> value(ignored) 57.184 +""" 57.185 +config_handlers = { 57.186 + 57.187 + # Ignore the fields we already handle. 57.188 + 57.189 + 'name': vm_field_ignore, 57.190 + 'memory': vm_field_ignore, 57.191 + 'ssidref': vm_field_ignore, 57.192 + 'cpu': vm_field_ignore, 57.193 + 'cpu_weight': vm_field_ignore, 57.194 + 'restart': vm_field_ignore, 57.195 + 'image': vm_field_ignore, 57.196 + 'device': vm_field_ignore, 57.197 + 'backend': vm_field_ignore, 57.198 + 'vcpus': vm_field_ignore, 57.199 + 'bootloader': vm_field_ignore, 57.200 + 57.201 + # Register other config handlers. 57.202 + 'maxmem': vm_field_maxmem 57.203 + } 57.204 + 57.205 57.206 #============================================================================ 57.207 # Register device controllers and their device config types. 57.208 57.209 -from server import blkif 57.210 -controller.addDevControllerClass("vbd", blkif.BlkifController) 57.211 -add_device_handler("vbd", "vbd") 57.212 - 57.213 -from server import netif 57.214 -controller.addDevControllerClass("vif", netif.NetifController) 57.215 -add_device_handler("vif", "vif") 57.216 - 57.217 -from server import tpmif 57.218 -controller.addDevControllerClass("vtpm", tpmif.TPMifController) 57.219 -add_device_handler("vtpm", "vtpm") 57.220 - 57.221 -from server import pciif 57.222 -controller.addDevControllerClass("pci", pciif.PciController) 57.223 -add_device_handler("pci", "pci") 57.224 - 57.225 -from xen.xend.server import usbif 57.226 -controller.addDevControllerClass("usb", usbif.UsbifController) 57.227 -add_device_handler("usb", "usb") 57.228 - 57.229 -#============================================================================ 57.230 +controller.addDevControllerClass("vbd", server.blkif.BlkifController) 57.231 +controller.addDevControllerClass("vif", server.netif.NetifController) 57.232 +controller.addDevControllerClass("vtpm", server.tpmif.TPMifController) 57.233 +controller.addDevControllerClass("pci", server.pciif.PciController) 57.234 +controller.addDevControllerClass("usb", server.usbif.UsbifController)
58.1 --- a/tools/python/xen/xend/XendVnet.py Tue Sep 13 15:32:38 2005 +0000 58.2 +++ b/tools/python/xen/xend/XendVnet.py Tue Sep 13 15:33:37 2005 +0000 58.3 @@ -145,7 +145,7 @@ class XendVnet: 58.4 def vnet_get(self, id): 58.5 """Get a vnet. 58.6 58.7 - @param id: vnet id 58.8 + @param id vnet id 58.9 """ 58.10 id = str(id) 58.11 return self.vnet.get(id)
60.1 --- a/tools/python/xen/xend/scheduler.py Tue Sep 13 15:32:38 2005 +0000 60.2 +++ b/tools/python/xen/xend/scheduler.py Tue Sep 13 15:33:37 2005 +0000 60.3 @@ -20,8 +20,8 @@ import threading 60.4 def later(delay, fn, args=(), kwargs={}): 60.5 """Schedule a function to be called later. 60.6 60.7 - @param _delay: delay in seconds 60.8 - @param _fn: function 60.9 + @param delay: delay in seconds 60.10 + @param fn: function 60.11 @param args: arguments (list) 60.12 @param kwargs keyword arguments (map) 60.13 """ 60.14 @@ -32,7 +32,7 @@ def later(delay, fn, args=(), kwargs={}) 60.15 def now(fn, args=(), kwargs={}): 60.16 """Schedule a function to be called now. 60.17 60.18 - @param _fn: function 60.19 + @param fn: function 60.20 @param args: arguments (list) 60.21 @param kwargs keyword arguments (map) 60.22 """
61.1 --- a/tools/python/xen/xend/server/controller.py Tue Sep 13 15:32:38 2005 +0000 61.2 +++ b/tools/python/xen/xend/server/controller.py Tue Sep 13 15:33:37 2005 +0000 61.3 @@ -63,6 +63,13 @@ def addDevControllerClass(name, cls): 61.4 cls.type = name 61.5 getDevControllerTable().addDevControllerClass(cls) 61.6 61.7 + 61.8 +def isDevControllerClass(name): 61.9 + """@return True if a device controller class has been registered with 61.10 + the controller table under the given name.""" 61.11 + return name in getDevControllerTable().controllerClasses 61.12 + 61.13 + 61.14 def createDevController(name, vm, recreate=False): 61.15 return getDevControllerTable().createDevController(name, vm, recreate=recreate) 61.16
68.1 --- a/tools/xenstore/xenstore_client.c Tue Sep 13 15:32:38 2005 +0000 68.2 +++ b/tools/xenstore/xenstore_client.c Tue Sep 13 15:33:37 2005 +0000 68.3 @@ -76,7 +76,7 @@ main(int argc, char **argv) 68.4 /* NOTREACHED */ 68.5 } 68.6 #if defined(CLIENT_write) 68.7 - if ((argc - optind) % 1) { 68.8 + if ((argc - optind) % 2 == 1) { 68.9 usage(argv[0]); 68.10 /* NOTREACHED */ 68.11 }