Skip to content

change: add initial source/build structure#3

Merged
erhankur merged 1 commit intoespressif:masterfrom
erhankur:add_initial_structure
Apr 10, 2025
Merged

change: add initial source/build structure#3
erhankur merged 1 commit intoespressif:masterfrom
erhankur:add_initial_structure

Conversation

@erhankur
Copy link
Collaborator

@erhankur erhankur commented Apr 8, 2025

Description

Suggested directory structure, example project and GH build workflow added to the repository.

image

Library Structure:

  • Core library functionality kept independent of target-specific settings
  • No toolchain or linker configurations at library level
  • Clean separation between library interface and implementation

Example Project:

  • Complete build configuration demonstrates including:
    • Target-specific toolchain settings
    • Custom linker scripts for each target
    • Memory layout configurations
  • Build configuration kept at project level for flexibility
  • Basic stub implementation demonstrates library usage
  • Support for all targets

Build System Architecture:

  • Linker scripts maintained in example/linker/
  • Toolchain configuration in example/cmake/
  • Project-level CMake controls all target-specific settings
  • Library remains target-agnostic

Testing

Verified builds for all targets using latest toolchain (esp-14.2.0_20241119) from the IDF


Checklist

Before submitting a Pull Request, please ensure the following:

  • 🚨 This PR does not introduce breaking changes.
  • All CI checks (GH Actions) pass.
  • Documentation is updated as needed.
  • Tests are updated or added as necessary.
  • Code is well-commented, especially in complex areas.
  • Git history is clean — commits are squashed to the minimum necessary.

@github-actions
Copy link

github-actions bot commented Apr 8, 2025

Messages
📖 This PR seems to be quite large (total lines of code: 13299), you might consider splitting it into smaller PRs

👋 Hello erhankur, we appreciate your contribution to this project!


Click to see more instructions ...


This automated output is generated by the PR linter DangerJS, which checks if your Pull Request meets the project's requirements and helps you fix potential issues.

DangerJS is triggered with each push event to a Pull Request and modify the contents of this comment.

Please consider the following:
- Danger mainly focuses on the PR structure and formatting and can't understand the meaning behind your code or changes.
- Danger is not a substitute for human code reviews; it's still important to request a code review from your colleagues.
- Addressing info messages (📖) is strongly recommended; they're less critical but valuable.
- To manually retry these Danger checks, please navigate to the Actions tab and re-run last Danger workflow.

Review and merge process you can expect ...


We do welcome contributions in the form of bug reports, feature requests and pull requests.

1. An internal issue has been created for the PR, we assign it to the relevant engineer.
2. They review the PR and either approve it or ask you for changes or clarifications.
3. Once the GitHub PR is approved we do the final review, collect approvals from core owners and make sure all the automated tests are passing.
- At this point we may do some adjustments to the proposed change, or extend it by adding tests or documentation.
4. If the change is approved and passes the tests it is merged into the default branch.

Generated by 🚫 dangerJS against 01250fa

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 85 out of 102 changed files in this pull request and generated no comments.

Files not reviewed (17)
  • CMakeLists.txt: Language not supported
  • example/CMakeLists.txt: Language not supported
  • example/build.sh: Language not supported
  • example/cmake/build-flags.cmake: Language not supported
  • example/cmake/riscv-gcc-toolchain.cmake: Language not supported
  • example/cmake/util.cmake: Language not supported
  • example/cmake/xtensa-gcc-toolchain.cmake: Language not supported
  • example/linker/common.ld: Language not supported
  • example/linker/esp32.ld: Language not supported
  • example/linker/esp32c2.ld: Language not supported
  • example/linker/esp32c3.ld: Language not supported
  • example/linker/esp32c5.ld: Language not supported
  • example/linker/esp32c6.ld: Language not supported
  • example/linker/esp32c61.ld: Language not supported
  • example/linker/esp32h2.ld: Language not supported
  • example/linker/esp32p4.ld: Language not supported
  • example/linker/esp32s2.ld: Language not supported
Comments suppressed due to low confidence (1)

README.md:16

  • The target name 'ESP32-C61' appears ambiguous given the presence of 'ESP32-C6'. Confirm whether 'ESP32-C61' is intentional or a typo.
+- ESP32-C61

Copy link
Collaborator

@dobairoland dobairoland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Nice work!

@dobairoland
Copy link
Collaborator

Thanks for the accepting my suggestions. I'll be away till Easter. Please feel free to merge this without me.

@erhankur erhankur force-pushed the add_initial_structure branch from 8fa96a0 to 79d7bc0 Compare April 9, 2025 07:00
@erhankur
Copy link
Collaborator Author

erhankur commented Apr 9, 2025

@dobairoland thanks for your comments. I will wait 1-2 days for others to review. Then we are good to merge.

@erhankur erhankur force-pushed the add_initial_structure branch 2 times, most recently from 7702511 to e97c5c2 Compare April 9, 2025 11:15
@antmak
Copy link
Collaborator

antmak commented Apr 9, 2025

I liked you added an perfect example and liked stub_target_xxx-related code structure, thanks!

@erhankur erhankur force-pushed the add_initial_structure branch from e97c5c2 to 01250fa Compare April 10, 2025 06:54
@erhankur
Copy link
Collaborator Author

@antmak thank you for your review and comment.

@erhankur erhankur merged commit e8ff7a0 into espressif:master Apr 10, 2025
13 checks passed
@erhankur erhankur deleted the add_initial_structure branch April 14, 2025 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants