Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tools: Docker: install build-essential apt package (IDFGH-9402) #10772

Closed
wants to merge 1 commit into from

Conversation

ncmiller
Copy link

Before this change, it was not possible to build an application with target linux in Docker.

For example, building examples/build_system/cmake/linux_host_app:

docker run -t -e IDF_TARGET="linux" -v "$PWD/examples/build_system/cmake/linux_host_app:/app/linux_host_app" -w "/app/linux_host_app" espressif/idf:v5.0 /bin/bash -c 'git config --global --add safe.directory "*" && idf.py build'

results in the following error:

CMake Error at /opt/esp/idf/tools/cmake/build.cmake:129 (enable_language):
  No CMAKE_CXX_COMPILER could be found.

This commit adds the build-essential package to the list of apt packages to install, which allows the example above to build successfully.

Before this change, it was not possible to build an application with
target `linux` in Docker.

For example, building `examples/build_system/cmake/linux_host_app`:

```
docker run -t -e IDF_TARGET="linux" -v "$PWD/examples/build_system/cmake/linux_host_app:/app/linux_host_app" -w "/app/linux_host_app" espressif/idf:v5.0 /bin/bash -c 'git config --global --add safe.directory "*" && idf.py build'
```

results in the following error:

```
CMake Error at /opt/esp/idf/tools/cmake/build.cmake:129 (enable_language):
  No CMAKE_CXX_COMPILER could be found.
```

This commit adds the `build-essential` package to the list of apt
packages to install, which allows the example above to build
successfully.

Signed-off-by: Nick Miller <nick@golioth.io>
@CLAassistant
Copy link

CLAassistant commented Feb 15, 2023

CLA assistant check
All committers have signed the CLA.

@espressif-bot espressif-bot added the Status: Opened Issue is new label Feb 15, 2023
@github-actions github-actions bot changed the title tools: Docker: install build-essential apt package tools: Docker: install build-essential apt package (IDFGH-9402) Feb 15, 2023
@Alvin1Zhang
Copy link
Collaborator

Thanks for your contribution.

@espressif-bot espressif-bot added Status: Selected for Development Issue is selected for development Status: In Progress Work is in progress and removed Status: Opened Issue is new Status: Selected for Development Issue is selected for development labels Feb 20, 2023
@dobairoland
Copy link
Collaborator

sha=97c00c7f5be79fa09461cb965647e1a3035aeffd

@dobairoland dobairoland added the PR-Sync-Merge Pull request sync as merge commit label Feb 21, 2023
@espressif-bot espressif-bot added Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally Resolution: Done Issue is done internally and removed Resolution: NA Issue resolution is unavailable labels Mar 2, 2023
@dobairoland
Copy link
Collaborator

JFYI, we have added this package under the condition that one doesn't set IDF_INSTALL_TARGETS to a specific chip target which rules out the support for the linux target. This will be closed when the commit is pushed to the master branch.

Thank you for letting us know about this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR-Sync-Merge Pull request sync as merge commit Resolution: Done Issue is done internally Status: Done Issue is done internally Status: In Progress Work is in progress
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants