e-m-b-a / emba

EMBA - The firmware security analyzer
https://www.securefirmware.de
GNU General Public License v3.0
2.69k stars 233 forks source link

docker compose dependency crash #1313

Closed qequ closed 1 month ago

qequ commented 1 month ago

Describe the bug Running docker-compose one of the dependencies being installed fails

1464.2       [ 10%] No update step for 'lief_libjson'
1464.2       [ 10%] No patch step for 'lief_libjson'
1464.2       [ 10%] No configure step for 'lief_libjson'
1464.2       [ 10%] No build step for 'lief_libjson'
1464.2       [ 10%] No install step for 'lief_libjson'
1464.2       [ 10%] Completed 'lief_libjson'
1464.2       [ 10%] Built target lief_libjson
1464.2       [ 10%] Generating internal/utfcpp/utf8.h
1464.2       [ 10%] Generating include/LIEF/third-party/internal/leaf.hpp
1464.2       [ 10%] Generating include/LIEF/third-party/internal/span.hpp
1464.2       [ 10%] Generating internal/nlohmann/json.hpp
1464.2       [ 10%] Building CXX object CMakeFiles/LIB_LIEF.dir/src/errors.cpp.o
1464.2       [ 10%] Building CXX object CMakeFiles/LIB_LIEF.dir/src/hash_stream.cpp.o
1464.2       [ 11%] Building CXX object CMakeFiles/LIB_LIEF.dir/src/logging.cpp.o
1464.2       [ 11%] Building CXX object CMakeFiles/LIB_LIEF.dir/src/exception.cpp.o
1464.2       In file included from /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/src/exception.cpp:19:
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:75:38: error: expected ‘)’ before ‘offset’
1464.2          75 |   explicit read_out_of_bound(uint64_t offset, uint64_t size);
1464.2             |                             ~        ^~~~~~~
1464.2             |                                      )
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:76:38: error: expected ‘)’ before ‘offset’
1464.2          76 |   explicit read_out_of_bound(uint64_t offset);
1464.2             |                             ~        ^~~~~~~
1464.2             |                                      )
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/src/exception.cpp:50:1: error: no declaration matches ‘LIEF::read_out_of_bound::read_out_of_bound(uint64_t, uint64_t)’
1464.2          50 | read_out_of_bound::read_out_of_bound(uint64_t offset, uint64_t size) : LIEF::exception("") {
1464.2             | ^~~~~~~~~~~~~~~~~
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note: candidates are: ‘LIEF::read_out_of_bound::read_out_of_bound(LIEF::read_out_of_bound&&)’
1464.2          71 | class LIEF_API read_out_of_bound : public exception {
1464.2             |                ^~~~~~~~~~~~~~~~~
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(const LIEF::read_out_of_bound&)’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound()’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:73:20: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(const LIEF::exception&) [inherited from LIEF::exception]’
1464.2          73 |   using exception::exception;
1464.2             |                    ^~~~~~~~~
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:73:20: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(std::string) [inherited from LIEF::exception]’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:73:20: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(const char*) [inherited from LIEF::exception]’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note: ‘class LIEF::read_out_of_bound’ defined here
1464.2          71 | class LIEF_API read_out_of_bound : public exception {
1464.2             |                ^~~~~~~~~~~~~~~~~
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/src/exception.cpp:58:1: error: no declaration matches ‘LIEF::read_out_of_bound::read_out_of_bound(uint64_t)’
1464.2          58 | read_out_of_bound::read_out_of_bound(uint64_t offset) : LIEF::exception("") {
1464.2             | ^~~~~~~~~~~~~~~~~
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note: candidates are: ‘LIEF::read_out_of_bound::read_out_of_bound(LIEF::read_out_of_bound&&)’
1464.2          71 | class LIEF_API read_out_of_bound : public exception {
1464.2             |                ^~~~~~~~~~~~~~~~~
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(const LIEF::read_out_of_bound&)’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound()’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:73:20: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(const LIEF::exception&) [inherited from LIEF::exception]’
1464.2          73 |   using exception::exception;
1464.2             |                    ^~~~~~~~~
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:73:20: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(std::string) [inherited from LIEF::exception]’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:73:20: note:                 ‘LIEF::read_out_of_bound::read_out_of_bound(const char*) [inherited from LIEF::exception]’
1464.2       /tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/include/LIEF/exception.hpp:71:16: note: ‘class LIEF::read_out_of_bound’ defined here
1464.2          71 | class LIEF_API read_out_of_bound : public exception {
1464.2             |                ^~~~~~~~~~~~~~~~~
1464.2       make[3]: *** [CMakeFiles/LIB_LIEF.dir/build.make:138: CMakeFiles/LIB_LIEF.dir/src/exception.cpp.o] Error 1
1464.2       make[2]: *** [CMakeFiles/Makefile2:411: CMakeFiles/LIB_LIEF.dir/all] Error 2
1464.2       make[1]: *** [CMakeFiles/Makefile2:472: api/python/CMakeFiles/pyLIEF.dir/rule] Error 2
1464.2       make: *** [Makefile:306: pyLIEF] Error 2
1464.2       Traceback (most recent call last):
1464.2         File "<string>", line 2, in <module>
1464.2         File "<pip-setuptools-caller>", line 34, in <module>
1464.2         File "/tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/setup.py", line 484, in <module>
1464.2           setup(
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/__init__.py", line 117, in setup
1464.2           return distutils.core.setup(**attrs)
1464.2                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/core.py", line 183, in setup
1464.2           return run_commands(dist)
1464.2                  ^^^^^^^^^^^^^^^^^^
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/core.py", line 199, in run_commands
1464.2           dist.run_commands()
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 954, in run_commands
1464.2           self.run_command(cmd)
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/dist.py", line 950, in run_command
1464.2           super().run_command(command)
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 973, in run_command
1464.2           cmd_obj.run()
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/command/bdist_wheel.py", line 398, in run
1464.2           self.run_command("build")
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/cmd.py", line 316, in run_command
1464.2           self.distribution.run_command(command)
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/dist.py", line 950, in run_command
1464.2           super().run_command(command)
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 973, in run_command
1464.2           cmd_obj.run()
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/command/build.py", line 135, in run
1464.2           self.run_command(cmd_name)
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/cmd.py", line 316, in run_command
1464.2           self.distribution.run_command(command)
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/dist.py", line 950, in run_command
1464.2           super().run_command(command)
1464.2         File "/external/emba_venv/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 973, in run_command
1464.2           cmd_obj.run()
1464.2         File "/tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/setup.py", line 98, in run
1464.2           self.build_extension(ext)
1464.2         File "/tmp/pip-install-stold17x/lief_2909c0d7c52d43e3ab6911b51a450ede/setup.py", line 308, in build_extension
1464.2           subprocess.check_call(['make', '-j', str(jobs), targets['python_bindings']], cwd=self.build_temp, env=env)
1464.2         File "/usr/lib/python3.12/subprocess.py", line 413, in check_call
1464.2           raise CalledProcessError(retcode, cmd)
1464.2       subprocess.CalledProcessError: Command '['make', '-j', '1', 'pyLIEF']' returned non-zero exit status 2.
1464.2       [end of output]
1464.2   
1464.2   note: This error originates from a subprocess, and is likely not a problem with pip.
1464.2   ERROR: Failed building wheel for lief
1464.2   Running setup.py clean for lief
1464.5 Successfully built arpy
1464.5 Failed to build lief
1464.5 ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (lief)
1464.7 ------------------------------------------------------------------------------------------------
1464.7 Error detected - status code 1
1464.7 Command:  echo -e "Command:  ${ORANGE}${BASH_COMMAND}${NC}"
1464.7 Location:  ./installer/helpers.sh, line 182
1464.7 Stack Trace:
1464.7     [1] pip_install(): ./installer/helpers.sh, line 182 -> pip_install unblob
1464.7     [2] IP61_unblob(): ./installer/IP61_unblob.sh, line 93 -> IP61_unblob
1464.7     [3] main(): /installer.sh, line 339 -> main -s -D
1464.7 
1464.7 Important: Consider filling out a bug report at https://github.com/e-m-b-a/emba/issues
1464.7 
1464.7 ------------------------------------------------------------------------------------------------

To Reproduce Steps to reproduce the behavior:

  1. docker-compose build emba

Expected behavior finishing the installation and running emba

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Priority issue Are you already a Sponsor? - N

Additional context Add any other context about the problem here.

github-actions[bot] commented 1 month ago

Thank you for contributing an issue!

Welcome to the EMBA firmware analysis community!

We are glad you are here and appreciate your contribution. Please keep in mind our contributing guidelines here and here. Also, please check existing open issues and consider to open a discussion in the dedicated discussion area. Additionally, we have collected a lot of details around EMBA, the installation and the usage of EMBA in our Wiki.

If you like EMBA you have the chance to support us by becoming a Sponsor or buying some beer here.

To show your love for EMBA with nice shirts or other merch you can check our Spreadshop.

This is an automatic message. Allow for time for the EMBA community to be able to read the issue and comment on it.

m-1-k-3 commented 1 month ago

In the mean time please use the provided EMBA docker images.

m-1-k-3 commented 1 month ago

could you do a test of PR #1321

m-1-k-3 commented 1 month ago

docker base image v1.4.2e is up and could be used for early testing