Skip to content

Commit

Permalink
Fix RTS report of host arch/os for the testsuite
Browse files Browse the repository at this point in the history
  • Loading branch information
hsyl20 committed Feb 17, 2025
1 parent 643072e commit d1ccf00
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 15 deletions.
12 changes: 4 additions & 8 deletions Build.hs
Original file line number Diff line number Diff line change
Expand Up @@ -460,18 +460,14 @@ buildBootLibraries cabal ghc ghcpkg derive_constants genapply genprimop opts dst
[ "package rts"
, def_string "ProjectVersion" (Text.unpack (gboVersionInt opts))
, def_string "RtsWay" "FIXME"
, def_string "HostPlatform" "FIXME"
, def_string "HostArch" "FIXME"
, def_string "HostOS" "FIXME"
, def_string "HostVendor" "FIXME"
, def_string "HostPlatform" "x86_64-unknown-linux" -- FIXME
, def_string "HostArch" "x86_64" -- FIXME: appropriate value required for the tests
, def_string "HostOS" "linux" -- FIXME: appropriate value required for the tests
, def_string "HostVendor" "unknown"
, def_string "BuildPlatform" "FIXME"
, def_string "BuildArch" "FIXME"
, def_string "BuildOS" "FIXME"
, def_string "BuildVendor" "FIXME"
, def_string "TargetPlatform" "FIXME"
, def_string "TargetArch" "FIXME"
, def_string "TargetOS" "FIXME"
, def_string "TargetVendor" "FIXME"
, def_string "GhcUnregisterised" "FIXME"
, def_string "TablesNextToCode" "FIXME"
-- Set the namespace for the rts fs functions
Expand Down
4 changes: 0 additions & 4 deletions rts/RtsUtils.c
Original file line number Diff line number Diff line change
Expand Up @@ -372,10 +372,6 @@ void printRtsInfo(const RtsConfig rts_config) {
mkRtsInfoPair("Host architecture", HostArch);
mkRtsInfoPair("Host OS", HostOS);
mkRtsInfoPair("Host vendor", HostVendor);
mkRtsInfoPair("Target platform", TargetPlatform);
mkRtsInfoPair("Target architecture", TargetArch);
mkRtsInfoPair("Target OS", TargetOS);
mkRtsInfoPair("Target vendor", TargetVendor);
mkRtsInfoPair("Word size", TOSTRING(WORD_SIZE_IN_BITS));
// TODO(@Ericson2314) This is a joint property of the RTS and generated
// code. The compiler will soon be multi-target so it doesn't make sense to
Expand Down
6 changes: 3 additions & 3 deletions testsuite/ghc-config/ghc-config.hs
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ main = do
let fields = read info :: [(String,String)]
getGhcFieldOrFail fields "HostOS" "Host OS"
getGhcFieldOrFail fields "WORDSIZE" "Word size"
getGhcFieldOrFail fields "TARGETPLATFORM" "Target platform"
getGhcFieldOrFail fields "TargetOS_CPP" "Target OS"
getGhcFieldOrFail fields "TargetARCH_CPP" "Target architecture"
getGhcFieldOrFail fields "TARGETPLATFORM" "Host platform"
getGhcFieldOrFail fields "TargetOS_CPP" "Host OS"
getGhcFieldOrFail fields "TargetARCH_CPP" "Host architecture"
getGhcFieldOrFail fields "RTSWay" "RTS way"

info <- readProcess ghc ["--info"] ""
Expand Down

0 comments on commit d1ccf00

Please sign in to comment.