summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael J. Spencer <bigcheesegs@gmail.com>2012-04-25 19:34:24 +0000
committerMichael J. Spencer <bigcheesegs@gmail.com>2012-04-25 19:34:24 +0000
commit365f1ec246889a93d6ac7cc7e217eeee6e2ad571 (patch)
tree9cf517b256a600653d5eecf6ccd71674eeb43ef3
parentd712ef0fd75388423210c5b3cf7ce86c0182886a (diff)
downloadbcm5719-llvm-365f1ec246889a93d6ac7cc7e217eeee6e2ad571.tar.gz
bcm5719-llvm-365f1ec246889a93d6ac7cc7e217eeee6e2ad571.zip
[docs] Add getting started guide.
llvm-svn: 155578
-rw-r--r--lld/docs/development.rst2
-rw-r--r--lld/docs/getting_started.rst99
-rw-r--r--lld/docs/index.rst1
3 files changed, 101 insertions, 1 deletions
diff --git a/lld/docs/development.rst b/lld/docs/development.rst
index 2b12e38ff60..c24e83b64a4 100644
--- a/lld/docs/development.rst
+++ b/lld/docs/development.rst
@@ -5,7 +5,7 @@ Development
lld is developed as part of the `LLVM <http://llvm.org>`_ project.
-.. todo:: Write "getting started" style instructions for developers.
+See the :ref:`getting started <getting_started>` guide.
The project documentation is written in reStructuredText and generated using the
`Sphinx <http://sphinx.pocoo.org/>`_ documentation generator. For more
diff --git a/lld/docs/getting_started.rst b/lld/docs/getting_started.rst
new file mode 100644
index 00000000000..d20b25700d6
--- /dev/null
+++ b/lld/docs/getting_started.rst
@@ -0,0 +1,99 @@
+.. _getting_started:
+
+Getting Started: Building and Running lld
+=========================================
+
+This page gives you the shortest path to checking out and building lld. If you
+run into problems, please file bugs in the `LLVM Bugzilla`__
+
+__ http://llvm.org/bugs/
+
+Building lld
+------------
+
+On Unix-like Systems
+~~~~~~~~~~~~~~~~~~~~
+
+#. Get the required tools.
+
+ * `CMake 2.8`_\+.
+ * make (or any build system CMake supports).
+ * `Clang 3.1`_\+ or GCC 4.7+ (C++11 support is required).
+
+ * If using Clang, you will also need `libc++`_.
+ * `Python 2.4`_\+ (not 3.x) for running tests.
+
+.. _CMake 2.8: http://www.cmake.org/cmake/resources/software.html
+.. _Clang 3.1: http://clang.llvm.org/
+.. _libc++: http://libcxx.llvm.org/
+.. _Python 2.4: http://python.org/download/
+
+#. Check out LLVM::
+
+ $ cd path/to/llvm-project
+ $ svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
+
+#. Check out lld::
+
+ $ cd llvm/tools
+ $ svn co http://llvm.org/svn/llvm-project/lld/trunk lld
+
+ * lld can also be checked out to ``path/to/llvm-project`` and built as an external
+ project.
+
+#. Build LLVM and lld::
+
+ $ cd path/to/llvm-build/llvm (out of source build required)
+ $ cmake -G "Unix Makefiles" path/to/llvm-project/llvm
+ $ make
+
+#. Test::
+
+ $ make lld-test
+
+Using Visual Studio
+~~~~~~~~~~~~~~~~~~~
+
+#. Get the required tools.
+
+ * `CMake 2.8`_\+.
+ * `Visual Studio 11`_ (required for C++11 support)
+ * `Python 2.4`_\+ (not 3.x) for running tests.
+
+.. _CMake 2.8: http://www.cmake.org/cmake/resources/software.html
+.. _Visual Studio 11: http://www.microsoft.com/visualstudio/11/en-us
+.. _Python 2.4: http://python.org/download/
+
+#. Check out LLVM::
+
+ $ cd path/to/llvm-project
+ $ svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
+
+#. Check out lld::
+
+ $ cd llvm/tools
+ $ svn co http://llvm.org/svn/llvm-project/lld/trunk lld
+
+ * lld can also be checked out to ``path/to/llvm-project`` and built as an external
+ project.
+
+#. Generate Visual Studio project files::
+
+ $ cd path/to/llvm-build/llvm (out of source build required)
+ $ cmake -G "Visual Studio 11" path/to/llvm-project/llvm
+
+#. Build
+
+ * Open LLVM.sln in Visual Studio.
+ * Build the ``ALL_BUILD`` target.
+
+#. Test
+
+ * Build the ``lld-test`` target.
+
+More Information
+~~~~~~~~~~~~~~~~
+
+For more information on using CMake see the `LLVM CMake guide`_.
+
+.. _LLVM Cmake guide: http://llvm.org/docs/CMake.html
diff --git a/lld/docs/index.rst b/lld/docs/index.rst
index 94ff3487d63..9d4b8c20016 100644
--- a/lld/docs/index.rst
+++ b/lld/docs/index.rst
@@ -66,6 +66,7 @@ Contents
:maxdepth: 2
design
+ getting_started
development
open_projects
sphinx_intro
OpenPOWER on IntegriCloud