osx-cross / homebrew-arm

Pre-built GNU toolchain from ARM Cortex-M & Cortex-R processors (Cortex-M0/M0+/M3/M4/M7, Cortex-R4/R5/R7).
BSD 2-Clause "Simplified" License
152 stars 21 forks source link

arm-gcc-bin@12: Make keg only. #44

Closed tee3 closed 1 year ago

tee3 commented 1 year ago

This is untested, but seem straightforward.

Does this get automatically tested at some point or should I do more work to validate it?

ladislas commented 1 year ago

You should be able to fix the issues with brew style osx-cross/arm --fix

You can also run the different commands in the CI to make sure everything passes locally before running CI which can be quite long.

tee3 commented 1 year ago

I fixed the style issue and rebased. I ran some of the commands defined for CI, but I couldn't do all of them.

tee3 commented 1 year ago

It looks like it fails in the testing since it expects things to be not key-oniy. I'll see if I can run those tests locally and fix it up.

tee3 commented 1 year ago

I hope I fixed the issues with running the keg-only tests. I have not tested it locally, it requires way too much setup on my system that I do not have the time to do (at least I think it takes a lot, I know it used to require turning your machine into a Homebrew test system). We'll see if it works.

ladislas commented 1 year ago

(at least I think it takes a lot, I know it used to require turning your machine into a Homebrew test system)

No, not much, and it's all automated. The first time your run brew test-bot it will download a few dependencies and do the testing.

Really easy stuff.

and what you really need is brew audit --tap=osx-cross/arm

ladislas commented 1 year ago

Can you make separate PR's, one for each formula. The CI doesn't really like when multiple formulae are changed. It also results in very long build/testing time and everything has to be run from scratch if one formula fails.

Then, in the PR where you use keg_only, I'm not sure you can use prefix as it is not linked. You might need to use opt_prefix

see https://docs.brew.sh/Formula-Cookbook for more info

tee3 commented 1 year ago

I rebased this to be a single recipe and will create separate pull requests for each. I'm going to wait until the two I have open pass before creating the rest.

ladislas commented 1 year ago

I think you forgot to push. I'm still seeing the fix files modified.

tee3 commented 1 year ago

You are right, pushed now.

tee3 commented 1 year ago

What I mean by not easy is that I would have to modify my machine to check a formula. As far as I understand, those commands install a bunch of things in my Homebrew setup. When I've done it in the past, I've had to go back and remove them as I do Homebrew development only rarely.

I might do it on a separate user/machine if this starts taking too long, but this is one of the cases where a GitHub Codespace would be nice to have from the Homebrew folks.

tee3 commented 1 year ago

OK this is getting closer, but I don't want to waste your time with all these build requests. I'll see if I can get a proper development environment set up.

tee3 commented 1 year ago

Actually, I'm guessing if I changed the match string to be Arm GNU Toolchain #{version}, this would succeed.

ladislas commented 1 year ago

OK this is getting closer, but I don't want to waste your time with all these build requests.

no worries :) I'll run CI as soon as I get the notification ;)