summary refs log tree commit diff stats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/nim.cfg30
-rw-r--r--config/nimdoc.cfg87
2 files changed, 101 insertions, 16 deletions
diff --git a/config/nim.cfg b/config/nim.cfg
index 93b847784..8c8270f3e 100644
--- a/config/nim.cfg
+++ b/config/nim.cfg
@@ -23,10 +23,6 @@ arm.linux.gcc.linkerexe = "arm-linux-gcc"
 mips.linux.gcc.exe = "mips-openwrt-linux-gcc"
 mips.linux.gcc.linkerexe = "mips-openwrt-linux-gcc"
 
-@if not nimfix:
-  cs:partial
-@end
-
 path="$lib/deprecated/core"
 path="$lib/deprecated/pure"
 path="$lib/pure/collections"
@@ -70,7 +66,7 @@ path="$lib/pure"
 @end
 
 @if unix:
-  @if not bsd:
+  @if not bsd or haiku:
     # -fopenmp
     gcc.options.linker = "-ldl"
     gcc.cpp.options.linker = "-ldl"
@@ -84,6 +80,14 @@ path="$lib/pure"
     # at least NetBSD has problems with thread local storage:
     tlsEmulation:on
   @end
+  @if haiku:
+    # -fopenmp
+    gcc.options.linker = "-lroot -lnetwork"
+    gcc.cpp.options.linker = "-lroot -lnetwork"
+    clang.options.linker = "-lroot -lnetwork"
+    clang.cpp.options.linker = "-lroot -lnetwork"
+    tcc.options.linker = "-lroot -lnetwork"
+  @end
 @end
 
 # Configuration for the Intel C/C++ compiler:
@@ -126,6 +130,17 @@ clang.objc.options.linker = "-lobjc -lgnustep-base"
   clang.objc.options.linker = "-framework Foundation"
 @end
 
+# Options for FreeBSD, OpenBSD, NetBSD linker to add locations for searching
+# shared libraries.
+@if freebsd or openbsd or netbsd:
+  gcc.options.linker = "-Wl,-rpath=.:/usr/local/lib:/usr/pkg/lib:/usr/X11R6/lib"
+  gcc.cpp.options.linker = "-Wl,-rpath=.:/usr/local/lib:/usr/pkg/lib:/usr/X11R6/lib"
+  llvm_gcc.options.linker = "-Wl,-rpath=.:/usr/local/lib:/usr/pkg/lib:/usr/X11R6/lib"
+  llvm_gcc.cpp.options.linker = "-Wl,-rpath=.:/usr/local/lib:/usr/pkg/lib:/usr/X11R6/lib"
+  clang.options.linker = "-Wl,-rpath=.:/usr/local/lib:/usr/pkg/lib:/usr/X11R6/lib"
+  clang.cpp.options.linker = "-Wl,-rpath=.:/usr/local/lib:/usr/pkg/lib:/usr/X11R6/lib"
+@end
+
 # Configuration for the VxWorks
 # This has been tested with VxWorks 6.9 only
 @if vxworks:
@@ -168,10 +183,5 @@ vcc.options.always = "/nologo"
 vcc.options.speed = "/O2 /arch:SSE2"
 vcc.options.size = "/O1"
 
-# Configuration for the Digital Mars C/C++ compiler:
-@if windows:
-  dmc.path = r"$nimrod\dist\dm\bin"
-@end
-
 # Configuration for the Tiny C Compiler:
 tcc.options.always = "-w"
diff --git a/config/nimdoc.cfg b/config/nimdoc.cfg
index d973b922a..832b4ffd0 100644
--- a/config/nimdoc.cfg
+++ b/config/nimdoc.cfg
@@ -1,5 +1,5 @@
 # This is the config file for the documentation generator.
-# (c) 2012 Andreas Rumpf
+# (c) 2016 Andreas Rumpf
 # Feel free to edit the templates as you need. If you modify this file, it
 # might be worth updating the hardcoded values in packages/docutils/rstgen.nim
 
@@ -49,7 +49,7 @@ $seeSrc
 # See doc.item for available substitution variables.
 doc.item.toc = """
   <li><a class="reference" href="#$itemSymOrID"
-    title="$header_plain">$name</a></li>
+    title="$header_plain">$name<span class="attachedType" style="visibility:hidden">$attype</span></a></li>
 """
 
 # HTML rendered for doc.item's seeSrc variable. Note that this will render to
@@ -60,8 +60,10 @@ doc.item.toc = """
 # * $url: whatever you did pass through the --docSeeSrcUrl switch (which also
 #   gets variables path/line replaced!)
 doc.item.seesrc = """&nbsp;&nbsp;<a
-href="${url}/${path}#L${line}"
-class="link-seesrc" target="_blank">Source</a>"""
+href="${url}/tree/${commit}/${path}#L${line}"
+class="link-seesrc" target="_blank">Source</a>
+<a href="${url}/edit/devel/${path}#L${line}" class="link-seesrc" target="_blank" >Edit</a>
+"""
 
 doc.toc = """
 <ul class="simple simple-toc" id="toc-list">
@@ -72,9 +74,38 @@ $content
 doc.body_toc = """
 <div class="row">
   <div class="three columns">
+  <div>
+    Search: <input type="text" id="searchInput"
+      onkeyup="search()" />
+  </div>
+  $tableofcontents
+  </div>
+  <div class="nine columns" id="content">
+  <div id="tocRoot"></div>
+  <p class="module-desc">$moduledesc</p>
+  $content
+  </div>
+</div>
+"""
+
+doc.body_toc_group = """
+<div class="row">
+  <div class="three columns">
+  <div>
+    Search: <input type="text" id="searchInput"
+      onkeyup="search()" />
+  </div>
+  <div>
+    Group by:
+    <select onchange="groupBy(this.value)">
+      <option value="section">Section</option>
+      <option value="type">Type</option>
+    </select>
+  </div>
   $tableofcontents
   </div>
   <div class="nine columns" id="content">
+  <div id="tocRoot"></div>
   <p class="module-desc">$moduledesc</p>
   $content
   </div>
@@ -93,7 +124,7 @@ doc.listing_end = "</pre>"
 doc.file = """<?xml version="1.0" encoding="utf-8" ?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<!--  This file is generated by Nimrod. -->
+<!--  This file is generated by Nim. -->
 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
@@ -1235,10 +1266,54 @@ dt pre > span.Operator ~ span.Identifier, dt pre > span.Operator ~ span.Operator
   background-repeat: no-repeat;
   background-image: url("data:image/x-icon;base64,AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AAAAAAUAAAAF////AP///wD///8A////AP///wD///8A////AP///wD///8A////AAAAAAIAAABbAAAAlQAAAKIAAACbAAAAmwAAAKIAAACVAAAAWwAAAAL///8A////AP///wD///8A////AAAAABQAAADAAAAAYwAAAA3///8A////AP///wD///8AAAAADQAAAGMAAADAAAAAFP///wD///8A////AP///wAAAACdAAAAOv///wD///8A////AP///wD///8A////AP///wD///8AAAAAOgAAAJ3///8A////AP///wAAAAAnAAAAcP///wAAAAAoAAAASv///wD///8A////AP///wAAAABKAAAAKP///wAAAABwAAAAJ////wD///8AAAAAgQAAABwAAACIAAAAkAAAAJMAAACtAAAAFQAAABUAAACtAAAAkwAAAJAAAACIAAAAHAAAAIH///8A////AAAAAKQAAACrAAAAaP///wD///8AAAAARQAAANIAAADSAAAARf///wD///8AAAAAaAAAAKsAAACk////AAAAADMAAACcAAAAnQAAABj///8A////AP///wAAAAAYAAAAGP///wD///8A////AAAAABgAAACdAAAAnAAAADMAAAB1AAAAwwAAAP8AAADpAAAAsQAAAE4AAAAb////AP///wAAAAAbAAAATgAAALEAAADpAAAA/wAAAMMAAAB1AAAAtwAAAOkAAAD/AAAA/wAAAP8AAADvAAAA3gAAAN4AAADeAAAA3gAAAO8AAAD/AAAA/wAAAP8AAADpAAAAtwAAAGUAAAA/AAAA3wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAADfAAAAPwAAAGX///8A////AAAAAEgAAADtAAAAvwAAAL0AAADGAAAA7wAAAO8AAADGAAAAvQAAAL8AAADtAAAASP///wD///8A////AP///wD///8AAAAAO////wD///8A////AAAAAIcAAACH////AP///wD///8AAAAAO////wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A////AP///wD///8A//8AAP//AAD4HwAA7/cAAN/7AAD//wAAoYUAAJ55AACf+QAAh+EAAAAAAADAAwAA4AcAAP5/AAD//wAA//8AAA==");
   margin-bottom: -5px; }
+  div.pragma {
+    display: none;
+  }
+  span.pragmabegin {
+    cursor: pointer;
+  }
+  span.pragmaend {
+    cursor: pointer;
+  }
+
+div.search_results {
+  background-color: antiquewhite;
+  margin: 3em;
+  padding: 1em;
+  border: 1px solid #4d4d4d;
+}
 </style>
 
+<script type="text/javascript" src="../dochack.js"></script>
+
+<script type="text/javascript">
+function togglepragma(d) {
+  if (d.style.display != 'inline')
+    d.style.display = 'inline';
+  else
+    d.style.display = 'none';
+}
+
+function main() {
+  var elements = document.getElementsByClassName("pragmabegin");
+  for (var i = 0; i < elements.length; ++i) {
+    var e = elements[i];
+    e.onclick = function(event) {
+      togglepragma(event.target.nextSibling);
+    };
+  }
+  var elements = document.getElementsByClassName("pragmaend");
+  for (var i = 0; i < elements.length; ++i) {
+    var e = elements[i];
+    e.onclick = function(event) {
+      togglepragma(event.target.previousSibling);
+    };
+  }
+}
+</script>
+
 </head>
-<body>
+<body onload="main()">
 <div class="document" id="documentId">
   <div class="container">
     <h1 class="title">$title</h1>