Skip to content
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

recipes-openamp: get rpmsg apps from new repo #22

Closed
wants to merge 1 commit into from

Conversation

tnmysh
Copy link
Contributor

@tnmysh tnmysh commented Sep 23, 2022

remove rpmsg-echo-test source files and modify relative recipe to sync code from openamp-system-reference repo

Signed-off-by: Tanmay Shah [email protected]

@tnmysh
Copy link
Contributor Author

tnmysh commented Sep 23, 2022

@wmamills, @edmooring, @arnopo

This change resolves issue: #18
The relative pull request that moves code to openamp-system-reference repo is here: OpenAMP/openamp-system-reference#1

For now, only rpmsg-echo-test is moved. Once everything looks good for this example, I will replicate changes for other two examples.

Copy link

@edmooring edmooring left a comment

Choose a reason for hiding this comment

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

Looks good to me.

@tnmysh
Copy link
Contributor Author

tnmysh commented Sep 29, 2022

@edmooring Thanks for approval. One minor change, we are moving LICENSE file to root directory in openamp-system-reference repo. So, I will have to change LICENSE file location in bitabake script.
I will send new patch soon.

@tnmysh tnmysh marked this pull request as draft September 29, 2022 02:13
@tnmysh tnmysh force-pushed the master_rpmsg_echo_test branch 2 times, most recently from 7d0ede7 to 5d45f79 Compare October 4, 2022 05:24
@tnmysh tnmysh changed the title recipes-openamp: get rpmsg-echo-test demo from new repo recipes-openamp: get rpmsg apps from new repo Oct 4, 2022
@tnmysh tnmysh marked this pull request as ready for review October 4, 2022 05:28
@tnmysh tnmysh requested a review from edmooring October 4, 2022 05:29
@wmamills
Copy link
Collaborator

wmamills commented Oct 6, 2022

Most of this should be factored out of the individual recipes and made an inc file at the rpmsg-examples level.
I don't want to update 3 different places when adjusting the commit id.
Most of the new recipe logic should be there: git url etc. Even the license can be done this way as they all refer to the same file.

The other thing that is strange here is pointing the WORKDIR deep into the repo clone.
This makes the LICENSE file:// URL very strange also.

I will look for a better way to do this.
One obvious answer is build them all with one recipe and then split them into separate packages. However that is a lot of change compared to what we have and may not scale as well.

@mhatle may have other suggestions

@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 6, 2022

Most of this should be factored out of the individual recipes and made an inc file at the rpmsg-examples level. I don't want to update 3 different places when adjusting the commit id. Most of the new recipe logic should be there: git url etc. Even the license can be done this way as they all refer to the same file.

Ack.

The other thing that is strange here is pointing the WORKDIR deep into the repo clone. This makes the LICENSE file:// URL very strange also.

I will look for a better way to do this. One obvious answer is build them all with one recipe and then split them into separate packages. However that is a lot of change compared to what we have and may not scale as well.

Yes correct, we need better way to do this. I tried with making single bb file that compiles all the demos i.e. openamp-system-reference.bb, how ever it needs makefile in root dir. Which I believe wasn't good idea. I agreed with @arnopo and removed Makefile from root dir. So, I had to go all the way to example root dir where Makefile is available.

One solutiont could be, If we agree to keep Makefile in root dir, then we can call different targets from that make file from different recipes. Not sure if it's good idea though.

I definitely look forward to better and clean solution to this.

@mhatle may have other suggestions

@bentheredonethat
Copy link
Collaborator

LGTM

@wmamills
Copy link
Collaborator

wmamills commented Oct 9, 2022

If we go the single makefile route, I would not delete the individual ones. Just add a new one that calls each of the sub makes.

However I am OK to merge 3 recipies and look for a better way over time.
I would still like to cleanup the LICENCE URL. Can ${S} be used in a file:// URL??

@wmamills
Copy link
Collaborator

wmamills commented Oct 9, 2022

BTW: This will need to be rebased now that I have accepted the PRs from May

@wmamills
Copy link
Collaborator

You can use WORKDIR in the LIC_FILES_CHKSUM.
example:
LIC_FILES_CHKSUM = "file://${WORKDIR}/license.html;md5=5c94767cedb5d6987c902ac850ded2c6"
from:
https://docs.yoctoproject.org/current/dev-manual/common-tasks.html#specifying-the-lic-files-chksum-variable

@wmamills
Copy link
Collaborator

Also please change LICENSE to match the new master. "BSD" gives warnings. You need to specify which BSD.

@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 10, 2022

BTW: This will need to be rebased now that I have accepted the PRs from May

Sure I will do that.

@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 10, 2022

You can use WORKDIR in the LIC_FILES_CHKSUM.
example:
LIC_FILES_CHKSUM = "file://${WORKDIR}/license.html;md5=5c94767cedb5d6987c902ac850ded2c6"
from:
https://docs.yoctoproject.org/current/dev-manual/common-tasks.html#specifying-the-lic-files-chksum-variable

