- Fix caching bug introduced in 0.12.3.
- Report compiler warnings (as
warn
level log messages).
- Add
link-commands
toModule
, similar tocompile-commands
.
- Rename
src/module.ergo
to not clash withsrc/Module.ergo
on case-insensitive filesystems. - Add
@rpath
to theinstall_name
used in mac shared libraries.
- Update to ergo-1.0.0rc.4.
- Completely refactor the organization of modules and how they are evaluated.
- Module creation (
module
,compiled-module
,exe
,dynamic-library
,static-library
), helpers (all-files
,header-paths
,exact-name
), and toolchains (toolchain
,env-toolchain
) all have the same API as before. Module
andLink
(previouslyModuleLink
) are now directly exposed (no longer undertype
), are specified more thoroughly, and have associated functions in each type index.context
is applied withbind-context
to prevent mistakes.Module
s no longer flatten the dependency hierarchy.
- Module creation (
- Break up the one big implementation file for better maintenance.
- Fix a bug in header tracking (when
include-dependencies
isrelaxed
).
- Fix the propagation of direct runtime dependencies through static libraries.
- Ensure detection works with both newer libstdc++ headers and older ones.
- The fix from 0.11.13 doesn't seem to work with older versions for some reason.
- Fix an incompatibility with newer libstdc++ headers in compiler detection.
- Fix a bug introduced in 0.11.11 which caused modules to recompile files if they depended upon a module which had to recompile a file.
- Properly unique the runtime files in
exec-output
. - Fix a bug in file dependency tracking: when
include-dependencies
isaccurate
(the default), if an dependent header path changed, the file dependencies were not recomputed.
- Change header dependency checks to be run as tasks (mainly to limit concurrency, but also to illuminate what's going on to users).
- Don't run header dependency checks on headers themselves when
include-dependencies
isaccurate
(the default), as it is unnecessary in that case: that information is only used to reconstruct missing dependencies, which only happens inrelaxed
mode. - XXX: Since 0.11.7, public/private header dependency checking has been broken (since it relied on headers not resolving). In general the dependency checking should be refactored to make it more consistent and enable better features.
- Use
LD_LIBRARY_PATH
rather thanLD_PRELOAD
forexec-output
on linux, as this interacts better with llvm-symbolizer (used by sanitizers).- Previously we favored
LD_PRELOAD
because it avoids caring about file SONAMEs, but we've long had the runtime (e.g. abi symlinks) as part of the files so it shouldn't be an issue.
- Previously we favored
- Add a
runtime-direct
field to linked modules to indicate the direct runtime dependencies (excluding secondary dependencies).
- Properly set the
runtime-if-used
field forcompiled-module
s based on the link arguments. - Use the full includes when determining header dependencies.
- In general this will behave better for weird header shenanigans, at the cost of possibly forcing dependent headers to be evaluated and accessible.
- Add an
include-dependencies
option which can be used to revert behavior to the old method.
- Correctly handle windows env variable path separators.
- Revert the 0.11.4 change as it causes unacceptable quadratic memory behavior which is detrimental in large projects with a lot of nesting.
- Add a
library-paths
optional argument totoolchain
to ensure toolchains that require library paths in the environment are accounted for. - Add a
tool-exec-env
map and anexec
function to the value returned fromtoolchain
to make executing toolchain binaries less error-prone.
- Don't deduplicate module
header-dirs
fields to allow consumers to use these to convey disparate metadata for the same root header directory.
- Correctly categorize
env-toolchain
in documentation (to prevent it from being evaluated prematurely among other things), and allow strings to be passed astoolchain
overrides (which was the intention based on documentation but was not realized in the types provided). - Ensure a leading
.
is removed in header-deps include paths.
- Pretty-print
compile_commands.json
.
- Always include
-fPIC
by default.- This is less surprising when it comes to linking and also allows for more sharing of cached object files.
- Fix a caching bug resulting from the cached file dependency results being misidentified.
- Update scripts for ergo-1.0.0rc.1.
- Improve correctness/safety of configuration-based caching.
- Improve the behavior of header dependency checking when the compiler fails.
- Failures are inevitably due to preprocessor behavior which is difficult to account for, so reduce the errors to warnings (for header files).
- Change the produced
impl
field of modules to belink
, and change it to be an array oftype:ModuleLink
types. - Add a
module-link
submodule with basic functions to extract values from thelink
field. - Add
type:ModuleLink
to distinguish linked value types. - Fix dependency visibility errors being propagated (when checking header dependencies).
- Use correct toolchain identity when changing toolchain flags from function arguments.
- Any use of
c++:compiled-module
will need to update thelink
field to haveModuleLink
-typed values. - Any use of
c++:get-output
will need to access thelink
field rather than theimpl
field (and access the inner values appropriately withc++:module-link
functions).
- Fix a bug in static library creation.
- Change compilation of
.c
files to use the C compiler.c-compile-flags
is used to distinguish from C++ compile flags.
- Fix a bug in the detection of private includes used in public headers.
- Fix a bug in file dependency calculation.
- Fix a bug in
exact-name
behavior.
- Fix a bug in nested module change tracking.
- Changes to nested module files would be missed in subsequent builds.
- Improve concurrent behavior of configuration-based caching.
- There is a race condition that would cause an error to occur. In lieu of additional features/support from the standard library, we avoid the error but possibly do extra work.
- Change shallow copies of header files to be symlinks.
- These behave better with CI caching.
- Fix header tracking! It was broken since the update to ergo rc.0, as the semantics around evaluation were being relied upon for correct caching.
- Use shallow copies for header files so
#pragma once
and editors can find the original files. - Drastically improve performance of builds with nested modules with a little extra caching.
- Change toolchain to allow arbitrary tool names.
- Optimize header dependency tracking with additional caching.
- Fix toolchain default behavior (a bug was making it default to Unset).
- Fix bug in
header-paths
preventingall
from working as intended.
- Updated to support ergo-1.0.0-rc.0.
- Expose the
context
value to retrieve the current compilation context.
- Change
options:file-content-cache
to instead beoptions:cache-policy
, with options ofconfiguration
andcontent
. - Change modules to store arbitrary values rather than a function that takes the
context. This changes the paradigm of creating modules to one where a user
writes expressions (that optionally use
context
) which evaluate to aModule
type, doing any necessary value- or context-dependent work prior to creating theModule
. compile-flags
andlink-flags
arguments now are just arrays; if the context is needed, usecontext
.- Change
env-toolchain
to be a value rather than a function.
- Fix a bug with symbolic link creation.
- Correct
static-library-name
to return a name with alib
prefix for linux/mac.
- Improve behavior of compile-flags/link-flags.
- Compile-flags for a linked output are inherited only by modules that linked output uses. Link-flags are not inherited at all.
- Add
abi-version
option todynamic-library
, supporting OS conventions for abi versioning. - Fix
exec-output
on mac when runtime libraries are needed.
- Add
compile-commands
to write acompile_commands.json
file from outputs. - Change caching to (by default) only depend on compile flags. Add the
options
map toget-outputs
configuration, which has afile-content-cache
key which may be specified to cache based on file content as well (as it used to). - Allow
uses
to be distinguished as public/private/export.- If a private include is exposed in a public header, an error will occur.
- Add
compiled-module
function for creating modules from pre-compiled outputs. - Move
exe:exec
toexec-output
, and improve behavior by using the host os and preloading libraries when possible, rather than specifying a library load path. This avoids issues with SONAME file lookup.
- A
uses
that's just an array will be interpreted as private visibility, whereas in the past it behaved as if it were public visibility. exe:exec
no longer works;exec-output
should be used instead.
- Update to ergo beta.9.
- Improve type checking and performance using new ergo standard library functions.
- Add
object-dump
to the toolchain definition. - Fix the detection of c++ library and c++ abi.
- C++ library wasn't always working (depending on cassert include).
- C++ abi was getting false positives, so the detection file has been improved to only use the c preprocessor (which we didn't realize was possible before).
- Fix naming of outputs.
exact-name
detection was incorrect.
- Correctly track headers in
header-dirs
output for each module.- Previously there was a bug where, if a header was changed, it did not consider it different and did not generate a new header directory.
- Add
c-compiler
andc-compile-flags
to the toolchain in support of building external libraries. - Add
exact-name
to be able to indicate that a target's conventions shouldn't be applied to the name of a file.- This is more for nice bookkeeping, since you can still always rename the file when copying it.
- Allow
compiler
andarchiver
to be specified as paths to binaries
- Use
#include <cassert>
rather than c++20's#include <version>
in stdlib detection. - Fix
static-library
functionality.
- Add C++ library and ABI detection keys to the toolchain target map
- Fix linker errors on macOS, which groups everything by default
- Fix deduplication function that broke with syntax changes in ergo 8.
- Deduplicate runtime and impl lists in modules.
- Simplify
headers
andfiles
definitions. Remove support forauto
for both, as well as formodule
. - Add
all-files
andheader-paths
to replace functionality previously built-in tomodule
.
- Allow headers to be plain strings (to be interpreted as relative paths).
- Toolchains to be used are now parameterized.
- Use
toolchain
to create a toolchain from a configuration, and pass it intoget-output
. - The previous
target
functions are now in the produced toolchain.
- Use
- Add
env-toolchain
to get a toolchain based on the environment. - Update to ergo beta.8.
- Use a
Module
type for c++ modules. - Allow paths in
files
andheaders
to be relative. Do not require specifying the relative directory (it will default to the executing script's directory), though it can be set with the non-positional argumentrelative-dir
to themodule
function.
- Fix bug with compiler invocation for header tracking.
- The invocation did not pass the PATH environment variable, which breaks e.g. ccache.
- Improve task behavior (ergo >= beta.6).
- Add a preprocessor value (
ERGO_CPP_HEADER_DEPENDS
) when checking header dependencies.- This allows code to avoid problematic preprocessor directives.
- Change functions to take named arguments.
- Support setting cflags directly on modules.
- Fix bug with file names and
target-os
.
- Fix export bug for naming functions.
- Update for ergo 1.0.0-beta.4.
- With new features from the latest ergo, add header tracking.
- Support header layout descriptions.
- Support ccache and fix the invocation to detect the target os.
- Improve how runtime file dependencies are linked.
- Expose some of the internally-derived values like target-os and the name conventions.
- Update for ergo 1.0.0-beta.2.
- Change
context
function toapply-context
.
- Initial release of the module.