Skip to content

Conversation

angerman
Copy link

@angerman angerman commented Sep 4, 2025

No description provided.

@angerman angerman requested a review from hasufell September 4, 2025 00:38
@angerman angerman self-assigned this Sep 4, 2025
@angerman angerman force-pushed the ci-dynamic-matrix-and-rename branch from 4de99d0 to 23dd6fa Compare September 4, 2025 00:50
@angerman
Copy link
Author

angerman commented Sep 4, 2025

Interestingly, this now seems to fail due to the missing rts sublib issues. That are fixed in #44. Specifically this:

#44 (comment)

@angerman
Copy link
Author

angerman commented Sep 4, 2025

Fixes #51 and #52

@angerman angerman force-pushed the ci-dynamic-matrix-and-rename branch 3 times, most recently from dabc558 to bbb815a Compare September 4, 2025 12:46
@angerman angerman force-pushed the stable-ghc-9.14 branch 4 times, most recently from d9f06c2 to a1edbb5 Compare September 5, 2025 07:32
@angerman angerman force-pushed the ci-dynamic-matrix-and-rename branch 2 times, most recently from 7c8212f to e74ec54 Compare September 11, 2025 06:05
Ideally, ghc should just be able to produce this data outright, without having to resort to a separate tool. This seems highly
questionable.  It would be much better if ghc should emitted
this information in a structured way.
This seems conceptually wrong. I don't fully understand why we need this?
@angerman angerman force-pushed the ci-dynamic-matrix-and-rename branch from b78b210 to 1967f08 Compare September 17, 2025 03:20
@angerman angerman changed the base branch from stable-ghc-9.14 to stable-ghc-9.14-rebased September 17, 2025 08:28
Comment on lines +263 to +274
sanitized_hc := $(subst $(space),_,$(subst :,_,$(subst /,_,$(subst \,_,$(TEST_HC)))))
test_hc_hash := $(shell \
if command -v openssl >/dev/null 2>&1; then \
openssl dgst -sha256 $(TEST_HC) | awk '{print substr($$2, 1, 8)}'; \
elif command -v sha256sum >/dev/null 2>&1; then \
sha256sum $(TEST_HC) | awk '{print substr($$1, 1, 8)}'; \
elif command -v shasum >/dev/null 2>&1; then \
shasum -a 256 $(TEST_HC) | awk '{print substr($$1, 1, 8)}'; \
else \
echo "no_hash"; \
fi)
ghc_config_mk = $(TOP)/mk/$(test_hc_hash)_ghcconfig$(sanitized_hc).mk
Copy link
Author

Choose a reason for hiding this comment

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

I should add a comment here why we do this. It adds a has to the ghc config file. This ensure we always read the correct ghcconfig, if the ghc changed, the hash changed, and we recompute.


visibility: public

ghc-options: -optc-DRtsWay="v"
Copy link
Author

Choose a reason for hiding this comment

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

Julian has "rts_v" and others in #75 for this.

(NoArg (setGeneralFlag Opt_NoHsMain))
, make_ord_flag defGhcFlag "no-rts"
(NoArg (setGeneralFlag Opt_NoRts))
, make_ord_flag defGhcFlag "no-ghc-internal"
Copy link

Choose a reason for hiding this comment

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

Why is this needed now?

Copy link
Author

Choose a reason for hiding this comment

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

We have the following dependeny as visible to cabal:

ghc-internal
+ rts

however, ghc will try to insert:

ghc-internal
+ rts-sublib (based on the -threaded / -debug flag)
  + rts

If we try to build the rts-sublib with ghc, we can end up trying to load ghc-internal, due to auto-injection of libraries.

Maybe a better solution is to add a flag to outright disable ghc's auto population of libs, instead of having separate ones for each lib 😅

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.

2 participants