diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2015-05-23 15:55:08 +0200 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2015-05-23 15:57:18 +0200 |
| commit | c71979f416df409425391e1de35ec95528ed0f84 (patch) | |
| tree | a90215e0bdb0fcf62e74c58636c12b2ffd321680 /doc | |
| parent | 92492b23838f77decfc63810b56add0af6805feb (diff) | |
doc: Add "Running Guix Before It Is Installed".
* doc/guix.texi (Running Guix Before It Is Installed): New node.
(Packaging Guidelines): Refer to it.
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/guix.texi | 43 |
1 files changed, 42 insertions, 1 deletions
diff --git a/doc/guix.texi b/doc/guix.texi index 1d882afeca8..cfb626c7057 100644 --- a/doc/guix.texi +++ b/doc/guix.texi | |||
| @@ -88,6 +88,7 @@ Installation | |||
| 88 | * Running the Test Suite:: Testing Guix. | 88 | * Running the Test Suite:: Testing Guix. |
| 89 | * Setting Up the Daemon:: Preparing the build daemon's environment. | 89 | * Setting Up the Daemon:: Preparing the build daemon's environment. |
| 90 | * Invoking guix-daemon:: Running the build daemon. | 90 | * Invoking guix-daemon:: Running the build daemon. |
| 91 | * Running Guix Before It Is Installed:: Hacker tricks. | ||
| 91 | 92 | ||
| 92 | Setting Up the Daemon | 93 | Setting Up the Daemon |
| 93 | 94 | ||
| @@ -252,6 +253,7 @@ instead, you want to install the complete GNU operating system, | |||
| 252 | * Running the Test Suite:: Testing Guix. | 253 | * Running the Test Suite:: Testing Guix. |
| 253 | * Setting Up the Daemon:: Preparing the build daemon's environment. | 254 | * Setting Up the Daemon:: Preparing the build daemon's environment. |
| 254 | * Invoking guix-daemon:: Running the build daemon. | 255 | * Invoking guix-daemon:: Running the build daemon. |
| 256 | * Running Guix Before It Is Installed:: Hacker tricks. | ||
| 255 | @end menu | 257 | @end menu |
| 256 | 258 | ||
| 257 | @node Binary Installation | 259 | @node Binary Installation |
| @@ -830,6 +832,44 @@ useful in exceptional circumstances, such as if you need to run several | |||
| 830 | daemons on the same machine. | 832 | daemons on the same machine. |
| 831 | @end table | 833 | @end table |
| 832 | 834 | ||
| 835 | @node Running Guix Before It Is Installed | ||
| 836 | @section Running Guix Before It Is Installed | ||
| 837 | |||
| 838 | If you are hacking Guix itself---which is a good idea!---you will find | ||
| 839 | it useful to test the changes made in your local source tree checkout | ||
| 840 | without actually installing them. | ||
| 841 | |||
| 842 | To that end, all the command-line tools can be used even if you have not | ||
| 843 | run @command{make install}. To do that, prefix each command with | ||
| 844 | @command{./pre-inst-env} (the @file{pre-inst-env} script lives in the | ||
| 845 | top build tree of Guix), as in: | ||
| 846 | |||
| 847 | @example | ||
| 848 | $ sudo ./pre-inst-env guix-daemon --build-users-group=guixbuild | ||
| 849 | $ ./pre-inst-env guix build hello | ||
| 850 | @end example | ||
| 851 | |||
| 852 | @noindent | ||
| 853 | Similarly, for a Guile session using the Guix modules: | ||
| 854 | |||
| 855 | @example | ||
| 856 | $ ./pre-inst-env guile -c '(use-modules (guix utils)) (pk (%current-system))' | ||
| 857 | @end example | ||
| 858 | |||
| 859 | The @command{pre-inst-env} script sets up all the environment variables | ||
| 860 | necessary to support this, including @code{PATH} and | ||
| 861 | @code{GUILE_LOAD_PATH}. | ||
| 862 | |||
| 863 | If you are hacking Guix from Emacs using the wonderful Geiser | ||
| 864 | (@pxref{Introduction,,, geiser, Geiser User Manual}), make sure to | ||
| 865 | augment Guile's load path so that it finds source files from your | ||
| 866 | checkout: | ||
| 867 | |||
| 868 | @lisp | ||
| 869 | ;; Assuming the Guix checkout is in ~/src/guix. | ||
| 870 | (add-to-list 'geiser-guile-load-path "~/src/guix") | ||
| 871 | @end lisp | ||
| 872 | |||
| 833 | 873 | ||
| 834 | @c ********************************************************************* | 874 | @c ********************************************************************* |
| 835 | @node Package Management | 875 | @node Package Management |
| @@ -6215,7 +6255,8 @@ creating packages. For more information on package definitions, | |||
| 6215 | Once a package definition is in place, stored in a file in the Guix | 6255 | Once a package definition is in place, stored in a file in the Guix |
| 6216 | source tree, it can be tested using the @command{guix build} command | 6256 | source tree, it can be tested using the @command{guix build} command |
| 6217 | (@pxref{Invoking guix build}). For example, assuming the new package is | 6257 | (@pxref{Invoking guix build}). For example, assuming the new package is |
| 6218 | called @code{gnew}, you may run this command from the Guix build tree: | 6258 | called @code{gnew}, you may run this command from the Guix build tree |
| 6259 | (@pxref{Running Guix Before It Is Installed}): | ||
| 6219 | 6260 | ||
| 6220 | @example | 6261 | @example |
| 6221 | ./pre-inst-env guix build gnew --keep-failed | 6262 | ./pre-inst-env guix build gnew --keep-failed |
