Age | Commit message (Collapse) | Author |
|
This will make sure we don't look twice.
Also make a single call to find the common file formats
rather than many calls.
|
|
The previous approach spawned a shell for every single source files. As
we disable parallel make jobs, this is very time consuming.
The new approach uses an intermediate timestamp file in $(ERLANG_MK_TMP)
to record the last modification of any of $(MAKEFILE_LIST) and touch
all source files in one command. Then, the .app file depends on this
timestamp file.
We test the existence of this timestamp file: if if doesn't exist, don't
touch source files, they will be built anyway.
$(PROJECT).d now depends directly on $(MAKEFILE_LIST); before, this
dependency was indirect through $(ERL_FILES). Also, once $(ERL_FILES)
were touched, we do the same with $(PROJECT).d because there is no need
to regen it because of this.
|
|
This allows to add standard keys which do not have a corresponding
`PROJECT_` Makefile variable, as well as non-standard keys.
|
|
|
|
|
|
Fix #587
|
|
|
|
|
|
|
|
Extended Mode uses { and } as special characters. Making grep
implementations other then GNU grep fail (see
http://www.gnu.org/software/grep/manual/grep.html#Basic-vs-Extended).
|
|
|
|
This makes i18n work. It worked before, but I didn't know,
and broke it. Next commit will add i18n to the index to
ensure this doesn't happen again.
|
|
One case was added, where a -compile attribute specified a list
that included a parse_transform. This affected alog, for example.
The COMPILE_FIRST variable is now filled from a digraph. This
allows us to keep track of the dependency tree properly, rather
than rely on luck. This affected erlando.
With both of these changes in, a large chunk of the rebar
autopatch code can be removed, the part that concerned the
auto detection of file dependencies.
On the other hand, we still need to honor the erl_first_files
configuration value, otherwise the parse_trans project fails
to build. While it would be possible to detect these dependencies
automatically too, it's probably too complex to bother, at least
for now.
|
|
|
|
We can now use 'make -j 32' again. All tests pass. There might
be some issues left with the areas that are not fully tested
yet (some plugins).
A few changes in behavior:
* 'make app' will also do 'make deps' unless SKIP_DEPS is set.
You can use 'make app-build' instead to just build the application.
* 'make rel' will also do 'make app' (and therefore deps). There
are no alternative target to keep the old behavior at this time.
|
|
The `-n` flag is not standard and not portable. It is supported by many
Bourne shell to suppress the trailing newline character. But some old
shells do not support this and "-n" is printed.
This is the case for instance on some old versions of Mac OS X where
`/bin/sh` is Bash 3.2.
|
|
|
|
Everything will be rebuilt when the Makefile or any included
Makefile (like Erlang.mk or plugins) change.
Only the .app will be rebuilt when the .app.src file changes.
|
|
|
|
|
|
This changes adds Rebar-like "apps/" functionality.
From this commit onward, Erlang.mk supports 4 types of repositories:
- Repo with an Erlang app at root level + deps/
- Repo with an Erlang app at root level + apps/ deps/
- Repo with no app at root level + deps/
- Repo with no app at root level + apps/ deps/
Example usage:
- make new-app in=webchat
- make new t=gen_server n=my_chat in=webchat
- make
Replace new-app with new-lib to create an OTP library instead of
an OTP application.
|
|
Replacing $(newline) occurances with \n before passing it to printf
instead of echo ensures valid output accross different platforms.
|
|
|
|
Also fixes two bugs with the new "no .app.src" method.
All tests now pass with both methods.
We can now test specific cases with make check c=$CASE.
|
|
This way we can commit the .app file once and it won't
change until we actually change something. Much better
for "no .app.src" file method.
We are getting close to making this method the default!
|
|
|
|
We have nothing to hide.
|
|
|
|
This is useful only for projects that are stable and rarely
need to rebuild it. Check the guide additions for more info.
|
|
R16B03 in particular is missing epp:parse_file/2.
|
|
Fixes a bug detected with the test introduced in the previous commit.
|
|
Dirty, dirty files!
|
|
This ensures all generated dependencies are prepared and the .d file is
ready before the actual build is started.
|
|
|
|
* Move the .app generation to the .app rule (don't remake it
for no reasons when nothing needs to be done)
* Rever the previous double colon commit; add touch $@ in depend
* Move the creation of ebin/ directory in its own rule
* Temporarily remove the ignore on missing depend file
|
|
The touch(1) happens after `$(PROJECT).d` is generated. Therefore, with
the next run of make, `$(PROJECT).d` is considered obsolete and
recreated. Source files are touched again, and so on.
This makes the whole project to be rebuilt with every run of make.
|
|
When files are generated, this avoids a warning because the target would
be redefined.
|
|
This is a very large change of a central part of Erlang.mk.
I will admit that I am not quite confident on that one. If
you do have issues following this change, please open a
ticket and I will look at it immediately.
At this point, it works for me, but I wouldn't be surprised
to hear about a few minor issues.
This commit introduces a dependency file $(PROJECT).d which
contains Makefile rules between Erlang source files and
headers, behaviors and parse_transforms. This allows us
to rebuild only the files that are needed.
The $(PROJECT).d is generated automatically when missing,
and when any of the files change.
It is possible to hook before and after this generation,
by defining a $(PROJECT).d:: rule. This allows users to
generate Erlang files which are then compiled by Erlang.mk
automatically (and to track their dependencies, of course).
Here goes nothing...
|
|
|
|
Fix a bug where deps that use erlang.mk didn't have the -Werror
option suppressed automatically.
|
|
|
|
This commit implements a core_find and core_ls function that
can be used to list files recursively or not.
A few other minute changes are included and a couple hacks
removed.
|
|
Was using $(MODULES) instead of $(2).
|
|
Fixes a previous incomplete PR merged by mistake.
|
|
This removes the need for a .app.src file entirely.
The PROJECT_* variables and the OTP_DEPS variable
allow us to specify everything we need.
REL_DEPS and BUILD_DEPS will be added later on to
allow users to cleanly specify those without adding
them to the .app file.
|
|
|
|
Some projects had their modules section filled incorrectly, this
has been fixed.
Merl (used by erlydtl) had its .app file incorrectly moved to
.app.src despite having its own Makefile. This has been fixed.
A new g++ warning caused some projects with -Werror to fail to
compile, this has been fixed.
The include path given in rebar.config is now properly used.
The project concuerror has been removed temporarily due to a
recent change that broke the auto detection.
The projects ircbot, exmpp and tsung have been removed temporarily
due to broken modules section and will need a custom patch and/or
a PR sent to fix them.
|
|
|
|
|
|
Also added a copyright line in the eunit plugin due to the
extensive work I have done there a few days ago.
|