Advertisement
Guest User

Untitled

a guest
Apr 11th, 2012
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 14.85 KB | None | 0 0
  1. # -*- mode: perl -*-
  2. # Configuration file
  3. #
  4. # $Id: lxr.conf,v 1.49 2012/04/04 12:42:24 ajlittoz Exp $
  5. #
  6.  
  7. # This configuration file template can be automatically
  8. # preconfigured by script initial-config.sh during the
  9. # installation process.
  10.  
  11. (
  12. ################################
  13. # Global configuration section #
  14. ################################
  15.  
  16. {
  17. # Auxiliary tools subsection #
  18. #============================#
  19.  
  20. # Place where lxr can write temporary files
  21. 'tmpdir' => '/tmp'
  22.  
  23. # Define this OR the swish-e variable depending which search engine you want to use.
  24. # Path to glimpse executables.
  25. # e.g.: , 'glimpsebin' => '/usr/local/bin/glimpse'
  26. , 'glimpsebin' => '/usr/bin/glimpse'
  27. , 'glimpseindex' => '/usr/bin/glimpseindex'
  28. # Location of SWISH-E binary
  29. # e.g.: , 'swishbin' => '/usr/local/bin/swish-e'
  30. # , 'swishbin' => '%swish%'
  31. # Location of the SWISH-E.conf file
  32. # , 'swishconf' => '/var/www/localhost/htdocs/lxr/templates/swish-e.conf'
  33.  
  34. # Path to Exuberant Ctags executable
  35. , 'ectagsbin' => '/usr/bin/ctags'
  36. # Location of the ectags.conf file
  37. , 'ectagsconf' => '/var/www/localhost/htdocs/lxr/templates/ectags.conf'
  38.  
  39. # Paths for CVS module
  40. # , 'cvspath' => '/bin:/usr/local/bin:/usr/bin:/usr/sbin'
  41.  
  42. # Computer DNS names subsection #
  43. #================================
  44. , 'host_names' => [ '//localhost', 'http://localhost', 'http://127.0.0.1' ]
  45.  
  46. # HTML subsection #
  47. #=================#
  48.  
  49. # All paths in this subsection are relative to LXR root directory
  50.  
  51. # Templates used for headers and footers
  52. , 'htmlfatal' => 'templates/html/html-fatal.html'
  53. , 'htmlhead' => 'templates/html/html-head.html'
  54. , 'htmltail' => 'templates/html/html-tail.html'
  55. , 'htmldir' => 'templates/html/html-dir.html'
  56. , 'htmlident' => 'templates/html/html-ident.html'
  57. , 'htmlsearch' => 'templates/html/html-search-glimpse.html'
  58. , 'htmlconfig' => 'templates/html/html-config.html'
  59.  
  60. # htmlhead and htmltail can be customised for the various
  61. # LXR operations. Just replace html by source (listing file),
  62. # sourcedir (displaying directory), diff (difference markup),
  63. # ident (identifier search), search (free-text search)
  64. # as below (which changes nothing):
  65. , 'sourcehead' => 'templates/html/html-head.html'
  66. , 'sourcedirhead' => 'templates/html/html-head.html'
  67.  
  68. # showconfig script is a bit special since "version" has
  69. # no meaning for it. Better to wipe out the 'variables' selection
  70. # links with an adequate header:
  71. , 'showconfighead' => 'templates/html/config-head-btn-smaller.html'
  72.  
  73. # Default character width of left version (for diff)
  74. , 'diffleftwidth' => 50
  75.  
  76. # Default identifier search constraint (for ident)
  77. # , 'identdefonly' => 1
  78.  
  79. # CSS style sheet
  80. , 'stylesheet' => 'templates/lxr.css'
  81. # , 'alternate_stylesheet' => [ 'lxrconf.d/another.css' ]
  82.  
  83. # Default character encoding
  84. , 'encoding' => 'utf-8', #'iso-8859-1',
  85.  
  86. # File management subsection #
  87. #============================#
  88.  
  89. # Which extensions to treat as images when browsing. If a file is an image,
  90. # it is displayed.
  91. , 'graphicfile' =>
  92. 'bitmap|bmp|gif|icon?|jp2|jpe?g|pjpe?g|png|svg|tiff?|xbm|xpm'
  93.  
  94. # Which file extensions are associated with which icon
  95. # Below is an example using 'Oxygen' theme available with KDE
  96. # small-icons/ is a symbolic link to
  97. # /usr/share/icons/oxygen/22x22/mimetypes/
  98. # (This location is valid for Fedora distributions,
  99. # check for others)
  100. # , 'iconfolder' => 'small-icons/'
  101. # Don't forget the final / above.
  102. # , 'icons' =>
  103. # { 'c|pc' => 'text-x-csrc.png'
  104. # , 'h|hh' => 'text-x-chdr.png'
  105. # , 'c\+\+|cc|cpp|cxx' => 'text-x-c++src.png'
  106. # , 'hpp|hxx|h\+\+' => 'text-x-c++hdr.png'
  107. # , 'java' => 'text-x-java.png'
  108. # , 'js' => 'application-x-javascript.png'
  109. # , 'pl|pm|perl' => 'application-x-perl.png'
  110. # , 'php|php3|phtml' => 'application-x-php.png'
  111. # , 'py|python' => 'text-x-python.png'
  112. # , 'sh|bsh|bash|ksh|zsh' => 'text-x-script.png'
  113. # , 's?html?' => 'text-html.png'
  114. # , 'css' => 'text-css.png'
  115. # , 'pdf' => 'application-pdf.png'
  116. # , 'txt' => 'text-plain.png'
  117. # , 'p|pas' => 'text-x-pascal.png'
  118. # , 'patch' => 'text-x-patch.png'
  119. # , 'sql' => 'text-x-sql.png'
  120. # , 'rb' => 'application-x-ruby.png'
  121. # , 'ui' => 'text-xml.png'
  122. # , '.*\~' => 'application-x-trash'
  123. # }
  124. # , 'graphicicon' => 'image-x-generic.png'
  125. # , 'defaulticon' => 'unknown.png'
  126. # , 'diricon' => 'inode-directory.png'
  127.  
  128. # How to map files to languages
  129. , 'filetypeconf' => '/var/www/localhost/htdocs/lxr/templates/filetype.conf'
  130.  
  131. # Location of the Generic.pm config file
  132. , 'genericconf' => '/var/www/localhost/htdocs/lxr/lib/LXR/Lang/generic.conf'
  133.  
  134. # "Common factor" subsection #
  135. #============================#
  136.  
  137. # In case your LXR installation controls several trees,
  138. # put here what you consider common parameters between
  139. # your source trees.
  140. # A parameter is "common" if its value must be simultaneously
  141. # adjusted in every tree.
  142.  
  143. # Pattern for extracting tree name from URL, since all
  144. # trees are usually served from the same physical server.
  145. , 'treeextract' => '([^/]*)/[^/]*$'
  146.  
  147. # User name and password for DB access are usually the same,
  148. # even if the database name is tree-specific.
  149. # , 'dbpass' => 'lxr'
  150. , 'dbuser' => 'lxr'
  151. # Table prefix (parameter dbprefix) is also a common parameter
  152. # unless you stuff all tree data in a single database.
  153. # It has a default hard-coded value:
  154. # , 'dbprefix' => 'lxr_'
  155. }
  156.  
  157. ###############################
  158. # Tree configuration sections #
  159. ###############################
  160.  
  161. , {
  162.  
  163. # Server configuration subsection #
  164. #=================================#
  165.  
  166. # NOTE --------------------------------------------------- #
  167. # ---- 'baseurl' and 'baseurl_aliases' are deprecated ---- #
  168. # ---- in favor of 'host_names'. ---- #
  169. # ---- See "Global configuration section" ---- #
  170. # ---- ---- #
  171. # ---- 'host_names' takes precedence if 'baseurl' is ---- #
  172. # ---- also defined. ---- #
  173. # ---- ---- #
  174. # ---- Support for 'baseurl' is maintained for ---- #
  175. # ---- compatibility with existing LXRs. ---- #
  176. # ---- ---- #
  177. # Configuration for http://192.168.1.1/lxr.
  178. # baseurl is used to select configuration block.
  179. # 'baseurl' => 'http://localhost/lxr' # Put your URL here
  180. # # baseurl_aliases allows other URLs to be used to reach the site
  181. # # comment this out if you do not want any aliases
  182. # , 'baseurl_aliases' =>
  183. # [ 'http://localhost/lxr'
  184. # , 'http://mydomain/lxr'
  185. # ]
  186. # ---- ---- #
  187. # ---- End of deprecated parameters ---- #
  188. # ---- If you use them, uncomment the comma below ---- #
  189. # -------------------------------------------------------- #
  190. # ,
  191.  
  192. 'virtroot' => '/lxr' # The bit after the / above
  193.  
  194. # Title for this tree to display in page header area
  195. # if you aren't satisfied with the default
  196. , 'caption' => 'Linux kernel'
  197.  
  198. # Button title to switch to this tree when multiple
  199. # trees are managed by LXR
  200. # , 'shortcaption' => 'My tree'
  201.  
  202. # Character encoding (overrides default if necessary)
  203. , 'encoding' => 'utf-8' #'iso-8859-1'
  204.  
  205. # a link of the form (prefix)($filepath)(postfix) is generated when viewing a file
  206. # example for cvsweb:
  207. # , 'cvswebprefix' => 'http://cvs.myhost.com/cgi-bin/cvsweb.cgi'
  208. # , 'cvswebpostfix' => '?cvsroot=rootname'
  209. # example for viewcvs:
  210. # , 'cvswebprefix' => 'http://cvs.myhost.com/cgi-bin/viewcvs.cgi/myroot'
  211. # , 'cvswebpostfix' => ''
  212.  
  213. # Tree location subsection #
  214. #==========================#
  215.  
  216. # sourceroot - where to get the source files from
  217.  
  218. # For ordinary directories, this specifies a directory which has each version as a
  219. # subdirectory e.g.
  220. # indexed-src/version1/...
  221. # indexed-src/version2/...
  222. # The names of the version directories must match the values for the Version
  223. # variable (see the version selection subsection).
  224. , 'sourceroot' => '/mnt/storage/project/kernel'
  225.  
  226. # Alternatively, this can specify a CVS repository by setting the value to "cvs:"
  227. # followed by the path to the repository. Note this must be file accessible - remote
  228. # server access does NOT work.
  229. # , 'sourceroot' => 'cvs:/home/karsk/a/CVSROOT/linux'
  230.  
  231. # For a BitKeeper repository, specify bk: followed by the path to the
  232. # repository. For BK it is also necessary to specify a 'cachepath' parameter in
  233. # the 'sourceparams' value below. This should point to a directory where the
  234. # code can write and read files.
  235. # , 'sourceroot' => 'bk:/some/repository/here'
  236.  
  237. # Finally, you can also use GIT, Linux Kernel's new
  238. # distributed SCM to access the history:
  239. # , 'sourceroot' => 'git:/some/repository/.git'
  240. # The 'sourceroot' config variable points to the directory
  241. # in which you find the `objects', `refs', `index' etc.
  242. # directories.
  243.  
  244. # The string to display as the base part of every path in the tree
  245. # , 'sourcerootname' => 'Example'
  246. # Or if you want automatic version insertion
  247. , 'sourcerootname' => '$v'
  248.  
  249. #
  250. # Any parameters to the source access method should be specified below.
  251. #
  252. # BK: 'cachepath' is used for temporary files
  253. # GIT: if `do_annotations' is non-zero, the file revision that
  254. # introduced each line is displayed.
  255. # `do_blame' will add the author of each line to the
  256. # output. Keep in mind that the core LXR code
  257. # will only request author information if
  258. # annotations are switched on, too!
  259. #
  260. # , 'sourceparams' =>
  261. # { 'cachepath' => '/a/path/here'
  262. # , 'do_annotate' => 1,
  263. # , 'do_blame' => 1
  264. # }
  265.  
  266. # Version selection subsection #
  267. #==============================#
  268.  
  269. , 'variables' =>
  270.  
  271. # Define typed variable "v".
  272. { 'v' =>
  273. { 'name' => 'Version'
  274. # This is the list of versions to index.
  275. # This can come from a file, a function or be explicitly
  276. # ennumerated.
  277. # From a file:
  278. # , 'range' => [ readfile('src/versions') ]
  279. # Explicitly:
  280. , 'range' => [qw(linux-3.0.6-gentoo_origin)]
  281. # If files within a tree can have different versions,
  282. # e.g in a CVS tree, 'range' can be specified as a
  283. # function to call for each file:
  284. # , 'range' => sub
  285. # { return ($files->allreleases($LXR::Common::pathname)
  286. # ,$files->allrevisions($LXR::Common::pathname)
  287. # )
  288. # } # deferred function call.
  289. #
  290. # When using a GIT repo, you can use its tags
  291. # to create a list of versions. As an extra
  292. # bonus, with the Linux::KernelSort Perl module,
  293. # you can properly sort kernel versions. Just
  294. # leave it off for generic projects.
  295. #
  296. # Simple example for any GIT repo:
  297. # , 'range' => sub
  298. # { my $some_dir = "/path/to/project/.git/refs/tags";
  299. # opendir (DIR, $some_dir) || die "cannot opendir $some_dir: $!";
  300. # my @files = grep { -f "$some_dir/$_" } readdir (DIR);
  301. # closedir DIR;
  302. # return sort @files;
  303. # }
  304. #
  305. # Advanced example for Linus's upstream
  306. # linux-2.6 kernel repository:
  307. # 'range' => sub
  308. # {
  309. # use Linux::KernelSort;
  310. # my $kernel = new Linux::KernelSort;
  311. #
  312. # my $some_dir = "/path/to/linux-2.6/.git/refs/tags";
  313. # opendir (DIR, $some_dir) || die "cannot opendir $some_dir: $!";
  314. # my @files = grep { -f "$some_dir/$_" } readdir (DIR);
  315. # closedir DIR;
  316. # # Linus's tags all have a leading "v"
  317. # # which we must cut off for sorting
  318. # # add again afterwards.
  319. # for (my $i = 0; $i < scalar (@files); $i++)
  320. # {
  321. # $files[$i] =~ s/^v//;
  322. # }
  323. # @files = $kernel->sort (@files);
  324. # for (my $i = 0; $i < scalar (@files); $i++)
  325. # {
  326. # $files[$i] =~ s/^/v/;
  327. # }
  328. #
  329. # return @files;
  330. # }
  331.  
  332. # The default version to display
  333. # If not specified, first in 'range' used
  334. # , 'default' => 'v3.1'
  335. }
  336.  
  337. # Define typed variable "a". First value is default.
  338. # Meaningful for Linux kernel
  339. # Comment out for average user source-tree
  340. , 'a' =>
  341. { 'name' => 'Architecture'
  342. , 'range' => [qw(alpha avr32 c6x frv hexagon m68k mips openrisc powerpc score sparc um x86 arm blackfin cris h8300 ia64 m32r microblaze mn10300 parisc s390 sh tile unicore32 xtensa)]
  343. , 'default' => 'x86'
  344. }
  345. # NOTE: If you implement the 'a' variable against the Kernel tree,
  346. # don't rely on the above list of architectures. It is out-dated.
  347. # To get an accurate list, type the following command in a
  348. # terminal: ls path-to-kernel-source/arch/
  349. # The directories list in the output gives the up-to-date list.
  350. }
  351.  
  352. # Subdirectory subsection #
  353. #=========================#
  354.  
  355. # Directories to always ignore. These usually are the SCM's
  356. # private directories which possibly may contain non-public
  357. # project history.
  358. , 'ignoredirs' => ['CVSROOT', '.git']
  359.  
  360. # Where to look for include files inside the sourcetree.
  361. # This is used to hyperlink to included files.
  362. # , 'incprefix' => [ '/include', '/include/linux' ]
  363.  
  364. # For the 2.x-3.x Linux kernel, use
  365. , 'incprefix' => [ '/include', '/arch/%=ARCH=%/include' ]
  366. # Leave the %=ARCH=% as is. It is needed by the 'maps' rule
  367. # and will be transformed into the appropriate subdir name.
  368.  
  369. # These do funky things to paths in the system - you probably don't need them.
  370. # , 'maps' =>
  371. # [ '/include/asm[^\/]*/' => '/include/asm-$a/'
  372. # , '/arch/[^\/]+/' => '/arch/$a/'
  373. # ],
  374.  
  375. # For the 2.x-3.x Linux kernel, use
  376. , 'maps' =>
  377. [ '^/arch/%-ARCH-%/' => '/arch/$a/'
  378. ]
  379. # Having a fully functional set of 'incprefix'/'maps' directives
  380. # for the kernel is not a trivial task. It requires defining many
  381. # auxiliary variables which are dependent on the current development
  382. # state of the kernel.
  383.  
  384. # Data storage subsection #
  385. #=========================#
  386.  
  387. # The DBI identifier for the database to use
  388. # For mysql, the format is dbi:mysql:dbname=<name>
  389. # for Postgres, it is dbi:Pg:dbname=<name>
  390. # for Oracle, it is dbi:Oracle:host=localhost;sid=DEVMMS;port=1521
  391. , 'dbname' => 'dbi:mysql:dbname=lxr'
  392.  
  393. # If you need to specify the username or password for the database connection,
  394. # uncomment the following two lines
  395. , 'dbuser' => 'lxr'
  396. # , 'dbpass' => 'foo'
  397.  
  398. # If you need multiple lxr configurations in one database, set different table
  399. # prefixes for them.
  400. # , 'dbprefix' => 'lxr_'
  401.  
  402. # For using glimpse, the directory to store the .glimpse files in is required
  403. , 'glimpsedir' => '/var/db/webapps/lxr/0.12.1/glimpse_db/'
  404.  
  405. # Location of swish-e index database files if using swish-e
  406. # , 'swishdir' => '/var/db/webapps/lxr/0.12.1/swish-e/'
  407. }
  408. )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement