diff options
-rw-r--r-- | guide/building.html | 6 | ||||
-rw-r--r-- | guide/ct.html | 3 | ||||
-rw-r--r-- | guide/deps.html | 13 | ||||
-rw-r--r-- | guide/edoc.html | 6 | ||||
-rw-r--r-- | guide/eunit.html | 2 | ||||
-rw-r--r-- | guide/index.html | 2 | ||||
-rw-r--r-- | guide/installation.html | 8 | ||||
-rw-r--r-- | guide/relx.html | 4 |
8 files changed, 33 insertions, 11 deletions
diff --git a/guide/building.html b/guide/building.html index dcff3d0..4d47271 100644 --- a/guide/building.html +++ b/guide/building.html @@ -42,7 +42,11 @@ Erlang.mk also automatically downloads and compiles the dependencies for your project.</p><p>All this is possible thanks to a combination of configuration and conventions. Most of the conventions come from Erlang/OTP itself so any seasoned Erlang developers should feel right at -home.</p></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_what_to_build"></a>6.2. What to build</h2></div></div></div><p>Erlang.mk gives you control over three steps of the build +home.</p><p>Erlang.mk supports multi-threaded building. Parallel execution +is supported for all targets. To execute Erlang.mk in parallel +the <code class="literal">-j</code> option must be used:</p><pre class="programlisting">$ make -j8</pre><p>The <code class="literal">MAKEFLAGS</code> variable can be used to enable parallel +building permanently on your system. It can be set in +your <code class="literal">.zshrc</code>, <code class="literal">.bashrc</code> or equivalent file.</p><pre class="programlisting">MAKEFLAGS="-j8"</pre></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_what_to_build"></a>6.2. What to build</h2></div></div></div><p>Erlang.mk gives you control over three steps of the build process, allowing you to do a partial build if needed.</p><p>A build has three phases: first any dependency is fetched and built, then the project itself is built and finally a release may be generated when applicable. A release is only diff --git a/guide/ct.html b/guide/ct.html index 3c09784..141c668 100644 --- a/guide/ct.html +++ b/guide/ct.html @@ -56,7 +56,8 @@ using the variable <code class="literal">t</code>. Note that this only applies t suite-specific targets, like the <code class="literal">ct-http</code> example above.</p><p>To run all tests from the <code class="literal">http_compress</code> group in the <code class="literal">http_SUITE</code> test suite, write:</p><pre class="programlisting">$ make ct-http t=http_compress</pre><p>Similarly, to run a specific test case in that group:</p><pre class="programlisting">$ make ct-http t=http_compress:headers_dupe</pre><p>To do the same against a multi-application repository, you can use the <code class="literal">-C</code> option:</p><pre class="programlisting">$ make -C apps/my_app ct-http t=my_group:my_case</pre><p>Note that this also applies to dependencies. When using Cowboy -as a dependency, you can run the following directly:</p><pre class="programlisting">$ make -C deps/cowboy ct-http t=http_compress</pre><p>Finally, <a class="link" href="coverage.html" title="Chapter 21. Code coverage">code coverage</a> is available, +as a dependency, you can run the following directly:</p><pre class="programlisting">$ make -C deps/cowboy ct-http t=http_compress</pre><p>The variable <code class="literal">c</code> can be used to run a specific test when +the test suite does not group test cases:</p><pre class="programlisting">$ make ct-http c=headers_dupe</pre><p>Finally, <a class="link" href="coverage.html" title="Chapter 21. Code coverage">code coverage</a> is available, but covered in its own chapter.</p></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="eunit.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="tests.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="triq.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div> </main> </body> diff --git a/guide/deps.html b/guide/deps.html index 6930352..0fc548b 100644 --- a/guide/deps.html +++ b/guide/deps.html @@ -85,7 +85,7 @@ can define the <code class="literal">dep_$(DEP_NAME)</code> variable with everyt dep_cowboy = git https://github.com/essen/cowboy 2.0.0-pre.2</pre><p>This will fetch Cowboy from your fork at the given commit.</p></div><div class="section"><div class="titlepage"><div><div><h3 class="title"><a id="_fetch_methods"></a>7.2.2. Fetch methods</h3></div></div></div><p>Erlang.mk comes with a number of different fetch methods. You can fetch from Git, Mercurial, SVN, to name a few. There are fetch methods that will work everywhere, and -fetch methods that will only work in a given environment.</p><p>The following table lists all existing methods:</p><div class="informaltable"><table class="informaltable" cellpadding="4px" style="border-collapse: collapse;border-top: 3px solid #527bbd; border-bottom: 3px solid #527bbd; border-left: 3px solid #527bbd; border-right: 3px solid #527bbd; "><colgroup><col class="col_1" /><col class="col_2" /><col class="col_3" /></colgroup><thead><tr><th style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"> Name </th><th style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"> Format </th><th style="border-bottom: 1px solid #527bbd; " align="center" valign="top"> Description</th></tr></thead><tbody><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>git</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>git repo commit</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Clone the Git repository and checkout the given version</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>git-submodule</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>git-submodule</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Initialize and update the Git submodule</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>hg</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>hg repo commit</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Clone the Mercurial repository and update to the given version</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>svn</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>svn repo</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Checkout the given SVN repository</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>cp</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>cp path/to/repo</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Recursively copy a local directory</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>ln</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>ln path/to/repo</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Symbolically link a local directory</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>hex</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>hex version</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Download the given project version from hex.pm</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>fail</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>N/A</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Always fail, reserved for internal use</p></td></tr><tr><td style="border-right: 1px solid #527bbd; " align="left" valign="top"><p>legacy</p></td><td style="border-right: 1px solid #527bbd; " align="center" valign="top"><p>N/A</p></td><td style="" align="center" valign="top"><p>Legacy Erlang.mk fetcher, reserved for internal use</p></td></tr></tbody></table></div><p>The <code class="literal">git</code> and <code class="literal">hg</code> methods both have a repository and commit. +fetch methods that will only work in a given environment.</p><p>The following table lists all existing methods:</p><div class="informaltable"><table class="informaltable" cellpadding="4px" style="border-collapse: collapse;border-top: 3px solid #527bbd; border-bottom: 3px solid #527bbd; border-left: 3px solid #527bbd; border-right: 3px solid #527bbd; "><colgroup><col class="col_1" /><col class="col_2" /><col class="col_3" /></colgroup><thead><tr><th style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"> Name </th><th style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"> Format </th><th style="border-bottom: 1px solid #527bbd; " align="center" valign="top"> Description</th></tr></thead><tbody><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>git</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>git repo commit</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Clone the Git repository and checkout the given version</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>git-subfolder</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>git repo commit subfolder</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Clone the Git repository, checkout the given version and use one of its subfolders as a dependency</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>git-submodule</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>git-submodule</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Initialize and update the Git submodule</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>hg</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>hg repo commit</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Clone the Mercurial repository and update to the given version</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>svn</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>svn repo</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Checkout the given SVN repository</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>cp</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>cp path/to/repo</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Recursively copy a local directory</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>ln</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>ln path/to/repo</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Symbolically link a local directory</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>hex</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>hex version</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Download the given project version from hex.pm</p></td></tr><tr><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="left" valign="top"><p>fail</p></td><td style="border-right: 1px solid #527bbd; border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>N/A</p></td><td style="border-bottom: 1px solid #527bbd; " align="center" valign="top"><p>Always fail, reserved for internal use</p></td></tr><tr><td style="border-right: 1px solid #527bbd; " align="left" valign="top"><p>legacy</p></td><td style="border-right: 1px solid #527bbd; " align="center" valign="top"><p>N/A</p></td><td style="" align="center" valign="top"><p>Legacy Erlang.mk fetcher, reserved for internal use</p></td></tr></tbody></table></div><p>The <code class="literal">git</code> and <code class="literal">hg</code> methods both have a repository and commit. You can use any valid commit, tag or branch in that repository for the commit value.</p><p>For example, to fetch Cowboy with tag 2.0.0-pre.2 from Git:</p><pre class="programlisting">dep_cowboy = git https://github.com/ninenines/cowboy 2.0.0-pre.2</pre><p>Or to fetch Ehsa tag 4.0.3 from Mercurial:</p><pre class="programlisting">dep_ehsa = hg https://bitbucket.org/a12n/ehsa 4.0.3</pre><p>Git also comes with a concept of submodules. Erlang.mk can automatically initializes and updates submodules for dependencies, @@ -266,7 +266,16 @@ empty Makefile generated, for compatibility purposes. Other projects with no Makefile are left untouched. </li></ul></div><p>You can disable the replacing of the <span class="emphasis"><em>erlang.mk</em></span> file by defining the <code class="literal">NO_AUTOPATCH_ERLANG_MK</code> variable:</p><pre class="programlisting">NO_AUTOPATCH_ERLANG_MK = 1</pre><p>You can also disable autopatch entirely for a few select -projects using the <code class="literal">NO_AUTOPATCH</code> variable:</p><pre class="programlisting">NO_AUTOPATCH = cowboy ranch cowlib</pre></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_skipping_deps"></a>7.10. Skipping deps</h2></div></div></div><p>It is possible to temporarily skip all dependency operations. +projects using the <code class="literal">NO_AUTOPATCH</code> variable:</p><pre class="programlisting">NO_AUTOPATCH = cowboy ranch cowlib</pre></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_dealing_with_duplicate_modules"></a>7.10. Dealing with duplicate modules</h2></div></div></div><p>When there are duplicate modules found in both applications +and their dependencies, some tasks may fail. Erlang expects +modules to be unique in general.</p><p>When the duplicates are found in dependencies, you will need +to remove one of the duplicates at fetch time. To do so, you +can add a rule similar to this to your Makefile before including +<span class="emphasis"><em>erlang.mk</em></span>:</p><pre class="programlisting">DEPS_DIR = $(CURDIR)/deps + +deps:: $(DEPS_DIR)/cowlib + $(verbose) rm -f $(DEPS_DIR)/cowlib/src/cow_ws.erl</pre><p>This must be done from the application that has this dependency. +Only define the <code class="literal">DEPS_DIR</code> variable if necessary.</p></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_skipping_deps"></a>7.11. Skipping deps</h2></div></div></div><p>It is possible to temporarily skip all dependency operations. This is done by defining the <code class="literal">SKIP_DEPS</code> variable. Use cases include being somewhere with no connection to download them, or perhaps a peculiar setup.</p><p>A typical usage would be:</p><pre class="programlisting">$ make SKIP_DEPS=1</pre><p>When the variable is defined:</p><div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem"> diff --git a/guide/edoc.html b/guide/edoc.html index 3ad87eb..f13d5db 100644 --- a/guide/edoc.html +++ b/guide/edoc.html @@ -43,7 +43,11 @@ EDOC_OPTS = {doclet, edown_doclet}</pre></div><div class="section"><div class="t automatically if the <span class="emphasis"><em>doc/overview.edoc</em></span> file exists. If you do not want that file and still want to generate doc comments, two solutions are available.</p><p>You can generate EDoc documentation directly:</p><pre class="programlisting">$ make edoc</pre><p>You can enable automatic generation on <code class="literal">make docs</code> by adding -the following to your Makefile:</p><pre class="programlisting">docs:: edoc</pre></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="asciidoc.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="docs.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="sphinx.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div> +the following to your Makefile:</p><pre class="programlisting">docs:: edoc</pre></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_running_edoc_on_all_applications"></a>15.4. Running EDoc on all applications</h2></div></div></div><p>In a multi-application project you may want to run EDoc +against all applications at the same time, instead of +against each applications independently. To do so, you +need to configure the <code class="literal">EDOC_SRC_DIRS</code> at the end of +your Makefile, after including <span class="emphasis"><em>erlang.mk</em></span>:</p><pre class="programlisting">EDOC_SRC_DIRS = $(ALL_APPS_DIRS)</pre></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="asciidoc.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="docs.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="sphinx.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div> </main> </body> </html> diff --git a/guide/eunit.html b/guide/eunit.html index eedd8e7..8c054ec 100644 --- a/guide/eunit.html +++ b/guide/eunit.html @@ -63,7 +63,7 @@ EUnit options. Options are documented in the <a class="ulink" href="http://www.erlang.org/doc/man/eunit.html#test-2" target="_top">EUnit manual</a>. At the time of writing, the only available option is <code class="literal">verbose</code>:</p><pre class="programlisting">EUNIT_OPTS = verbose</pre><p>The <code class="literal">EUNIT_ERL_OPTS</code> variable allows you to specify options to be passed to <code class="literal">erl</code> when running EUnit tests. For example, -you can load the <span class="emphasis"><em>vm.args</em></span> and <span class="emphasis"><em>sys.config</em></span> files:</p><pre class="programlisting">EUNIT_ERL_OPTS = -args_file rel/vm.args -config rel/sys.config</pre></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_usage_4"></a>18.3. Usage</h2></div></div></div><p>To run all tests (including EUnit):</p><pre class="programlisting">$ make tests</pre><p>To run all tests and static checks (including EUnit):</p><pre class="programlisting">$ make check</pre><p>You can also run EUnit separately:</p><pre class="programlisting">$ make eunit</pre><p>EUnit will be quiet by default, only outputting errors. +you can load the <span class="emphasis"><em>vm.args</em></span> and <span class="emphasis"><em>sys.config</em></span> files:</p><pre class="programlisting">EUNIT_ERL_OPTS = -args_file config/vm.args -config config/sys.config</pre></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_usage_4"></a>18.3. Usage</h2></div></div></div><p>To run all tests (including EUnit):</p><pre class="programlisting">$ make tests</pre><p>To run all tests and static checks (including EUnit):</p><pre class="programlisting">$ make check</pre><p>You can also run EUnit separately:</p><pre class="programlisting">$ make eunit</pre><p>EUnit will be quiet by default, only outputting errors. You can easily make it verbose for a single invocation:</p><pre class="programlisting">$ make eunit EUNIT_OPTS=verbose</pre><p>Erlang.mk allows you to run all tests from a specific module, or a specific test case from that module, using the variable <code class="literal">t</code>.</p><p>For example, to run all tests from the <code class="literal">cow_http_hd</code> diff --git a/guide/index.html b/guide/index.html index a9c5ce7..ec5b1a6 100644 --- a/guide/index.html +++ b/guide/index.html @@ -33,7 +33,7 @@ div.navfooter{margin-bottom:1em} </header> <main> -<div class="navheader"><table width="100%" summary="Navigation header"><tr><td width="20%" align="left"> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="installation.html">Next</a></td></tr></table><hr /></div><div xml:lang="en" class="book" lang="en"><div class="titlepage"><div><div><h1 class="title"><a id="idm46132705570336"></a>Erlang.mk User Guide</h1></div><div><div class="author"><h3 class="author"><span class="firstname">Loïc</span> <span class="surname">Hoguin</span></h3><code class="email"><<a class="email" href="mailto:[email protected]">[email protected]</a>></code></div></div></div><hr /></div><div class="toc"><p><strong>Table of Contents</strong></p><dl class="toc"><dt><span class="chapter"><a href="installation.html">1. Installation</a></span></dt><dd><dl><dt><span class="section"><a href="installation.html#_on_unix">1.1. On Unix</a></span></dt><dt><span class="section"><a href="installation.html#_on_windows">1.2. On Windows</a></span></dt></dl></dd><dt><span class="chapter"><a href="getting_started.html">2. Getting started</a></span></dt><dd><dl><dt><span class="section"><a href="getting_started.html#_creating_a_folder_for_your_project">2.1. Creating a folder for your project</a></span></dt><dt><span class="section"><a href="getting_started.html#_downloading_erlang_mk">2.2. Downloading Erlang.mk</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_with_otp_applications">2.3. Getting started with OTP applications</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_with_otp_libraries">2.4. Getting started with OTP libraries</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_with_otp_releases">2.5. Getting started with OTP releases</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_from_scratch">2.6. Getting started from scratch</a></span></dt><dt><span class="section"><a href="getting_started.html#_using_spaces_instead_of_tabs">2.7. Using spaces instead of tabs</a></span></dt><dt><span class="section"><a href="getting_started.html#_using_templates">2.8. Using templates</a></span></dt><dt><span class="section"><a href="getting_started.html#_hiding_erlang_mk_from_git">2.9. Hiding Erlang.mk from git</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_help">2.10. Getting help</a></span></dt></dl></dd><dt><span class="chapter"><a href="overview.html">3. Overview</a></span></dt><dd><dl><dt><span class="section"><a href="overview.html#_building_your_project">3.1. Building your project</a></span></dt><dt><span class="section"><a href="overview.html#_exploring_the_package_index">3.2. Exploring the package index</a></span></dt><dt><span class="section"><a href="overview.html#_generating_documentation">3.3. Generating documentation</a></span></dt><dt><span class="section"><a href="overview.html#_running_tests">3.4. Running tests</a></span></dt><dt><span class="section"><a href="overview.html#_need_more">3.5. Need more?</a></span></dt></dl></dd><dt><span class="chapter"><a href="updating.html">4. Updating Erlang.mk</a></span></dt><dd><dl><dt><span class="section"><a href="updating.html#_initial_bootstrap">4.1. Initial bootstrap</a></span></dt><dt><span class="section"><a href="updating.html#_updating">4.2. Updating</a></span></dt><dt><span class="section"><a href="updating.html#_customizing_the_build">4.3. Customizing the build</a></span></dt></dl></dd><dt><span class="chapter"><a href="limitations.html">5. Limitations</a></span></dt><dd><dl><dt><span class="section"><a href="limitations.html#_erlang_must_be_available">5.1. Erlang must be available</a></span></dt><dt><span class="section"><a href="limitations.html#_spaces_in_path">5.2. Spaces in path</a></span></dt><dt><span class="section"><a href="limitations.html#_dependency_tracking_and_modification_times">5.3. Dependency tracking and modification times</a></span></dt></dl></dd><dt><span class="part"><a href="code.html">I. Code</a></span></dt><dd><dl><dt><span class="chapter"><a href="building.html">6. Building</a></span></dt><dd><dl><dt><span class="section"><a href="building.html#_how_to_build">6.1. How to build</a></span></dt><dt><span class="section"><a href="building.html#_what_to_build">6.2. What to build</a></span></dt><dt><span class="section"><a href="building.html#_application_resource_file">6.3. Application resource file</a></span></dt><dt><span class="section"><a href="building.html#_automatic_application_resource_file_values">6.4. Automatic application resource file values</a></span></dt><dt><span class="section"><a href="building.html#_file_formats">6.5. File formats</a></span></dt><dt><span class="section"><a href="building.html#_compilation_options">6.6. Compilation options</a></span></dt><dt><span class="section"><a href="building.html#_cold_and_hot_builds">6.7. Cold and hot builds</a></span></dt><dt><span class="section"><a href="building.html#_dependency_tracking">6.8. Dependency tracking</a></span></dt><dt><span class="section"><a href="building.html#_generating_erlang_source">6.9. Generating Erlang source</a></span></dt><dt><span class="section"><a href="building.html#_cleaning">6.10. Cleaning</a></span></dt></dl></dd><dt><span class="chapter"><a href="deps.html">7. Packages and dependencies</a></span></dt><dd><dl><dt><span class="section"><a href="deps.html#_searching_packages">7.1. Searching packages</a></span></dt><dt><span class="section"><a href="deps.html#_adding_dependencies_to_your_project">7.2. Adding dependencies to your project</a></span></dt><dt><span class="section"><a href="deps.html#_how_deps_are_fetched_and_built">7.3. How deps are fetched and built</a></span></dt><dt><span class="section"><a href="deps.html#_fetching_and_listing_dependencies_only">7.4. Fetching and listing dependencies only</a></span></dt><dt><span class="section"><a href="deps.html#_ignoring_unwanted_dependencies">7.5. Ignoring unwanted dependencies</a></span></dt><dt><span class="section"><a href="deps.html#_dependencies_directory">7.6. Dependencies directory</a></span></dt><dt><span class="section"><a href="deps.html#_many_applications_in_one_repository">7.7. Many applications in one repository</a></span></dt><dt><span class="section"><a href="deps.html#_repositories_with_no_application_at_the_root_level">7.8. Repositories with no application at the root level</a></span></dt><dt><span class="section"><a href="deps.html#_autopatch">7.9. Autopatch</a></span></dt><dt><span class="section"><a href="deps.html#_skipping_deps">7.10. Skipping deps</a></span></dt></dl></dd><dt><span class="chapter"><a href="ports.html">8. NIFs and port drivers</a></span></dt><dd><dl><dt><span class="section"><a href="ports.html#_c_source_code_location_and_erlang_environment">8.1. C source code location and Erlang environment</a></span></dt><dt><span class="section"><a href="ports.html#_using_a_custom_makefile">8.2. Using a custom Makefile</a></span></dt><dt><span class="section"><a href="ports.html#_using_erlang_mk_directly">8.3. Using Erlang.mk directly</a></span></dt><dt><span class="section"><a href="ports.html#_propagating_compile_and_linker_flags_to_sub_makefiles">8.4. Propagating compile and linker flags to sub-Makefiles</a></span></dt></dl></dd><dt><span class="chapter"><a href="relx.html">9. Releases</a></span></dt><dd><dl><dt><span class="section"><a href="relx.html#_setup">9.1. Setup</a></span></dt><dt><span class="section"><a href="relx.html#_configuration">9.2. Configuration</a></span></dt><dt><span class="section"><a href="relx.html#_generating_the_release">9.3. Generating the release</a></span></dt><dt><span class="section"><a href="relx.html#_running_the_release">9.4. Running the release</a></span></dt><dt><span class="section"><a href="relx.html#_upgrading_a_release">9.5. Upgrading a release</a></span></dt><dt><span class="section"><a href="relx.html#_getting_relx_semver_value">9.6. Getting Relx semver value</a></span></dt></dl></dd><dt><span class="chapter"><a href="sfx.html">10. Self-extracting releases</a></span></dt><dd><dl><dt><span class="section"><a href="sfx.html#_generating_the_self_extracting_archive">10.1. Generating the self-extracting archive</a></span></dt><dt><span class="section"><a href="sfx.html#_running_the_release_2">10.2. Running the release</a></span></dt></dl></dd><dt><span class="chapter"><a href="escript.html">11. Escripts</a></span></dt><dd><dl><dt><span class="section"><a href="escript.html#_requirements">11.1. Requirements</a></span></dt><dt><span class="section"><a href="escript.html#_generating_an_escript">11.2. Generating an escript</a></span></dt><dt><span class="section"><a href="escript.html#_configuration_2">11.3. Configuration</a></span></dt><dt><span class="section"><a href="escript.html#_extra_files">11.4. Extra files</a></span></dt><dt><span class="section"><a href="escript.html#_optimizing_for_size">11.5. Optimizing for size</a></span></dt></dl></dd><dt><span class="chapter"><a href="kerl.html">12. OTP version management</a></span></dt><dd><dl><dt><span class="section"><a href="kerl.html#_erlang_versions">12.1. Erlang versions</a></span></dt><dt><span class="section"><a href="kerl.html#otp_version_pinning">12.2. OTP version pinning</a></span></dt><dt><span class="section"><a href="kerl.html#_continuous_integration">12.3. Continuous integration</a></span></dt><dt><span class="section"><a href="kerl.html#_configuring_kerl">12.4. Configuring Kerl</a></span></dt></dl></dd><dt><span class="chapter"><a href="compat.html">13. Compatibility with other build tools</a></span></dt><dd><dl><dt><span class="section"><a href="compat.html#_rebar_projects_as_erlang_mk_dependencies">13.1. Rebar projects as Erlang.mk dependencies</a></span></dt><dt><span class="section"><a href="compat.html#_erlang_mk_projects_as_rebar_dependencies">13.2. Erlang.mk projects as Rebar dependencies</a></span></dt></dl></dd></dl></dd><dt><span class="part"><a href="docs.html">II. Documentation</a></span></dt><dd><dl><dt><span class="chapter"><a href="asciidoc.html">14. AsciiDoc documentation</a></span></dt><dd><dl><dt><span class="section"><a href="asciidoc.html#_requirements_2">14.1. Requirements</a></span></dt><dt><span class="section"><a href="asciidoc.html#_writing_asciidoc_documentation">14.2. Writing AsciiDoc documentation</a></span></dt><dt><span class="section"><a href="asciidoc.html#_configuration_3">14.3. Configuration</a></span></dt><dt><span class="section"><a href="asciidoc.html#_usage">14.4. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="edoc.html">15. EDoc comments</a></span></dt><dd><dl><dt><span class="section"><a href="edoc.html#_writing_edoc_comments">15.1. Writing EDoc comments</a></span></dt><dt><span class="section"><a href="edoc.html#_configuration_4">15.2. Configuration</a></span></dt><dt><span class="section"><a href="edoc.html#_usage_2">15.3. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="sphinx.html">16. Sphinx documentation</a></span></dt><dd><dl><dt><span class="section"><a href="sphinx.html#_writing_sphinx_documentation">16.1. Writing Sphinx documentation</a></span></dt><dt><span class="section"><a href="sphinx.html#_basic_setup">16.2. Basic setup</a></span></dt><dt><span class="section"><a href="sphinx.html#_erlang_mk_configuration">16.3. Erlang.mk configuration</a></span></dt><dt><span class="section"><a href="sphinx.html#_generating_man_pages">16.4. Generating man pages</a></span></dt></dl></dd></dl></dd><dt><span class="part"><a href="tests.html">III. Tests</a></span></dt><dd><dl><dt><span class="chapter"><a href="shell.html">17. Erlang shell</a></span></dt><dd><dl><dt><span class="section"><a href="shell.html#_configuration_5">17.1. Configuration</a></span></dt><dt><span class="section"><a href="shell.html#_usage_3">17.2. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="eunit.html">18. EUnit</a></span></dt><dd><dl><dt><span class="section"><a href="eunit.html#_writing_tests">18.1. Writing tests</a></span></dt><dt><span class="section"><a href="eunit.html#_configuration_6">18.2. Configuration</a></span></dt><dt><span class="section"><a href="eunit.html#_usage_4">18.3. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="ct.html">19. Common Test</a></span></dt><dd><dl><dt><span class="section"><a href="ct.html#_writing_tests_2">19.1. Writing tests</a></span></dt><dt><span class="section"><a href="ct.html#_configuration_7">19.2. Configuration</a></span></dt><dt><span class="section"><a href="ct.html#_usage_5">19.3. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="triq.html">20. Triq</a></span></dt><dt><span class="chapter"><a href="coverage.html">21. Code coverage</a></span></dt><dt><span class="chapter"><a href="ci.html">22. Continuous integration</a></span></dt><dd><dl><dt><span class="section"><a href="ci.html#_configuring_erlang_otp_versions_to_test">22.1. Configuring Erlang/OTP versions to test</a></span></dt><dt><span class="section"><a href="ci.html#_running_tests_across_all_configured_versions">22.2. Running tests across all configured versions</a></span></dt><dt><span class="section"><a href="ci.html#_extending_the_ci_targets">22.3. Extending the CI targets</a></span></dt></dl></dd><dt><span class="chapter"><a href="dialyzer.html">23. Dialyzer</a></span></dt><dd><dl><dt><span class="section"><a href="dialyzer.html#_how_it_works">23.1. How it works</a></span></dt><dt><span class="section"><a href="dialyzer.html#_configuration_8">23.2. Configuration</a></span></dt><dt><span class="section"><a href="dialyzer.html#_usage_6">23.3. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="xref.html">24. Xref</a></span></dt></dl></dd><dt><span class="part"><a href="plugins.html">IV. Third-party plugins</a></span></dt><dd><dl><dt><span class="chapter"><a href="plugins_usage.html">25. External plugins</a></span></dt><dd><dl><dt><span class="section"><a href="plugins_usage.html#_loading_all_plugins_from_a_dependency">25.1. Loading all plugins from a dependency</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_loading_one_plugin_from_a_dependency">25.2. Loading one plugin from a dependency</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_writing_external_plugins">25.3. Writing external plugins</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_early_stage_plugins">25.4. Early-stage plugins</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_loading_plugins_local_to_the_application">25.5. Loading plugins local to the application</a></span></dt></dl></dd><dt><span class="chapter"><a href="plugins_list.html">26. List of plugins</a></span></dt><dd><dl><dt><span class="section"><a href="plugins_list.html#_efene_mk">26.1. efene.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_elixir_mk">26.2. elixir.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_elvis_mk">26.3. elvis.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_geas">26.4. geas</a></span></dt><dt><span class="section"><a href="plugins_list.html#_hexer_mk">26.5. hexer.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_hexpm_mk">26.6. hexpm.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_jorel">26.7. jorel</a></span></dt><dt><span class="section"><a href="plugins_list.html#_lfe_mk">26.8. lfe.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_mix_mk">26.9. mix.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_reload_mk">26.10. reload.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_rust_mk">26.11. rust.mk</a></span></dt></dl></dd></dl></dd><dt><span class="part"><a href="about.html">V. About Erlang.mk</a></span></dt><dd><dl><dt><span class="chapter"><a href="why.html">27. Why Erlang.mk</a></span></dt><dd><dl><dt><span class="section"><a href="why.html#_erlang_mk_is_fast">27.1. Erlang.mk is fast</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_gives_you_the_full_power_of_unix">27.2. Erlang.mk gives you the full power of Unix</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_is_a_text_file">27.3. Erlang.mk is a text file</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_can_manage_erlang_itself">27.4. Erlang.mk can manage Erlang itself</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_can_do_more_than_erlang">27.5. Erlang.mk can do more than Erlang</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_integrates_nicely_in_make_and_automake_projects">27.6. Erlang.mk integrates nicely in Make and Automake projects</a></span></dt></dl></dd><dt><span class="chapter"><a href="history.html">28. Short history</a></span></dt><dd><dl><dt><span class="section"><a href="history.html#_before_erlang_mk">28.1. Before Erlang.mk</a></span></dt><dt><span class="section"><a href="history.html#_lifetime_of_the_project">28.2. Lifetime of the project</a></span></dt></dl></dd><dt><span class="chapter"><a href="contributing.html">29. Contributing</a></span></dt><dd><dl><dt><span class="section"><a href="contributing.html#_priorities">29.1. Priorities</a></span></dt><dt><span class="section"><a href="contributing.html#_bugs">29.2. Bugs</a></span></dt><dt><span class="section"><a href="contributing.html#_code">29.3. Code</a></span></dt><dt><span class="section"><a href="contributing.html#_packages">29.4. Packages</a></span></dt><dt><span class="section"><a href="contributing.html#_documentation">29.5. Documentation</a></span></dt><dt><span class="section"><a href="contributing.html#_feature_requests">29.6. Feature requests</a></span></dt></dl></dd></dl></dd></dl></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="installation.html">Next</a></td></tr></table></div> +<div class="navheader"><table width="100%" summary="Navigation header"><tr><td width="20%" align="left"> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="installation.html">Next</a></td></tr></table><hr /></div><div xml:lang="en" class="book" lang="en"><div class="titlepage"><div><div><h1 class="title"><a id="idm46197684974672"></a>Erlang.mk User Guide</h1></div><div><div class="author"><h3 class="author"><span class="firstname">Loïc</span> <span class="surname">Hoguin</span></h3><code class="email"><<a class="email" href="mailto:[email protected]">[email protected]</a>></code></div></div></div><hr /></div><div class="toc"><p><strong>Table of Contents</strong></p><dl class="toc"><dt><span class="chapter"><a href="installation.html">1. Installation</a></span></dt><dd><dl><dt><span class="section"><a href="installation.html#_on_unix">1.1. On Unix</a></span></dt><dt><span class="section"><a href="installation.html#_on_windows">1.2. On Windows</a></span></dt></dl></dd><dt><span class="chapter"><a href="getting_started.html">2. Getting started</a></span></dt><dd><dl><dt><span class="section"><a href="getting_started.html#_creating_a_folder_for_your_project">2.1. Creating a folder for your project</a></span></dt><dt><span class="section"><a href="getting_started.html#_downloading_erlang_mk">2.2. Downloading Erlang.mk</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_with_otp_applications">2.3. Getting started with OTP applications</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_with_otp_libraries">2.4. Getting started with OTP libraries</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_with_otp_releases">2.5. Getting started with OTP releases</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_started_from_scratch">2.6. Getting started from scratch</a></span></dt><dt><span class="section"><a href="getting_started.html#_using_spaces_instead_of_tabs">2.7. Using spaces instead of tabs</a></span></dt><dt><span class="section"><a href="getting_started.html#_using_templates">2.8. Using templates</a></span></dt><dt><span class="section"><a href="getting_started.html#_hiding_erlang_mk_from_git">2.9. Hiding Erlang.mk from git</a></span></dt><dt><span class="section"><a href="getting_started.html#_getting_help">2.10. Getting help</a></span></dt></dl></dd><dt><span class="chapter"><a href="overview.html">3. Overview</a></span></dt><dd><dl><dt><span class="section"><a href="overview.html#_building_your_project">3.1. Building your project</a></span></dt><dt><span class="section"><a href="overview.html#_exploring_the_package_index">3.2. Exploring the package index</a></span></dt><dt><span class="section"><a href="overview.html#_generating_documentation">3.3. Generating documentation</a></span></dt><dt><span class="section"><a href="overview.html#_running_tests">3.4. Running tests</a></span></dt><dt><span class="section"><a href="overview.html#_need_more">3.5. Need more?</a></span></dt></dl></dd><dt><span class="chapter"><a href="updating.html">4. Updating Erlang.mk</a></span></dt><dd><dl><dt><span class="section"><a href="updating.html#_initial_bootstrap">4.1. Initial bootstrap</a></span></dt><dt><span class="section"><a href="updating.html#_updating">4.2. Updating</a></span></dt><dt><span class="section"><a href="updating.html#_customizing_the_build">4.3. Customizing the build</a></span></dt></dl></dd><dt><span class="chapter"><a href="limitations.html">5. Limitations</a></span></dt><dd><dl><dt><span class="section"><a href="limitations.html#_erlang_must_be_available">5.1. Erlang must be available</a></span></dt><dt><span class="section"><a href="limitations.html#_spaces_in_path">5.2. Spaces in path</a></span></dt><dt><span class="section"><a href="limitations.html#_dependency_tracking_and_modification_times">5.3. Dependency tracking and modification times</a></span></dt></dl></dd><dt><span class="part"><a href="code.html">I. Code</a></span></dt><dd><dl><dt><span class="chapter"><a href="building.html">6. Building</a></span></dt><dd><dl><dt><span class="section"><a href="building.html#_how_to_build">6.1. How to build</a></span></dt><dt><span class="section"><a href="building.html#_what_to_build">6.2. What to build</a></span></dt><dt><span class="section"><a href="building.html#_application_resource_file">6.3. Application resource file</a></span></dt><dt><span class="section"><a href="building.html#_automatic_application_resource_file_values">6.4. Automatic application resource file values</a></span></dt><dt><span class="section"><a href="building.html#_file_formats">6.5. File formats</a></span></dt><dt><span class="section"><a href="building.html#_compilation_options">6.6. Compilation options</a></span></dt><dt><span class="section"><a href="building.html#_cold_and_hot_builds">6.7. Cold and hot builds</a></span></dt><dt><span class="section"><a href="building.html#_dependency_tracking">6.8. Dependency tracking</a></span></dt><dt><span class="section"><a href="building.html#_generating_erlang_source">6.9. Generating Erlang source</a></span></dt><dt><span class="section"><a href="building.html#_cleaning">6.10. Cleaning</a></span></dt></dl></dd><dt><span class="chapter"><a href="deps.html">7. Packages and dependencies</a></span></dt><dd><dl><dt><span class="section"><a href="deps.html#_searching_packages">7.1. Searching packages</a></span></dt><dt><span class="section"><a href="deps.html#_adding_dependencies_to_your_project">7.2. Adding dependencies to your project</a></span></dt><dt><span class="section"><a href="deps.html#_how_deps_are_fetched_and_built">7.3. How deps are fetched and built</a></span></dt><dt><span class="section"><a href="deps.html#_fetching_and_listing_dependencies_only">7.4. Fetching and listing dependencies only</a></span></dt><dt><span class="section"><a href="deps.html#_ignoring_unwanted_dependencies">7.5. Ignoring unwanted dependencies</a></span></dt><dt><span class="section"><a href="deps.html#_dependencies_directory">7.6. Dependencies directory</a></span></dt><dt><span class="section"><a href="deps.html#_many_applications_in_one_repository">7.7. Many applications in one repository</a></span></dt><dt><span class="section"><a href="deps.html#_repositories_with_no_application_at_the_root_level">7.8. Repositories with no application at the root level</a></span></dt><dt><span class="section"><a href="deps.html#_autopatch">7.9. Autopatch</a></span></dt><dt><span class="section"><a href="deps.html#_dealing_with_duplicate_modules">7.10. Dealing with duplicate modules</a></span></dt><dt><span class="section"><a href="deps.html#_skipping_deps">7.11. Skipping deps</a></span></dt></dl></dd><dt><span class="chapter"><a href="ports.html">8. NIFs and port drivers</a></span></dt><dd><dl><dt><span class="section"><a href="ports.html#_c_source_code_location_and_erlang_environment">8.1. C source code location and Erlang environment</a></span></dt><dt><span class="section"><a href="ports.html#_using_a_custom_makefile">8.2. Using a custom Makefile</a></span></dt><dt><span class="section"><a href="ports.html#_using_erlang_mk_directly">8.3. Using Erlang.mk directly</a></span></dt><dt><span class="section"><a href="ports.html#_propagating_compile_and_linker_flags_to_sub_makefiles">8.4. Propagating compile and linker flags to sub-Makefiles</a></span></dt></dl></dd><dt><span class="chapter"><a href="relx.html">9. Releases</a></span></dt><dd><dl><dt><span class="section"><a href="relx.html#_setup">9.1. Setup</a></span></dt><dt><span class="section"><a href="relx.html#_configuration">9.2. Configuration</a></span></dt><dt><span class="section"><a href="relx.html#_generating_the_release">9.3. Generating the release</a></span></dt><dt><span class="section"><a href="relx.html#_running_the_release">9.4. Running the release</a></span></dt><dt><span class="section"><a href="relx.html#_upgrading_a_release">9.5. Upgrading a release</a></span></dt><dt><span class="section"><a href="relx.html#_getting_relx_semver_value">9.6. Getting Relx semver value</a></span></dt></dl></dd><dt><span class="chapter"><a href="sfx.html">10. Self-extracting releases</a></span></dt><dd><dl><dt><span class="section"><a href="sfx.html#_generating_the_self_extracting_archive">10.1. Generating the self-extracting archive</a></span></dt><dt><span class="section"><a href="sfx.html#_running_the_release_2">10.2. Running the release</a></span></dt></dl></dd><dt><span class="chapter"><a href="escript.html">11. Escripts</a></span></dt><dd><dl><dt><span class="section"><a href="escript.html#_requirements">11.1. Requirements</a></span></dt><dt><span class="section"><a href="escript.html#_generating_an_escript">11.2. Generating an escript</a></span></dt><dt><span class="section"><a href="escript.html#_configuration_2">11.3. Configuration</a></span></dt><dt><span class="section"><a href="escript.html#_extra_files">11.4. Extra files</a></span></dt><dt><span class="section"><a href="escript.html#_optimizing_for_size">11.5. Optimizing for size</a></span></dt></dl></dd><dt><span class="chapter"><a href="kerl.html">12. OTP version management</a></span></dt><dd><dl><dt><span class="section"><a href="kerl.html#_erlang_versions">12.1. Erlang versions</a></span></dt><dt><span class="section"><a href="kerl.html#otp_version_pinning">12.2. OTP version pinning</a></span></dt><dt><span class="section"><a href="kerl.html#_continuous_integration">12.3. Continuous integration</a></span></dt><dt><span class="section"><a href="kerl.html#_configuring_kerl">12.4. Configuring Kerl</a></span></dt></dl></dd><dt><span class="chapter"><a href="compat.html">13. Compatibility with other build tools</a></span></dt><dd><dl><dt><span class="section"><a href="compat.html#_rebar_projects_as_erlang_mk_dependencies">13.1. Rebar projects as Erlang.mk dependencies</a></span></dt><dt><span class="section"><a href="compat.html#_erlang_mk_projects_as_rebar_dependencies">13.2. Erlang.mk projects as Rebar dependencies</a></span></dt></dl></dd></dl></dd><dt><span class="part"><a href="docs.html">II. Documentation</a></span></dt><dd><dl><dt><span class="chapter"><a href="asciidoc.html">14. AsciiDoc documentation</a></span></dt><dd><dl><dt><span class="section"><a href="asciidoc.html#_requirements_2">14.1. Requirements</a></span></dt><dt><span class="section"><a href="asciidoc.html#_writing_asciidoc_documentation">14.2. Writing AsciiDoc documentation</a></span></dt><dt><span class="section"><a href="asciidoc.html#_configuration_3">14.3. Configuration</a></span></dt><dt><span class="section"><a href="asciidoc.html#_usage">14.4. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="edoc.html">15. EDoc comments</a></span></dt><dd><dl><dt><span class="section"><a href="edoc.html#_writing_edoc_comments">15.1. Writing EDoc comments</a></span></dt><dt><span class="section"><a href="edoc.html#_configuration_4">15.2. Configuration</a></span></dt><dt><span class="section"><a href="edoc.html#_usage_2">15.3. Usage</a></span></dt><dt><span class="section"><a href="edoc.html#_running_edoc_on_all_applications">15.4. Running EDoc on all applications</a></span></dt></dl></dd><dt><span class="chapter"><a href="sphinx.html">16. Sphinx documentation</a></span></dt><dd><dl><dt><span class="section"><a href="sphinx.html#_writing_sphinx_documentation">16.1. Writing Sphinx documentation</a></span></dt><dt><span class="section"><a href="sphinx.html#_basic_setup">16.2. Basic setup</a></span></dt><dt><span class="section"><a href="sphinx.html#_erlang_mk_configuration">16.3. Erlang.mk configuration</a></span></dt><dt><span class="section"><a href="sphinx.html#_generating_man_pages">16.4. Generating man pages</a></span></dt></dl></dd></dl></dd><dt><span class="part"><a href="tests.html">III. Tests</a></span></dt><dd><dl><dt><span class="chapter"><a href="shell.html">17. Erlang shell</a></span></dt><dd><dl><dt><span class="section"><a href="shell.html#_configuration_5">17.1. Configuration</a></span></dt><dt><span class="section"><a href="shell.html#_usage_3">17.2. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="eunit.html">18. EUnit</a></span></dt><dd><dl><dt><span class="section"><a href="eunit.html#_writing_tests">18.1. Writing tests</a></span></dt><dt><span class="section"><a href="eunit.html#_configuration_6">18.2. Configuration</a></span></dt><dt><span class="section"><a href="eunit.html#_usage_4">18.3. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="ct.html">19. Common Test</a></span></dt><dd><dl><dt><span class="section"><a href="ct.html#_writing_tests_2">19.1. Writing tests</a></span></dt><dt><span class="section"><a href="ct.html#_configuration_7">19.2. Configuration</a></span></dt><dt><span class="section"><a href="ct.html#_usage_5">19.3. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="triq.html">20. Triq</a></span></dt><dt><span class="chapter"><a href="coverage.html">21. Code coverage</a></span></dt><dt><span class="chapter"><a href="ci.html">22. Continuous integration</a></span></dt><dd><dl><dt><span class="section"><a href="ci.html#_configuring_erlang_otp_versions_to_test">22.1. Configuring Erlang/OTP versions to test</a></span></dt><dt><span class="section"><a href="ci.html#_running_tests_across_all_configured_versions">22.2. Running tests across all configured versions</a></span></dt><dt><span class="section"><a href="ci.html#_extending_the_ci_targets">22.3. Extending the CI targets</a></span></dt></dl></dd><dt><span class="chapter"><a href="dialyzer.html">23. Dialyzer</a></span></dt><dd><dl><dt><span class="section"><a href="dialyzer.html#_how_it_works">23.1. How it works</a></span></dt><dt><span class="section"><a href="dialyzer.html#_configuration_8">23.2. Configuration</a></span></dt><dt><span class="section"><a href="dialyzer.html#_usage_6">23.3. Usage</a></span></dt></dl></dd><dt><span class="chapter"><a href="xref.html">24. Xref</a></span></dt></dl></dd><dt><span class="part"><a href="plugins.html">IV. Third-party plugins</a></span></dt><dd><dl><dt><span class="chapter"><a href="plugins_usage.html">25. External plugins</a></span></dt><dd><dl><dt><span class="section"><a href="plugins_usage.html#_loading_all_plugins_from_a_dependency">25.1. Loading all plugins from a dependency</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_loading_one_plugin_from_a_dependency">25.2. Loading one plugin from a dependency</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_writing_external_plugins">25.3. Writing external plugins</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_early_stage_plugins">25.4. Early-stage plugins</a></span></dt><dt><span class="section"><a href="plugins_usage.html#_loading_plugins_local_to_the_application">25.5. Loading plugins local to the application</a></span></dt></dl></dd><dt><span class="chapter"><a href="plugins_list.html">26. List of plugins</a></span></dt><dd><dl><dt><span class="section"><a href="plugins_list.html#_efene_mk">26.1. efene.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_elixir_mk">26.2. elixir.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_elvis_mk">26.3. elvis.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_geas">26.4. geas</a></span></dt><dt><span class="section"><a href="plugins_list.html#_hexer_mk">26.5. hexer.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_hexpm_mk">26.6. hexpm.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_jorel">26.7. jorel</a></span></dt><dt><span class="section"><a href="plugins_list.html#_lfe_mk">26.8. lfe.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_mix_mk">26.9. mix.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_reload_mk">26.10. reload.mk</a></span></dt><dt><span class="section"><a href="plugins_list.html#_rust_mk">26.11. rust.mk</a></span></dt></dl></dd></dl></dd><dt><span class="part"><a href="about.html">V. About Erlang.mk</a></span></dt><dd><dl><dt><span class="chapter"><a href="why.html">27. Why Erlang.mk</a></span></dt><dd><dl><dt><span class="section"><a href="why.html#_erlang_mk_is_fast">27.1. Erlang.mk is fast</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_gives_you_the_full_power_of_unix">27.2. Erlang.mk gives you the full power of Unix</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_is_a_text_file">27.3. Erlang.mk is a text file</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_can_manage_erlang_itself">27.4. Erlang.mk can manage Erlang itself</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_can_do_more_than_erlang">27.5. Erlang.mk can do more than Erlang</a></span></dt><dt><span class="section"><a href="why.html#_erlang_mk_integrates_nicely_in_make_and_automake_projects">27.6. Erlang.mk integrates nicely in Make and Automake projects</a></span></dt></dl></dd><dt><span class="chapter"><a href="history.html">28. Short history</a></span></dt><dd><dl><dt><span class="section"><a href="history.html#_before_erlang_mk">28.1. Before Erlang.mk</a></span></dt><dt><span class="section"><a href="history.html#_lifetime_of_the_project">28.2. Lifetime of the project</a></span></dt></dl></dd><dt><span class="chapter"><a href="contributing.html">29. Contributing</a></span></dt><dd><dl><dt><span class="section"><a href="contributing.html#_priorities">29.1. Priorities</a></span></dt><dt><span class="section"><a href="contributing.html#_bugs">29.2. Bugs</a></span></dt><dt><span class="section"><a href="contributing.html#_code">29.3. Code</a></span></dt><dt><span class="section"><a href="contributing.html#_packages">29.4. Packages</a></span></dt><dt><span class="section"><a href="contributing.html#_documentation">29.5. Documentation</a></span></dt><dt><span class="section"><a href="contributing.html#_feature_requests">29.6. Feature requests</a></span></dt></dl></dd></dl></dd></dl></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="installation.html">Next</a></td></tr></table></div> </main> </body> </html> diff --git a/guide/installation.html b/guide/installation.html index e8c0f0f..62a3bc8 100644 --- a/guide/installation.html +++ b/guide/installation.html @@ -42,7 +42,8 @@ have further requirements depending on your needs.</p><p>Some packages may requi </p><pre class="programlisting">$ pacman -S erlang git make</pre><p> </p><p>Alpine Linux and other distributions based on BusyBox come with an incompatible <code class="literal">awk</code> program. Installing the GNU Awk -(<code class="literal">gawk</code> on Alpine) solves this issue.</p></div><div class="section"><div class="titlepage"><div><div><h3 class="title"><a id="_freebsd"></a>1.1.2. FreeBSD</h3></div></div></div><p>FreeBSD comes with binary and source packages:</p><p><strong>Install binary packages. </strong> +(<code class="literal">gawk</code> on Alpine) solves this issue.</p><p>Parallel builds may require the program <code class="literal">flock</code> that can +be found in the package <code class="literal">util-linux</code>.</p></div><div class="section"><div class="titlepage"><div><div><h3 class="title"><a id="_freebsd"></a>1.1.2. FreeBSD</h3></div></div></div><p>FreeBSD comes with binary and source packages:</p><p><strong>Install binary packages. </strong> </p><pre class="programlisting">$ pkg install erlang git gmake</pre><p> </p><p>On FreeBSD the <code class="literal">make</code> command is BSD Make. Use <code class="literal">gmake</code> instead.</p></div><div class="section"><div class="titlepage"><div><div><h3 class="title"><a id="_os_x_and_macos"></a>1.1.3. OS X and macOS</h3></div></div></div><p>While Apple distributes their own GNU Make, their version is very old and plagued with numerous bugs. It is recommended @@ -52,7 +53,10 @@ MacPorts:</p><p><strong>Homebrew. </strong> </p><p>Homebrew installs GNU Make as <code class="literal">gmake</code>. The <code class="literal">make</code> command is the one provided by Apple.</p><p><strong>MacPorts. </strong> </p><pre class="programlisting">$ sudo port install erlang git gmake</pre><p> -</p></div></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_on_windows"></a>1.2. On Windows</h2></div></div></div><p>Erlang.mk can be used on Windows inside an MSYS2 environment. +</p><p>Parallel builds may require the program <code class="literal">flock</code> which can +be installed via Homebrew or manually. The instructions +to install are available from its repository: +<a class="ulink" href="https://github.com/discoteq/flock" target="_top">https://github.com/discoteq/flock</a></p></div></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_on_windows"></a>1.2. On Windows</h2></div></div></div><p>Erlang.mk can be used on Windows inside an MSYS2 environment. Cygwin, MSYS (the original) and native Windows (both Batch and PowerShell) are currently not supported.</p><div class="note" style="margin-left: 0; margin-right: 10%;"><h3 class="title">Note</h3><p>Erlang.mk expects Unix line breaks in most of the files (LF instead of CRLF). Make sure to configure your text editor diff --git a/guide/relx.html b/guide/relx.html index da656aa..9d23106 100644 --- a/guide/relx.html +++ b/guide/relx.html @@ -68,8 +68,8 @@ release upgrade:</p><pre class="programlisting">$ make relup</pre><p>This will c release, <code class="literal">$RELX_OUTPUT_DIR/example/example-2.tar.gz</code>.</p><p>Move the archive to the correct location on the running node. From the release’s root directory:</p><pre class="programlisting">$ mkdir releases/2/ $ mv path/to/example-2.tar.gz releases/2/</pre><p>Finally, upgrade the release:</p><pre class="programlisting">$ bin/example_release upgrade "2/example_release"</pre><p>Or on Windows:</p><pre class="programlisting">$ bin/example_release.cmd upgrade "2/example_release"</pre><p>Your release was upgraded!</p></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_getting_relx_semver_value"></a>9.6. Getting Relx semver value</h2></div></div></div><p>There is a <span class="strong"><strong>workaround</strong></span> to get the semver value which is -generated by Relx based on VCS history.</p><p>Create a file <span class="emphasis"><em>rel/version</em></span> with only one line inside:</p><pre class="programlisting">{{ release_version }}</pre><p>Add/Update the <code class="literal">overlay</code> section of your <code class="literal">relx.config</code>:</p><pre class="programlisting">{overlay, [ - {template, "rel/version", "version"} +generated by Relx based on VCS history.</p><p>Create a file <span class="emphasis"><em>config/version</em></span> with only one line inside:</p><pre class="programlisting">{{ release_version }}</pre><p>Add/Update the <code class="literal">overlay</code> section of your <code class="literal">relx.config</code>:</p><pre class="programlisting">{overlay, [ + {template, "config/version", "version"} ]}.</pre><p>When you run <code class="literal">make rel</code> it creates the file <span class="emphasis"><em>$(RELX_OUTPUT_DIR)/example/version</em></span> which contains the version value generated by Relx.</p><pre class="programlisting">$ cat _rel/app/release 1.0.0+build.11.ref5612aa0</pre><p>In your <code class="literal">Makefile</code> you can use this simple snippet to get the version, |