[GHC] #13301: GHC base directory assumptions

#13301: GHC base directory assumptions ----------------------------------------+--------------------------------- Reporter: Phyx- | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.2 Keywords: | Operating System: Windows Architecture: Unknown/Multiple | Type of failure: None/Unknown Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: ----------------------------------------+--------------------------------- GHC and ghc-pkg make some pretty hard assumptions about where they're running on Windows. They assume that they are always running from `foo/bin/ghc.exe` and that to find the `lib` folder they can drop `bin/ghc.exe` from the base path and append `lib`. This is already false for the testsuite, which when testing the bindist has one test which puts the binaries in `inplace/test spaces`. For some reason before this was either being skipped or mysteriously passing. But as of `2017.02.11` our luck ran out. the testsuite triggers a failure such as: {{{ [04:16:21][Step 3/6] ghc-pkg.exe: Can't find package database in C:/TeamCity/buildAgent/work/28754042a1be6052/inplace/test sp\lib [04:16:22][Step 3/6] ghc-pkg.exe: Can't find package database in C:/TeamCity/buildAgent/work/28754042a1be6052/inplace/test sp\lib [04:16:23][Step 3/6] Traceback (most recent call last): [04:16:23][Step 3/6] File "../../driver/runtests.py", line 215, in <module> [04:16:23][Step 3/6] pkginfo = str(getStdout([config.ghc_pkg, 'dump'])) [04:16:23][Step 3/6] File "/c/TeamCity/buildAgent/work/28754042a1be6052/testsuite/driver/testutil.py", line 23, in getStdout [04:16:23][Step 3/6] raise Exception("Command failed: " + str(cmd_and_args)) [04:16:23][Step 3/6] Exception: Command failed: ['"/c/TeamCity/buildAgent/work/28754042a1be6052/inplace/test spaces/ghc- pkg.exe"', 'dump'] [04:16:23][Step 3/6] make: *** [../../mk/test.mk:299: test] Error 1 [04:16:23][Step 3/6] [04:16:23][Step 3/6] ==== STAGE 1 TESTS ==== [04:16:23][Step 3/6] cat: testsuite_summary_stage1.txt: No such file or directory [04:16:23][Step 3/6] Process exited with code 1 }}} Let's soften the assumption and just check that `../lib` exists instead. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13301 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13301: GHC base directory assumptions ---------------------------------+---------------------------------------- Reporter: Phyx- | Owner: Phyx- Type: bug | Status: new Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.2 Resolution: | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D3158 Wiki Page: | ---------------------------------+---------------------------------------- Changes (by Phyx-): * owner: (none) => Phyx- * differential: => Phab:D3158 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13301#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13301: GHC base directory assumptions ---------------------------------+---------------------------------------- Reporter: Phyx- | Owner: Phyx- Type: bug | Status: patch Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.2 Resolution: | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D3158 Wiki Page: | ---------------------------------+---------------------------------------- Changes (by Phyx-): * status: new => patch -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13301#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13301: GHC base directory assumptions ---------------------------------+---------------------------------------- Reporter: Phyx- | Owner: Phyx- Type: bug | Status: patch Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.2 Resolution: | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D3158 Wiki Page: | ---------------------------------+---------------------------------------- Comment (by bgamari): Oops, the commit mentioned the wrong ticket, In [changeset:"8d64395b43cb73d110767cab512a368b3db018de/ghc" 8d64395/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="8d64395b43cb73d110767cab512a368b3db018de" Correct Windows libdir assumptions. GHC and ghc-pkg make some pretty hard assumptions about where they're running on Windows. They assume that they are always running from `foo/bin/ghc.exe` and that to find the `lib` folder they can drop `bin/ghc.exe` from the base path and append `lib`. This is already false for the testsuite, which when testing thenbindist has one test which puts the binaries in `inplace/test spaces`. For some reason before this was either being skipped or mysteriously passing. But as of `2017.02.11` our luck ran out. the testsuite triggers a failure such as those in #13310 Let's soften the assumption and just check that `../lib` exists instead. 80 chars Test Plan: ./validate Reviewers: austin, erikd, bgamari Reviewed By: bgamari Subscribers: thomie, #ghc_windows_task_force Differential Revision: https://phabricator.haskell.org/D3158 }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13301#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13301: GHC base directory assumptions ---------------------------------+---------------------------------------- Reporter: Phyx- | Owner: Phyx- Type: bug | Status: closed Priority: normal | Milestone: 8.2.1 Component: Compiler | Version: 8.0.2 Resolution: fixed | Keywords: Operating System: Windows | Architecture: Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D3158 Wiki Page: | ---------------------------------+---------------------------------------- Changes (by bgamari): * status: patch => closed * resolution: => fixed * milestone: 8.4.1 => 8.2.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13301#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC