Skip to content

Add support of Zephyr OS#4692

Open
anobli wants to merge 2 commits into
google:mainfrom
anobli:abailon/zephyr/dev
Open

Add support of Zephyr OS#4692
anobli wants to merge 2 commits into
google:mainfrom
anobli:abailon/zephyr/dev

Conversation

@anobli

@anobli anobli commented Jan 8, 2025

Copy link
Copy Markdown

This updates googletest in order to use it with Zephyr.
The first patch update gtest itself to support Zephyr OS it self.
The second adds files used by Zephyr build system. If this is not acceptable, then I will drop it and find another way to integrate it to zephyr build system.

@google-cla

google-cla Bot commented Jan 8, 2025

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Comment thread modules/googletest/CMakeLists.txt Outdated
@anobli anobli force-pushed the abailon/zephyr/dev branch 3 times, most recently from c767d2d to 53e0458 Compare February 10, 2025 15:22
@anobli anobli requested a review from dkaszews February 10, 2025 15:26
Comment thread googletest/src/gtest_main.cc Outdated
@anobli anobli force-pushed the abailon/zephyr/dev branch 2 times, most recently from ef017e6 to 8e3886a Compare February 11, 2025 08:50
@anobli anobli requested a review from dkaszews February 11, 2025 08:50
@dkaszews

Copy link
Copy Markdown

What little I can review and understand looks good to me

@jeffwelder-ellenbytech

Copy link
Copy Markdown

+1

This is fantastic, and works great out of the box.
Attached is how I pulled it into my zephyr project.

manifest:
  remotes:
    - name: zephyrproject-rtos
      url-base: https://github.com/zephyrproject-rtos
    - name: anobli
      url-base: https://github.com/anobli

  projects:
    - name: googletest
      remote: anobli
      repo-path: googletest
      revision: 8e3886acac2e6058f4f540269f43b1f4a2700adc
    - name: zephyr
      remote: zephyrproject-rtos
      revision: v4.1.0
      import:
        name-blocklist:
          - hal_altera
          - hal_cypress
          - hal_infineon
          - hal_microchip
          - hal_nxp
          - hal_openisa
          - hal_silabs
          - hal_xtensa
          - hal_ti
          - loramac-node
          - ci-tools
          - edtt
          - sof
          - matter
  self:
    path: application

@awojasinski

Copy link
Copy Markdown

+1

@dkaszews can you merge it?

@dkaszews

dkaszews commented Aug 6, 2025

Copy link
Copy Markdown

@awojasinski I'm not a maintainer, I just reviewed it because I'd like to see it merged myself

@markus-schmailzl-bsh

Copy link
Copy Markdown

We are also really interested in the change. But we have the problem that the main zephyr thread is still running when the tests are executed. Does anybody else have this issue?

@thorsten-klein

thorsten-klein commented Dec 8, 2025

Copy link
Copy Markdown

Any updates on this? When will this be merged?

@anobli

anobli commented Dec 15, 2025

Copy link
Copy Markdown
Author

We are also really interested in the change. But we have the problem that the main zephyr thread is still running when the tests are executed. Does anybody else have this issue?

Could you elaborate more about the issue you are getting ?

@anobli anobli force-pushed the abailon/zephyr/dev branch 5 times, most recently from 4fc5516 to 810173c Compare April 1, 2026 05:16
@anobli anobli force-pushed the abailon/zephyr/dev branch 2 times, most recently from ad58b0b to 6e35d5a Compare May 21, 2026 06:42
@anobli anobli force-pushed the abailon/zephyr/dev branch 3 times, most recently from fbbab9d to 3ae17db Compare May 31, 2026 06:50
@anobli anobli force-pushed the abailon/zephyr/dev branch from 3ae17db to d6eb9ff Compare June 3, 2026 08:06
@anobli anobli force-pushed the abailon/zephyr/dev branch 3 times, most recently from 5893d41 to 35e39ad Compare June 22, 2026 08:48
@anobli anobli force-pushed the abailon/zephyr/dev branch from 35e39ad to 68b0379 Compare June 24, 2026 06:36
anobli added 2 commits June 30, 2026 06:46
Although Zephyr has it own test suite, it doesn't work well with C++.
gtest and gmock seem more adapted.
This adds support of Zephyr OS in order to test C++ libraries and
applications.

Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
This update googletest to use it as Zephyr OS external module.
This allows downloading, configure and building googltest using
Zephyr west build system, without any user manipulation.

Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
@anobli anobli force-pushed the abailon/zephyr/dev branch from 68b0379 to 618862a Compare June 30, 2026 06:46
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.

6 participants