Skip to content

Commit

Permalink
pylibfdt/Makefile.pylibfdt: use project's flags to compile the extension
Browse files Browse the repository at this point in the history
Seems the project's CFLAGS are not used when compiling the python
extension's C code via the setup.py script. Some default flags are used
instead. Thus pass the CFLAGS explicitly. Unfortunately the SWIG generated
code is not clean and requires -Wno-error override to compile successfully,
because -Werror is used in the project's flags.

Signed-off-by: Dan Horák <[email protected]>
Signed-off-by: David Gibson <[email protected]>
  • Loading branch information
sharkcz authored and dgibson committed Jul 6, 2024
1 parent 61e88fd commit 1df7b04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pylibfdt/Makefile.pylibfdt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ endif

$(PYMODULE): $(PYLIBFDT_srcs) $(LIBFDT_archive) $(SETUP)
@$(VECHO) PYMOD $@
$(PYTHON) $(SETUP) $(SETUPFLAGS) build_ext
CFLAGS="$(CFLAGS) -Wno-error" $(PYTHON) $(SETUP) $(SETUPFLAGS) build_ext

install_pylibfdt: $(PYMODULE)
@$(VECHO) INSTALL-PYLIB
Expand Down

0 comments on commit 1df7b04

Please sign in to comment.