Age | Commit message (Collapse) | Author |
|
If the application's Makefile specify either:
DEP_PLUGINS = $(PROJECT)
or e.g.:
DEP_PLUGINS = $(PROJECT)/mk/dist.mk
then load the plugin from the application instead of a dependency.
This helps when you have an application with common Erlang modules and
Erlang.mk plugins: your common application can load Erlang.mk plugins
exactly like other applications depending on the common application.
|
|
|
|
We do not touch the erlang.mk file anymore. We only patch the
Makefile to include the top-level Erlang.mk by changing the
'include erlang.mk' line to look for ERLANG_MK_FILENAME if it
is defined. The modified Makefile can be committed safely.
|
|
|
|
'source_path' property of edoc default to the list of explicit deps and apps
Can be overriden with EDOC_SRC_DIRS
In general, edoc options can be overriden with EDOC_OPTS, à la proplists
'source_path' edoc property is not recursive: look for source code in 'src' and 'c_src'
|
|
There are no more legacy tests. Enjoy!
|
|
|
|
|
|
|
|
In particular, xrefr 1.1.0 now exits with a non-zero exit status if
there are any warnings reported. This makes `make xref` fail
appropriately.
|
|
Regular plugins (`$(DEP_PLUGINS)`) are loaded near the end of Erlang.mk.
This is fine when you want to modify variables initialized earlier in
Erlang.mk or add new targets and variables.
However, it doesn't allow you to declare more dependencies because they
are loaded too late for that.
This commit introduces a new variable, `$(DEP_EARLY_PLUGINS)`, which can
be used to list plugins meant to be loaded near the beginning of
Erlang.mk. Those allow to append to the list of dependencies.
They work exactly like regular plugins otherwise. The default filename
loaded is `early-plugins.mk`.
|
|
Before this change, the build would continue, even if a dependency
failed to build. This could lead to obscure errors in the middle of a
testsuite for instance.
With this change, the build fails immediately, exactly like when a
regular dependency fails to build.
While here, replace most uses of `|| exit $$?` with `set -e`. This
simplifies error handling if we need to add more commands to each
blocks.
Also, echo error messages to stderr.
|
|
This silences warnings such as:
mv: rename file.app to file.app.src: No such file or directory
They are harmless really, but still annoying.
|
|
When the test check the running applications in the started release, the
node may not be up yet. So loop until the command returns a list of
applications (instead of "Node is not running!").
This fixes some transient failures.
|
|
Before this change, the help message for this plugin was:
Xref targets:
xref Run Xrefr using REF_CONFIG as config file if defined
Note the missing `$X` before `REF_CONFIG`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
we also use LOCAL_DEPS at the top-level, if it exists, to determine
which local apps to compile, in the interest of saving compile time
for projects that have many apps and multiple release configurations
|
|
`rm deps.log` was not being executed, because of 1) the ifeq around
it, checking for an empty ALL_DEPS_DIRS, which i believe was a logical
error; and 2) deps depended on apps, which means apps were compiled
before its recipe was executed, and the `rm deps.log` would be
executed after it had been written to by recursive make of the
apps.
the important reason to remove deps.log is so that dependencies get
remade when they change. otherwise you'll get mysterious errors about
missing dependencies if they need to be rebuilt, or worse, have wrong
stale beam files bundled in your release.
tests core-deps-apps and core-deps-apps-only now manually clean the
cowlib dep and rebuild at the top-level to make sure cowlib gets
rebuilt. both tests indeed fail without this fix.
this attempts to fix #1 by removing the ifeq, and #2 by having deps
and apps depend on deps.log, with deps.log 'built' (but actually
removed) by a double-colon rule with no prerequisites (which means its
recipe always be run).
|
|
|
|
|
|
Run erlydtl after compilation of project src. This accommodates erlydtl configs that include custom modules.
|
|
This allows all plugins to append to existing variables
and makes it easier to augment the functionality of the
core plugins.
|
|
Because we were unconditionally including the makedep file,
it would be built even if the target was unrelated (like
"make help"), and it would also trigger building of xrl
and other files that produce Erlang code.
Instead the makedep file is now included as a wildcard:
if it exists it gets included, if it doesn't it's not,
and if it's created in the middle of execution it gets
included only then.
More details on the technique can be found at
http://make.mad-scientist.net/papers/advanced-auto-dependency-generation/
A test has been added to make sure the behavior does not
come back at a later time.
|
|
Suggesting -Sy is a terrible idea[1]. This commit replaces it with -S
which is the default on how packages should be added on Archlinux.
Resolves #662.
[1]: https://bbs.archlinux.org/viewtopic.php?id=89328
|
|
`ERLC_ASN1_OPTS` can be used to pass compiler options when compiling
ASN.1 files. By default, Erlang.mk will leave this empty, but it can
be redefined in a Makefile.
|
|
Syntastic, an Erlang syntax checker plugin for Vim, uses the Erlang
compile application to get compilation errors and warnings. Therefore it
needs cooperation from the build system to get the appropriate compile
flags.
Currently it supports Rebar by parsing the configuration file. To add
support for Erlang.mk, we need new Make targets to return the compile
flags.
This plugin adds three targets:
o make show-ERL_LIBS
o make show-ERLC_OPTS
o make show-TEST_ERLC_OPTS
Separate patches for Syntastic's builtin checker and syntaxerl are
ready: they simply run those targets and parse the output.
|
|
|
|
... not $(ESCRIPT_NAME), which can be set to another value.
While here, add a testcase for `make distclean`.
|
|
|
|
Before we had Dialyzer look for BEAM files in every subfolders
of every deps. This resulted in the PLT bundling extra files
and/or Dialyzer failing because some of them are not built with
+debug_info, or because there are duplicates (in test logs for
example). Now Dialyzer will only look in ebin/.
|
|
|
|
When the index files are concatenated, (`index/*` in `build.config`),
their order is related to the collation locale used by the shell. By
explicitely setting this to the C locale, we make sure that the order is
consistent, no matter the user's locale.
It is especially useful in teams where users and systems have different
locales.
|
|
Erlang.mk projects either have a .app.src, or just the Makefile
with an optional .app file for compatibility.
|
|
If we have a .app and a .app.src we delete the .app.
If we have a Rebar project with a .app file, rename it to
.app.src and continue with autopatch.
If we have a non-Rebar project, leave the .app file, and then...
For all cases, delete the ebin/ folder after autopatch completes.
|
|
|
|
Official name after all.
|
|
[ci skip]
|
|
Oops!
[ci skip]
|
|
The VM used to test LLVM built code is the --enable-native-libs one.
|