Loading...
 

Zephyr project on STM32

   Zephyr Workbench, a VSCode extension to manage Zephyr on STM32.
It enables users to easily create, develop, and debug Zephyr applications.
Main features:
  • Install host dependencies.
  • Import toolchain and SDK.
  • Create, configure, build and manage apps.
  • Debug STM32.
You can directly download it from the VSCode marketplace
For more details, visit the Zephyr Workbench

System Workbench for STM32


Generated makefile does not include all folders

Using the latest version of System Workbench and creating a static library. The library does not show any errors. When the library gets built, referencing what I thought would be a file showed an error. After poking around, I found out the makefile that was generated did not include all the files.

The tree of the src directory is:
.
├── Boot
├── Coapt.h
├── debug
├── Engine
├── EventHandler
│   ├── EventHandler.c
│   └── EventHandler.h
├── Init
└── IODevices
└── IODeviceInterface.h

At the beginning of the makefile in Debug:

  1. All of the sources participating in the build are defined here

-include sources.mk
-include src/EventHandler/subdir.mk
-include subdir.mk
-include objects.mk

And the contents of sources.mk:
O_SRCS :=
C_SRCS :=
S_SRCS :=
S_UPPER_SRCS :=
OBJ_SRCS :=
ASM_SRCS :=
OBJS :=
C_DEPS :=
ARCHIVES :=
S_UPPER_DEPS :=

  1. Every subdirectory with source files must be described here

SUBDIRS := \
src/EventHandler \

Anyone have any idea why the subdirectories are left out?

I tried to add the src directory as an include path and nothing changed. Poked through and tried adding the src directory to any include path I could find to no avail. It seems like it thinks the main directory is the EventHandler directory and I cannot seem to change it.

So the fix is that the static library only builds and archives *.c and *.h pairs. I didn’t know that happened so if you run into this issue, you know what to do.

I fiddled with various settings several times to get it to index lonesome header files but none of the combinations work for me. Not sure if this is intended or this is a bug. Anyone have insight?


 

Newest Forum Posts

  1. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-25 07:37
  2. SPI on Nucleo_STMH533RE by royjamil, 2025-03-23 11:31
  3. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-23 09:33
  4. Configuring DMA for ADC in SW? by sam.hodgson, 2025-03-04 12:58
  5. Build a project in "release" mode by info@creosrl.it, 2025-02-20 18:12
  6. Build a project in "release" mode by info@creosrl.it, 2025-02-20 17:05
  7. Build a project in "release" mode by tang, 2025-02-20 10:36
  8. Build a project in "release" mode by info@creosrl.it, 2025-02-19 17:35
  9. Fail to debug in Win 11 C/C++ by mortenlund, 2024-12-26 20:27
  10. Fail to debug in Win 11 C/C++ by mortenlund, 2024-12-18 20:48

Last-Modified Blogs