From 1d4e62878e188704e4c599d50b4e3679a8189567 Mon Sep 17 00:00:00 2001 From: Bill Wendling Date: Thu, 21 Jun 2012 06:09:37 +0000 Subject: Sphinxify the outdated Packaging documentation. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158901 91177308-0d34-0410-b5e6-96231b3b80d8 --- docs/Packaging.html | 119 ---------------------------------------------------- docs/Packaging.rst | 75 +++++++++++++++++++++++++++++++++ docs/userguides.rst | 3 +- 3 files changed, 77 insertions(+), 120 deletions(-) delete mode 100644 docs/Packaging.html create mode 100644 docs/Packaging.rst diff --git a/docs/Packaging.html b/docs/Packaging.html deleted file mode 100644 index 51e9375e85..0000000000 --- a/docs/Packaging.html +++ /dev/null @@ -1,119 +0,0 @@ - - - - - Advice on Packaging LLVM - - - - -

Advice on Packaging LLVM

-
    -
  1. Overview
  2. -
  3. Compile Flags
  4. -
  5. C++ Features
  6. -
  7. Shared Library
  8. -
  9. Dependencies
  10. -
- - -

Overview

- -
- -

LLVM sets certain default configure options to make sure our developers don't -break things for constrained platforms. These settings are not optimal for most -desktop systems, and we hope that packagers (e.g., Redhat, Debian, MacPorts, -etc.) will tweak them. This document lists settings we suggest you tweak. -

- -

LLVM's API changes with each release, so users are likely to want, for -example, both LLVM-2.6 and LLVM-2.7 installed at the same time to support apps -developed against each. -

-
- - -

Compile Flags

- -
- -

LLVM runs much more quickly when it's optimized and assertions are removed. -However, such a build is currently incompatible with users who build without -defining NDEBUG, and the lack of assertions makes it hard to debug problems in -user code. We recommend allowing users to install both optimized and debug -versions of LLVM in parallel. The following configure flags are relevant: -

- -
-
--disable-assertions
Builds LLVM with NDEBUG - defined. Changes the LLVM ABI. Also available by setting - DISABLE_ASSERTIONS=0|1 in make's environment. This defaults - to enabled regardless of the optimization setting, but it slows things - down.
- -
--enable-debug-symbols
Builds LLVM with -g. - Also available by setting DEBUG_SYMBOLS=0|1 in make's - environment. This defaults to disabled when optimizing, so you should turn it - back on to let users debug their programs.
- -
--enable-optimized
(For svn checkouts) Builds LLVM with - -O2 and, by default, turns off debug symbols. Also available by - setting ENABLE_OPTIMIZED=0|1 in make's environment. This - defaults to enabled when not in a checkout.
-
-
- - -

C++ Features

- -
- -
-
RTTI
LLVM disables RTTI by default. Add REQUIRES_RTTI=1 - to your environment while running make to re-enable it. This will - allow users to build with RTTI enabled and still inherit from LLVM - classes.
-
-
- - -

Shared Library

- -
- -

Configure with --enable-shared to build -libLLVM-major.minor.(so|dylib) and link the tools -against it. This saves lots of binary size at the cost of some startup time. -

-
- - -

Dependencies

- -
- -
-
--enable-libffi
Depend on libffi to allow the LLVM -interpreter to call external functions.
-
--with-oprofile
Depend on libopagent -(>=version 0.9.4) to let the LLVM JIT tell oprofile about function addresses and -line numbers.
-
-
- - -
-
- Valid CSS - Valid HTML 4.01 - The LLVM Compiler Infrastructure
- Last modified: $Date$ -
- - diff --git a/docs/Packaging.rst b/docs/Packaging.rst new file mode 100644 index 0000000000..6e74158d72 --- /dev/null +++ b/docs/Packaging.rst @@ -0,0 +1,75 @@ +.. _packaging: + +======================== +Advice on Packaging LLVM +======================== + +.. contents:: + :local: + +Overview +======== + +LLVM sets certain default configure options to make sure our developers don't +break things for constrained platforms. These settings are not optimal for most +desktop systems, and we hope that packagers (e.g., Redhat, Debian, MacPorts, +etc.) will tweak them. This document lists settings we suggest you tweak. + +LLVM's API changes with each release, so users are likely to want, for example, +both LLVM-2.6 and LLVM-2.7 installed at the same time to support apps developed +against each. + +Compile Flags +============= + +LLVM runs much more quickly when it's optimized and assertions are removed. +However, such a build is currently incompatible with users who build without +defining ``NDEBUG``, and the lack of assertions makes it hard to debug problems +in user code. We recommend allowing users to install both optimized and debug +versions of LLVM in parallel. The following configure flags are relevant: + +``--disable-assertions`` + Builds LLVM with ``NDEBUG`` defined. Changes the LLVM ABI. Also available + by setting ``DISABLE_ASSERTIONS=0|1`` in ``make``'s environment. This + defaults to enabled regardless of the optimization setting, but it slows + things down. + +``--enable-debug-symbols`` + Builds LLVM with ``-g``. Also available by setting ``DEBUG_SYMBOLS=0|1`` in + ``make``'s environment. This defaults to disabled when optimizing, so you + should turn it back on to let users debug their programs. + +``--enable-optimized`` + (For svn checkouts) Builds LLVM with ``-O2`` and, by default, turns off + debug symbols. Also available by setting ``ENABLE_OPTIMIZED=0|1`` in + ``make``'s environment. This defaults to enabled when not in a + checkout. + +C++ Features +============ + +RTTI + LLVM disables RTTI by default. Add ``REQUIRES_RTTI=1`` to your environment + while running ``make`` to re-enable it. This will allow users to build with + RTTI enabled and still inherit from LLVM classes. + +Shared Library +============== + +Configure with ``--enable-shared`` to build +``libLLVM-..(so|dylib)`` and link the tools against it. This +saves lots of binary size at the cost of some startup time. + +Dependencies +============ + +``--enable-libffi`` + Depend on `libffi `_ to allow the LLVM + interpreter to call external functions. + +``--with-oprofile`` + + Depend on `libopagent + `_ (>=version 0.9.4) + to let the LLVM JIT tell oprofile about function addresses and line + numbers. diff --git a/docs/userguides.rst b/docs/userguides.rst index 57058ee0d7..f1267dc439 100644 --- a/docs/userguides.rst +++ b/docs/userguides.rst @@ -10,6 +10,7 @@ User Guides DeveloperPolicy FAQ Lexicon + Packaging * `The LLVM Getting Started Guide `_ @@ -67,7 +68,7 @@ User Guides Instructions for building the clang front-end from source. -* `Packaging guide `_ +* :ref:`packaging` Advice on packaging LLVM into a distribution. -- cgit v1.2.3