e3_build_tools.fs.make

Module for functions relating to make.

Attributes

Functions

parse_file_for_cxx_stds(→ List[str])

Return all c++ std definitions in a makefile.

find_cxx_stds(→ List[Tuple[pathlib.Path, List[str]]])

Return all c++ std definitions in all makefiles.

create_tmp_makefile(→ None)

Create a temporary makefile to try to determine which variables are undefined.

find_undefined_vars(→ Set[str])

Run make to see which variables have not been defined.

Module Contents

e3_build_tools.fs.make.UNDEF_REGEX = ".*warning: undefined variable [`']([^']+)'"[source]
e3_build_tools.fs.make.CXX_FLAGS_REGEX = '^([^#]*CXXFLAGS)\\s*[+:?]?=.*-std=([^\\s]+)'[source]
e3_build_tools.fs.make.CONFIG_FILES = ['CONFIG_MODULE', 'CONFIG_OPTIONS'][source]
e3_build_tools.fs.make.EXCEPTIONS = ['REQUIRE_CONFIG', 'E3_REQUIRE_CONFIG', 'E3_REQUIRE_TOOLS', 'E3_SITEMODS_PATH', 'COMMON_DIR',...[source]
e3_build_tools.fs.make.logger[source]
e3_build_tools.fs.make.parse_file_for_cxx_stds(f: Iterable) List[str][source]

Return all c++ std definitions in a makefile.

e3_build_tools.fs.make.find_cxx_stds(wrapper_path: pathlib.Path) List[Tuple[pathlib.Path, List[str]]][source]

Return all c++ std definitions in all makefiles.

e3_build_tools.fs.make.create_tmp_makefile(tmp_path: pathlib.Path, wrapper_path: pathlib.Path) None[source]

Create a temporary makefile to try to determine which variables are undefined.

e3_build_tools.fs.make.find_undefined_vars(wrapper_path: pathlib.Path) Set[str][source]

Run make to see which variables have not been defined.

Compile CONFIG_MODULE, CONFIG_OPTIONS, and all *.Makefiles into a single dummy file. Test this using the flag –warn-undefined-variables