Age | Commit message (Collapse) | Author |
|
|
|
This is still a bit hackish but it appears that some projects
have wrong erl_first_files entries (module exists but not at
the location configured) and so we have to do a bit of
manipulation before we can find the module. We also need
to be cautious about .yrl/.xrl because their corresponding
.erl files may not exist in the repository before compilation
yet can be listed in erl_first_files.
|
|
We use the same strategy as ~= we try to look for the version
in the .lock file and if we can't find it we guess for now.
|
|
Hut has both a Makefile and erlang.mk but the default target
does not build the project. To fix a few packages we have a
special patch HUT_PATCH that will call the appropriate target.
|
|
|
|
|
|
|
|
We expect users to fetch these projects from hex.pm now
and the packages no longer worked.
|
|
Otherwise some dependencies may get the wrong ERLC_OPTS
and may end up with invalid or duplicate options.
|
|
Thanks Luke Bakken for the report!
|
|
This is the case in erlang-systemd [1]. As far as I can tell, the format
is the same for the bits Erlang.mk is interested in.
The testsuite is expanded to use version 0.6.0 of erlang-systemd.
[1] https://github.com/rabbitmq/erlang-systemd
|
|
|
|
The query-deps, query-doc-deps, query-rel-deps, query-test-deps
and query-shell-deps targets go through dependencies and print
some information about them:
$ make query-deps
...
cowboy: cowlib git https://github.com/ninenines/cowlib 2.7.3
cowboy: ranch git https://github.com/ninenines/ranch 1.7.1
$ make query-deps QUERY="name repo version absolute_path"
...
cowboy: cowlib https://github.com/ninenines/cowlib 2.7.3 /path/to/deps/cowlib
cowboy: ranch https://github.com/ninenines/ranch 1.7.1 /path/to/deps/ranch
The query-deps target is recursive; the others aren't. This
mirrors the behavior when fetching and building dependencies.
The full list of options is:
QUERY="fetch_method name repo version extra absolute_path"
When an option has no corresponding value, "-" will be printed.
For example most fetch methods do not have extra information to
print. When there is extra information, the value will be prefixed
with a descriptive name. For example: package-name=uuid_erl
This commit also introduces changes to deps handling: some of
the functions for querying will now be used directly. In the
future the goal is to remove the old dep_name, dep_commit, etc.
functions and replace their usage with the new query functions.
Custom fetch methods should implement query functions in order
to have information about the relevant dependencies printed
properly.
|
|
Properly fixes partisan.
|
|
Fixes partisan.
|
|
... in addition to the `$(force_rebuild_dep)` function.
It's easier for the common use case than specify a function.
|
|
|
|
|
|
By default, Erlang.mk only builds dependencies once, the first time the
top-level project is compiled. A forced rebuild of all dependencies can
be forced by setting the `$(FULL)` variable to a non-empty value.
For developers working on the top-level project and one or more
dependencies at the same time, Erlang.mk now accepts a variable/function
called `$(force_rebuilding_dep)` which is called to determine if the
dependency passed as the first argument should be forcibly rebuilt.
It allows a developer to filter the dependencies he works on (so they
are always rebuilt) from other third-party dependencies he never touches
(i.e. they are only built once at the beginning).
The content of `$(force_rebuilding_dep)` is expected to be a shell
one-liner where the `$(1)` Make variable is set to the path to the
dependency.
Here is an example from the testsuite:
force_rebuilding_dep = test '$(1)' = '$(CURDIR)/deps/cowlib'
|
|
Allow a lack of space in the front. This will of course need
to be handled better eventually.
|
|
... exactly as it is displayed for Git-based dependencies.
|
|
|
|
For now, ~> is expanded to a full version only.
|
|
|
|
|
|
This solution should work better, previous one would sometimes
expand incorrectly and fail.
|
|
And use this in the tests to fetch Rebar only once and then
clone from the local repository. This should speed up tests
a little.
|
|
|
|
|
|
|
|
Unless it's a symbolic link, it's built directly, FULL=1 is set
or the file ebin/dep_built in the dependency is removed.
See the documentation changes for more details.
This provides immense build speed gains, for example on a
RabbitMQ project it went from 10s to 1s for the 2nd+ builds.
|
|
For example:
DEPS = elixir
ELIXIR_PATCH = 1
include erlang.mk
A language test suite will soon be added with a test for this.
|
|
The $(...) form was improperly converted. In addition it
must be changed into a $(shell ...) form.
|
|
|
|
Currently experimental. It'll enable lfe.mk when it encounters
the rebar3 plugin lfe-compile. Tested against some small library.
Note that it adds lfe as a build dependency with no version given
so the latest master will be fetched right now. This can be
overriden in the parent project.
|
|
Until it is found that one is needed to compile a project.
|
|
|
|
|
|
When the $(MAKE) is inside an $(eval $(call ...)) then it needs
to be escaped as $$(MAKE).
When the $(MAKE) is inside a $(call ...) then I did not figure
out a way other than passing it as an argument.
When the $(MAKE) is inside many levels of $(call $(call ...))
it's easier to avoid it if at all possible, so I replaced the
rebar $(MAKE) call with ./bootstrap. I confirmed it works fine
on Windows as well.
|
|
Fetching rebar is conditional depending on the project
being built, and if two projects require it and -j is
used this could mean the fetching happens at the same
time and one would fail.
|
|
I've reworked how the multi-apps projects are built. In particular
I've made sure the test build is made from the top-level once, and
then only tests are run on this build. It used to build multiple
times and some builds would not include test mode, not good. I've
also fixed issues with running tests in parallel.
All tests now pass with -j8 on my machine. It's possible more
issues remain that are not covered by tests yet though.
|
|
It clones and checkouts like the git fetch method, but
does so in the Erlang.mk temporary directory. It then
creates a symbolic link to the subfolder for the dependency.
|
|
|
|
Also add a missing space character.
|
|
It's cheap, can be useful to detect issues, so why not?
|
|
|
|
This fixes hackney.
|
|
|
|
(i.e. not wrapped inside a list - rebar3 allows this as well)
|
|
Ew, rebar, again!
|