This sounds good idea. Thanks.

@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 12, 2022

If we go the single makefile route, I would not delete the individual ones. Just add a new one that calls each of the sub makes.

Actually I see that we may not need single make file, if we can accept that

S = "${WORKDIR}/git/examples/linux/rpmsg-echo-test"

With this Makefile in root dir is not needed for now. We can introduce common Makefile if needed in future.

@wmamills
Copy link
Collaborator

Yes I am OK with that as long as we use ${WORKDIR} in the LIC_FILES_CHKSUM
WIth SRCURI and Licence info factored into an include common to all 3 examples.

@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 12, 2022

Yes I am OK with that as long as we use ${WORKDIR} in the LIC_FILES_CHKSUM
WIth SRCURI and Licence info factored into an include common to all 3 examples.

One more thing. I did make common .inc file which will be included in all of the three .bb files.
However, for that to work, I may have to create single pull request and bring all the demo source files all togather in single commit. Otherwise it may break compilation.

@wmamills
Copy link
Collaborator

This PR is already a single commit. I am OK with it staying that way.

@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 12, 2022

This PR is already a single commit. I am OK with it staying that way.

I am sorry I meant in https://github.com/OpenAMP/openamp-system-reference repository.
Three demos should be available in single commit.

@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 12, 2022

This PR is already a single commit. I am OK with it staying that way.

I am sorry, I wasn't clear. I mean in openamp-system-reference repo: https://github.com/OpenAMP/openamp-system-reference
We need all demos in single commit.

@tnmysh tnmysh force-pushed the master_rpmsg_echo_test branch from 5d45f79 to 4820a9f Compare October 12, 2022 04:28
remove rpmsg-echo-test, rpmsg-mat-mul and rpmsg-proxy-app
source files and modify relative recipe to sync code from
openamp-system-reference repo

Signed-off-by: Tanmay Shah <[email protected]>
@tnmysh tnmysh force-pushed the master_rpmsg_echo_test branch from 4820a9f to ed069e2 Compare October 12, 2022 04:33
@tnmysh
Copy link
Contributor Author

tnmysh commented Oct 12, 2022

This PR is already a single commit. I am OK with it staying that way.

I am sorry, I wasn't clear. I mean in openamp-system-reference repo: https://github.com/OpenAMP/openamp-system-reference We need all demos in single commit.

Discussed this with Bill offline. We don't need such sync between two different repository. So, no need to introduce all application in single commit in openamp-system-reference repository.

@mhatle
Copy link
Collaborator

mhatle commented Nov 9, 2022

I attempted to merge this request and got the following errors:

WARNING: rpmsg-proxy-app-1.0-r0 do_unpack: rpmsg-proxy-app: the directory ${WORKDIR}/git/examples/linux/rpmsg-proxy-app (/scratch2/fray/git/openamp/build-honister/tmp/work/core2-64-poky-linux/rpmsg-proxy-app/1.0-r0/git/examples/linux/rpmsg-proxy-app) pointed to by the S variable doesn't exist - please set S within the recipe to point to where the source has been unpacked to

WARNING: rpmsg-mat-mul-1.0-r0 do_unpack: rpmsg-mat-mul: the directory ${WORKDIR}/git/examples/linux/rpmsg-mat-mul (/scratch2/fray/git/openamp/build-honister/tmp/work/core2-64-poky-linux/rpmsg-mat-mul/1.0-r0/git/examples/linux/rpmsg-mat-mul) pointed to by the S variable doesn't exist - please set S within the recipe to point to where the source has been unpacked to

WARNING: rpmsg-echo-test-1.0-r0 do_unpack: rpmsg-echo-test: the directory ${WORKDIR}/git/examples/linux/rpmsg-echo-test (/scratch2/fray/git/openamp/build-honister/tmp/work/core2-64-poky-linux/rpmsg-echo-test/1.0-r0/git/examples/linux/rpmsg-echo-test) pointed to by the S variable doesn't exist - please set S within the recipe to point to where the source has been unpacked to

S is being set to:

S = "${WORKDIR}/git/examples/linux/rpmsg-echo-test"

The git checkout is empty, so your pull requests to git://github.com/OpenAMP/openamp-system-reference need to be approved before this can be merged.

Finally the SRCREV is set to 'AUTOREV' which will cause the system to pull data from GitHub on EVERY build. Whatever the 1.0 release is, is what the SRCREV should point to. Autorev will cause problems.

@wmamills
Copy link
Collaborator

I have reworded this PR as new PR#28.
I belive I have addressed @mhatle's concerns above.
I am closing this one in favor of that one.

@wmamills wmamills closed this Nov 21, 2022
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.

5 participants