Open
Conversation
use path to refer to project without cd saves us from cd errors later
a445a2b to
36d0ef4
Compare
it's easier to build and view in a separate script no functional changes
macOS 13 images have been officially turned off by GitHub actions/runner-images#13046
flag should work by itself; is not expecting a value the current version works fine on a local command line, but not in the cloud when parsed through 'make'
We don't want any PRs trying to sign themselves as an official, merged Mesen build but they would all fail anyway because PRs don't have access to the signing keys (only the main repo has that, after PRs are merged)
more flexible if the path changes
some mac builds are passing with the new find command, but others are failing bc of the `UNAME` value ``` (clang, macos-14, arm64) works: >Found app at: bin/osx-arm64/Release/osx-arm64/publish/Mesen.app (clang_aot, macos-14, arm64) works: >Found app at: bin/osx-arm64/Release/osx-arm64/publish/Mesen.app (clang, macos-14, x64) failed: >find: bin/osx-x64: No such file or directory (clang_aot, macos-14, x64) failed: >find: bin/osx-x64: No such file or directory ``` add a make test so we can see what is happening and fix/enforce it currently: ``` Checking Makefile architecture detection logic... ------------------------------------------------ Input: Linux-x86_64 | Expected Platform: linux-x64 | Expected Arch Flag: -m64 Input: Linux-aarch64 | Expected Platform: linux-arm64 | Expected Arch Flag: Input: Darwin-x86_64 | Expected Platform: osx-x64 | Expected Arch Flag: -m64 Input: Darwin-arm64 | Expected Platform: osx-arm64 | Expected Arch Flag: -m64 Input: Darwin-aarch64 | Expected Platform: osx-arm64 | Expected Arch Flag: -m64 ------------------------------------------------ ``` Right now this just prints them. need to refactor the makefile a bit to actually test it that will be in the next commit
use ?= for setting uname and machine, so we can test our own makefile now it gives: ``` $ make test-all-configs Validating makefile architecture detection: ---------------------------------------------------------------------------------------------------------- INPUT | EXPECTED (PLAT/FLAGS) | ACTUAL (PLAT/FLAGS) | RESULT ---------------------------------------------------------------------------------------------------------- Linux-x86_64 | linux-x64 -m64 | linux-x64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS Darwin-x86_64 | osx-x64 -m64 | osx-x64 -m64 | PASS Darwin-arm64 | osx-arm64 -m64 | osx-arm64 -m64 | PASS Darwin-aarch64 | osx-arm64 -m64 | osx-arm64 -m64 | PASS ---------------------------------------------------------------------------------------------------------- ``` manual test: I can prove this works by changing any of the `MESENPLATFORM :=` lines e.g. `MESENPLATFORM := $(MESENOS)-bad!` gives ``` ---------------------------------------------------------------------------------------------------------- INPUT | EXPECTED (PLAT/FLAGS) | ACTUAL (PLAT/FLAGS) | RESULT ---------------------------------------------------------------------------------------------------------- Linux-x86_64 | linux-x64 -m64 | linux-bad! -m64 | FAIL ```
1. verify-all-env: you can run this in your shell to test and check that the current Makefile logic works or not ``` ---------------------------------------------------------------------------------------------------------- INPUT | EXPECTED (PLAT/FLAGS) | ACTUAL (PLAT/FLAGS) | RESULT ---------------------------------------------------------------------------------------------------------- Linux-x86_64 | linux-x64 -m64 | linux-x64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS Darwin-x86_64 | osx-x64 -m64 | osx-x64 -m64 | PASS Darwin-arm64 | osx-arm64 -m64 | osx-arm64 -m64 | PASS Darwin-aarch64 | osx-arm64 -m64 | osx-arm64 -m64 | PASS ---------------------------------------------------------------------------------------------------------- ``` I can manually test and verify: if I change a `MESENPLATFORM` line, it breaks and prints `FAIL` instead ``` Linux-x86_64 | linux-x64 -m64 | linux-x64-bad! -m64 | FAIL ``` 2. verify-env: we will hook this up in the build.yml shortly so we can prove that we are doing the right thing in the build
test what we are actually building on
the tests now correctly detect this failure happening on macos ``` ---------------------------------------------------------------------------------------------------------- INPUT | EXPECTED (PLAT/FLAGS) | ACTUAL (PLAT/FLAGS) | RESULT ---------------------------------------------------------------------------------------------------------- Linux-x86_64 | linux-x64 -m64 | linux-x64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS Darwin-x86_64 | osx-x64 -m64 | osx-x64 -m64 | PASS Darwin-arm64 | osx-arm64 -m64 | osx-arm64 -m64 | PASS Linux-x86_64 | linux-arm64 | linux-x64 -m64 | FAIL make[1]: *** [makefile:309: test-env-row] Error 1 Darwin-arm64 | osx-x64 -m64 | osx-arm64 -m64 | FAIL make[1]: *** [makefile:309: test-env-row] Error 1 Linux-x86_64 | linux-arm64 | linux-x64 -m64 | FAIL make[1]: *** [makefile:309: test-env-row] Error 1 ---------------------------------------------------------------------------------------------------------- ```
with this change, the tests now pass ``` ---------------------------------------------------------------------------------------------------------- INPUT | EXPECTED (PLAT/FLAGS) | ACTUAL (PLAT/FLAGS) | RESULT ---------------------------------------------------------------------------------------------------------- Linux-x86_64 | linux-x64 -m64 | linux-x64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS Darwin-x86_64 | osx-x64 -m64 | osx-x64 -m64 | PASS Darwin-arm64 | osx-arm64 -m64 | osx-arm64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS Darwin-x86_64 | osx-x64 -m64 | osx-x64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS ---------------------------------------------------------------------------------------------------------- Verification Complete. All tests PASSED. ```
keep all of the args for each test in the same order, so it is easier to visually see: UNAME MARCHINE E_PLAT ARCH makefiles are already ugly enough. do what we can to keep it clean verify-env still passes: ``` make verify-all-env Validating Makefile Architecture Detection Logic: ---------------------------------------------------------------------------------------------------------- INPUT | EXPECTED (PLAT/FLAGS) | ACTUAL (PLAT/FLAGS) | RESULT ---------------------------------------------------------------------------------------------------------- Linux-x86_64 | linux-x64 -m64 | linux-x64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS Darwin-x86_64 | osx-x64 -m64 | osx-x64 -m64 | PASS Darwin-arm64 | osx-arm64 -m64 | osx-arm64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS Darwin-x86_64 | osx-x64 -m64 | osx-x64 -m64 | PASS Linux-aarch64 | linux-arm64 | linux-arm64 | PASS ---------------------------------------------------------------------------------------------------------- ``
the new tests now pass
don't try to do fancy sub-folder guessing. if we get an architecture env wrong or make a mistake, it fails to zip. just search in the main directory and let the 'find' command handle it
currently both macos (clang_aot, macos-14, x64) macos (clang, macos-14, x64) try to use the same artifact name. this causes a failure. add the compiler type so they are distinct
36d0ef4 to
c4fe530
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
current master branch on commit fabc9a6 - cloud builds are failing.
fix them so they pass again.