DemesneGH opened a new pull request, #244: URL: https://github.com/apache/teaclave-trustzone-sdk/pull/244
This PR reorganizes the **Makefiles** under `examples/`. Currently, we have **26 examples** (and more in the future). Updating each example's Makefile individually makes maintenance and review difficult. Since most Makefile logic is shared, this PR centralizes common definitions under `examples/mk/`: * `examples-root.mk` * `host.mk` — for CAs and plugins * `common-ta.mk` * `std-ta.mk` * `no-std-ta.mk` The Makefiles design is suitable for this directory layout of each example: ``` example/ ├── host/ │ ├── host1/ │ │ └── Makefile # includes host.mk │ └── host2/ │ └── Makefile ├── plugin/ # example with one plugin app, can be multiple apps like in the host/ │ ├── src/ │ └── Makefile # includes host.mk ├── ta/ │ ├── ta1/ │ │ └── Makefile # includes common-ta.mk or std-ta.mk or no-std-ta.mk │ └── ta2/ │ └── Makefile ├── Makefile # includes examples-root.mk └── uuid.txt # TA UUID ``` Our all examples are fit for this structure: Most of examples have one host and one TA; Some examples (e.g., `supp_plugin-rs`, `mnist-rs`) override certain variables (such as location of `uuid.txt`) to fit specific needs. The Makefile variables are designed to be easily overridden for such cases. Please pay special attention when reviewing the `examples/mk/*`, `supp_plugin-rs` and `mnist-rs`. #### Future Work This is the first step in cleaning up and unifying our Makefile structure. With this reorganization, future Makefile updates can be made more consistently and reviewed more easily. In the dev docker environment, the `examples/mk` path can be written as a constant include path used by each separate examples. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
