aboutsummaryrefslogtreecommitdiffstats
path: root/doc/building/llvm
diff options
context:
space:
mode:
authorPatrick Lehmann <Patrick.Lehmann@tu-dresden.de>2017-03-04 20:36:18 +0100
committertgingold <tgingold@users.noreply.github.com>2017-12-10 12:02:05 +0100
commit3f5cd97cc29039f8f153541808ca85938c00eef4 (patch)
treea4877e168191ef1e888f3a37fd7b46ece7daebb6 /doc/building/llvm
parentf38b0364b5a769eb97e87c6fbf5fc303101883d2 (diff)
downloadghdl-3f5cd97cc29039f8f153541808ca85938c00eef4.tar.gz
ghdl-3f5cd97cc29039f8f153541808ca85938c00eef4.tar.bz2
ghdl-3f5cd97cc29039f8f153541808ca85938c00eef4.zip
Restructured build section. Created smaller files. Created (hidden) sub-ToCs. Added out-dated build instructions for Windows GNAT GPL flow from private README.md.
Diffstat (limited to 'doc/building/llvm')
-rw-r--r--doc/building/llvm/GNULinux-GNAT.rst26
-rw-r--r--doc/building/llvm/index.rst50
2 files changed, 76 insertions, 0 deletions
diff --git a/doc/building/llvm/GNULinux-GNAT.rst b/doc/building/llvm/GNULinux-GNAT.rst
new file mode 100644
index 000000000..d72de34a2
--- /dev/null
+++ b/doc/building/llvm/GNULinux-GNAT.rst
@@ -0,0 +1,26 @@
+.. _BUILD:mcode:GNULinux-GNAT:
+
+GNU/Linux with GCC/GNAT
+#######################
+
+On Linux, GHDL is configured by ``configure`` and build by ``make``.
+
+* First, GHDL needs to be configured. It is common to specify a PREFIX
+ (installation directory like ``/usr/local`` or ``/opt/ghdl``). Without any
+ other option, ``configure`` select `mcode` as backend.
+
+* Next, ``make`` starts the compilation process.
+
+* Finally, ``make install`` installs GHDL into the installation directory
+ specified by PREFIX. You may need super user privileges (``sudo ...``).
+
+.. rubric:: Example:
+
+.. code-block:: Bash
+
+ cd <ghdl>
+ mkdir build
+ cd build
+ ../configure --prefix=PREFIX
+ make
+ sudo make install
diff --git a/doc/building/llvm/index.rst b/doc/building/llvm/index.rst
new file mode 100644
index 000000000..a2faf9d74
--- /dev/null
+++ b/doc/building/llvm/index.rst
@@ -0,0 +1,50 @@
+.. _BUILD:llvm:
+
+LLVM Backend
+############
+
+.. rubric:: Requirements
+
+* GCC (Gnu Compiler Collection)
+* GNAT (Ada compiler for GCC)
+* LLVM (Low-Level-Virtual Machine)
+
+ * 3.5
+ * 3.8
+
+* CLANG (Compiler front-end for LLVM)
+
+ * 3.5
+ * 3.8
+
+.. rubric:: Supported platforms
+
+* :ref:`GNU/Linux with GCC <BUILD:mcode:GNULinux-GCC>`
+* :ref:`Windows (x86_64) with MinGW32/MinGW64 <BUILD:mcode:Windows-WinGW>`
+
+.. toctree::
+ :hidden:
+
+ GNULinux-GNAT
+ Windows-WinGW
+
+
+
+GNU/Linux
+---------
+
+You need to install LLVM (usually depends on :samp:`libedit`, see :ghdlsharp`29`). The supported versions are 3.5 till 3.9, but debugging is only supported with LLVM 3.5.
+
+- First configure GHDL with the proper arg :samp:`./configure --with-llvm-config`. If :samp:`llvm-config` is not in your path, you can specify it: :samp:`./configure --with-llvm-config=LLVM_INSTALL/bin/llvm-config`.
+
+.. HINT:: If you want to have stack backtraces on errors (like assert failure or index of out bounds), you need to configure and build :samp:`libbacktrace` from GCC (you don't need to configure GCC). Then add the following arg to configure: :samp:`--with-backtrace-lib=/path-to-gcc-build/libbacktrace/.libs/libbacktrace.a`
+
+- Then build with :samp:`make` and install with :samp:`make install`.
+
+Mac OS?
+-------
+
+Windows MinGW 32/64
+-------------------
+
+ \ No newline at end of file