Skip to content

CMake: add nuvoton targets #13922

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

Merged
merged 5 commits into from
Nov 27, 2020
Merged

CMake: add nuvoton targets #13922

merged 5 commits into from
Nov 27, 2020

Conversation

0xc0170
Copy link
Contributor

@0xc0170 0xc0170 commented Nov 18, 2020

Summary of changes

Adding NUVOTON targets.

Note, there are some hex files. I added them as sources but I need more help to understand how they should be processed. I could not quickly find some references in Readme files in their directories or in the old tools.

We do not yet support TFM.

Impact of changes

Migration actions required

Documentation


Pull request type

[x] Patch update (Bug fix / Target update / Docs update / Test update / Refactor)
[] Feature update (New feature / Functionality change / New API)
[] Major update (Breaking change E.g. Return code change / API behaviour change)

Test results

[] No Tests required for this change (E.g docs only update)
[x] Covered by existing mbed-os tests (Greentea or Unittest)
[] Tests / results supplied as part of this PR

Reviewers


@ciarmcom ciarmcom added the release-type: patch Indentifies a PR as containing just a patch label Nov 18, 2020
@ciarmcom ciarmcom requested review from a team November 18, 2020 15:30
@ciarmcom
Copy link
Member

@0xc0170, thank you for your changes.
@ARMmbed/team-nuvoton @ARMmbed/mbed-os-maintainers please review.


if("NUMAKER_IOT_M252" IN_LIST MBED_TARGET_LABELS)
add_subdirectory(TARGET_NUMAKER_IOT_M252)
endif()
Copy link
Contributor

Choose a reason for hiding this comment

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

Should be NUMAKER_IOT_M263A

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed

@cyliangtw
Copy link
Contributor

@0xc0170 , About some hex files in TARGET_M2351, it's the pre-built secure image, such like as some loader binary files.
So please ignore it in CMake.

set(LINKER_FILE device/TOOLCHAIN_GCC_ARM/TARGET_NU_XRAM_SUPPORTED/NUC472.sct)
elseif("NU_XRAM_UNSUPPORTED" IN_LIST MBED_TARGET_LABELS)
set(LINKER_FILE device/TOOLCHAIN_GCC_ARM/TARGET_NU_XRAM_UNSUPPORTED/NUC472.sct)
endif()
Copy link
Contributor

@ccli8 ccli8 Nov 19, 2020

Choose a reason for hiding this comment

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

Should be TOOLCHAIN_ARM_STD

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed

@0xc0170
Copy link
Contributor Author

0xc0170 commented Nov 19, 2020

Thank you for review, I'll remove .hex files from CMake for now - if there is a folder with only .hex files, I won't add CMake.

I'll also fix the comments and let you know once updated.

@0xc0170
Copy link
Contributor Author

0xc0170 commented Nov 20, 2020

@cyliangtw @ccli8 updated.
I remove CMakeLists from mbed-os/targets/TARGET_NUVOTON/TARGET_M2351 where are hex files. Please review

set(LINKER_FILE device/TOOLCHAIN_GCC_ARM/M251.ld)
elseif(${MBED_TOOLCHAIN} STREQUAL "ARM")
set(LINKER_FILE device/TOOLCHAIN_ARM_STD/M251.sct)
endif()
Copy link
Contributor

Choose a reason for hiding this comment

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

Also support IAR linker file, such like as ?

elseif(${MBED_TOOLCHAIN} STREQUAL "IAR")
    set(LINKER_FILE device/TOOLCHAIN_IAR/M251.icf)
endif()

Copy link
Contributor Author

Choose a reason for hiding this comment

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

we do not support IAR with CMake , thus we do not port it neither. If IAR is supported, we will need to add targets support (will be done via separate PRs).

@0xc0170
Copy link
Contributor Author

0xc0170 commented Nov 24, 2020

I requested additional review, meanwhile started CI

@mbed-ci
Copy link

mbed-ci commented Nov 24, 2020

Jenkins CI Test : ✔️ SUCCESS

Build Number: 1 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_dynamic-memory-usage ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️
jenkins-ci/mbed-os-ci_cloud-client-pytest ✔️

@0xc0170
Copy link
Contributor Author

0xc0170 commented Nov 25, 2020

One more fix needed, .sct files need updating the comment for preprocessor. I'll fix now

@0xc0170
Copy link
Contributor Author

0xc0170 commented Nov 25, 2020

CI started

ARMClang fixed

@mbed-ci
Copy link

mbed-ci commented Nov 25, 2020

Jenkins CI Test : ❌ FAILED

Build Number: 2 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_dynamic-memory-usage ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️
jenkins-ci/mbed-os-ci_cloud-client-pytest

@0xc0170
Copy link
Contributor Author

0xc0170 commented Nov 25, 2020

CI restarted

@mbed-ci
Copy link

mbed-ci commented Nov 25, 2020

Jenkins CI Test : ❌ FAILED

Build Number: 3 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_dynamic-memory-usage ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️
jenkins-ci/mbed-os-ci_cloud-client-pytest

@mbed-ci
Copy link

mbed-ci commented Nov 26, 2020

Jenkins CI Test : ✔️ SUCCESS

Build Number: 4 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_dynamic-memory-usage ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️
jenkins-ci/mbed-os-ci_cloud-client-pytest ✔️

@0xc0170 0xc0170 merged commit 28eeee2 into ARMmbed:master Nov 27, 2020
@0xc0170 0xc0170 deleted the cmake-nuvoton branch November 27, 2020 11:03
@mergify mergify bot removed the ready for merge label Nov 27, 2020
@mbedmain mbedmain added release-version: 6.6.0 Release-pending and removed release-type: patch Indentifies a PR as containing just a patch Release-pending labels Dec 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants