Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TemplateHaskell/profiling and TemplateHaskell/dynamic fail #1207

Closed
bmillwood opened this issue Feb 17, 2013 · 1 comment · Fixed by #1251
Closed

TemplateHaskell/profiling and TemplateHaskell/dynamic fail #1207

bmillwood opened this issue Feb 17, 2013 · 1 comment · Fixed by #1251

Comments

@bmillwood
Copy link
Contributor

Actually, three test cases fail for me, but one I know why it is – see #1206 . These are the other two, which I don't understand. The test log is as follows:

Test suite package-tests: RUNNING...
Cabal test suite - testing cabal version 1.17.0
BuildDeps/SameDepsAllRound:
  : [OK]
BuildDeps/InternalLibrary0:
  : [OK]
PreProcess:
  : [OK]
TestStanza:
  : [OK]
TestSuiteExeV10/Test:
  : [OK]
TestSuiteExeV10/TestWithHpc:
  : [Failed]
expected: 'setup test' should succeed
  output: "/home/ben/haskell/cabal/Cabal/tests/Setup test" in PackageTests/TestSuiteExeV10
Running 1 test suites...
Test suite test-Foo: RUNNING...
Test suite test-Foo: PASS
Test suite logged to: dist/test/my-0.1-test-Foo.log
Warning: Your version of HPC (0.6) does not properly handle multiple search
paths. Coverage report generation may fail unexpectedly. These issues are
addressed in version 0.7 or later (GHC 7.8 or later). The following search
paths have been abandoned: ["dist/hpc/mix/my-0.1"]
hpc: can not find my-0.1/Foo in ["./dist/hpc/mix/test-Foo"]

TestOptions:
  : [OK]
BenchmarkStanza:
  : [OK]
BenchmarkExeV10/Test:
  : [OK]
BenchmarkOptions:
  : [OK]
TemplateHaskell/profiling:
  : [Failed]
expected: 'setup build' should succeed
  output: "/home/ben/haskell/cabal/Cabal/tests/Setup configure --user -w ghc --enable-library-profiling --enable-executable-profiling" in PackageTests/TemplateHaskell/profiling
Configuring templateHaskell-0.1...

"/home/ben/haskell/cabal/Cabal/tests/Setup build -v" in PackageTests/TemplateHaskell/profiling
Component build order: library, executable 'main'
creating dist/build
creating dist/build/autogen
Building templateHaskell-0.1...
Preprocessing library templateHaskell-0.1...
Building library...
'/usr/local/bin/ghc' '--info'
creating dist/build
'/usr/local/bin/ghc' '--make' '-fbuilding-cabal-package' '-O' '-static' '-odir' 'dist/build' '-hidir' 'dist/build' '-stubdir' 'dist/build' '-i' '-idist/build' '-i.' '-idist/build/autogen' '-Idist/build/autogen' '-Idist/build' '-optP-include' '-optPdist/build/autogen/cabal_macros.h' '-package-name' 'templateHaskell-0.1' '-hide-all-packages' '-package-db' 'dist/package.conf.inplace' '-package-id' 'base-4.6.0.1-5cb691aa2f6d3760b9c6e0f050ec5716' '-package-id' 'template-haskell-2.8.0.0-62b331739753ccf905ede7eaac4b9b09' '-XHaskell98' '-XTemplateHaskell' 'Lib' 'TH'
[1 of 2] Compiling TH               ( TH.hs, dist/build/TH.o )
[2 of 2] Compiling Lib              ( Lib.hs, dist/build/Lib.o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array-0.4.0.1 ... linking ... done.
Loading package deepseq-1.3.0.1 ... linking ... done.
Loading package containers-0.5.0.0 ... linking ... done.
Loading package pretty-1.1.1.0 ... linking ... done.
Loading package template-haskell ... linking ... done.
'/usr/local/bin/ghc' '--make' '-fbuilding-cabal-package' '-O' '-prof' '-static' '-osuf' 'p_o' '-hisuf' 'p_hi' '-odir' 'dist/build' '-hidir' 'dist/build' '-stubdir' 'dist/build' '-i' '-idist/build' '-i.' '-idist/build/autogen' '-Idist/build/autogen' '-Idist/build' '-optP-include' '-optPdist/build/autogen/cabal_macros.h' '-package-name' 'templateHaskell-0.1' '-hide-all-packages' '-package-db' 'dist/package.conf.inplace' '-package-id' 'base-4.6.0.1-5cb691aa2f6d3760b9c6e0f050ec5716' '-package-id' 'template-haskell-2.8.0.0-62b331739753ccf905ede7eaac4b9b09' '-XHaskell98' '-XTemplateHaskell' 'Lib' 'TH'
[1 of 2] Compiling TH               ( TH.hs, dist/build/TH.p_o )
[2 of 2] Compiling Lib              ( Lib.hs, dist/build/Lib.p_o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array-0.4.0.1 ... linking ... done.
Loading package deepseq-1.3.0.1 ... linking ... done.
Loading package containers-0.5.0.0 ... linking ... done.
Loading package pretty-1.1.1.0 ... linking ... done.
Loading package template-haskell ... linking ... done.
Linking...
'/usr/bin/ar' '-r' 'dist/build/libHStemplateHaskell-0.1.a' 'dist/build/Lib.o' 'dist/build/TH.o'
/usr/bin/ar: creating dist/build/libHStemplateHaskell-0.1.a
'/usr/bin/ar' '-r' 'dist/build/libHStemplateHaskell-0.1_p.a' 'dist/build/Lib.p_o' 'dist/build/TH.p_o'
/usr/bin/ar: creating dist/build/libHStemplateHaskell-0.1_p.a
In-place registering templateHaskell-0.1...
'/usr/local/bin/ghc-pkg' 'update' '-' '--global' '--user' '--package-db=dist/package.conf.inplace'
Preprocessing executable 'main' for templateHaskell-0.1...
Building executable main...
creating dist/build/main
creating dist/build/main/main-tmp
'/usr/local/bin/ghc' '--make' '-no-link' '-fbuilding-cabal-package' '-O' '-prof' '-static' '-osuf' 'p_o' '-hisuf' 'p_hi' '-odir' 'dist/build/main/main-tmp' '-hidir' 'dist/build/main/main-tmp' '-stubdir' 'dist/build/main/main-tmp' '-i' '-idist/build/main/main-tmp' '-i.' '-idist/build/autogen' '-Idist/build/autogen' '-Idist/build/main/main-tmp' '-optP-include' '-optPdist/build/autogen/cabal_macros.h' '-hide-all-packages' '-package-db' 'dist/package.conf.inplace' '-package-id' 'base-4.6.0.1-5cb691aa2f6d3760b9c6e0f050ec5716' '-package-id' 'template-haskell-2.8.0.0-62b331739753ccf905ede7eaac4b9b09' '-XHaskell98' '-XTemplateHaskell' './Exe.hs'
[1 of 2] Compiling TH               ( TH.hs, dist/build/main/main-tmp/TH.p_o )
[2 of 2] Compiling Main             ( Exe.hs, dist/build/main/main-tmp/Main.p_o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array-0.4.0.1 ... linking ... done.
Loading package deepseq-1.3.0.1 ... linking ... done.
Loading package containers-0.5.0.0 ... linking ... done.
Loading package pretty-1.1.1.0 ... linking ... done.
Loading package template-haskell ... linking ... done.
Exe.hs:6:16:
    cannot find normal object file `dist/build/main/main-tmp/TH.o'
    while linking an interpreted expression

TemplateHaskell/dynamic:
  : [Failed]
expected: 'setup build' should succeed
  output: "/home/ben/haskell/cabal/Cabal/tests/Setup configure --user -w ghc --enable-shared --enable-executable-dynamic" in PackageTests/TemplateHaskell/dynamic
Configuring templateHaskell-0.1...

"/home/ben/haskell/cabal/Cabal/tests/Setup build -v" in PackageTests/TemplateHaskell/dynamic
Component build order: library, executable 'main'
creating dist/build
creating dist/build/autogen
Building templateHaskell-0.1...
Preprocessing library templateHaskell-0.1...
Building library...
'/usr/local/bin/ghc' '--info'
creating dist/build
'/usr/local/bin/ghc' '--make' '-fbuilding-cabal-package' '-O' '-static' '-odir' 'dist/build' '-hidir' 'dist/build' '-stubdir' 'dist/build' '-i' '-idist/build' '-i.' '-idist/build/autogen' '-Idist/build/autogen' '-Idist/build' '-optP-include' '-optPdist/build/autogen/cabal_macros.h' '-package-name' 'templateHaskell-0.1' '-hide-all-packages' '-package-db' 'dist/package.conf.inplace' '-package-id' 'base-4.6.0.1-5cb691aa2f6d3760b9c6e0f050ec5716' '-package-id' 'template-haskell-2.8.0.0-62b331739753ccf905ede7eaac4b9b09' '-XHaskell98' '-XTemplateHaskell' 'Lib' 'TH'
[1 of 2] Compiling TH               ( TH.hs, dist/build/TH.o )
[2 of 2] Compiling Lib              ( Lib.hs, dist/build/Lib.o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array-0.4.0.1 ... linking ... done.
Loading package deepseq-1.3.0.1 ... linking ... done.
Loading package containers-0.5.0.0 ... linking ... done.
Loading package pretty-1.1.1.0 ... linking ... done.
Loading package template-haskell ... linking ... done.
'/usr/local/bin/ghc' '--make' '-fbuilding-cabal-package' '-O' '-dynamic' '-fPIC' '-osuf' 'dyn_o' '-hisuf' 'dyn_hi' '-odir' 'dist/build' '-hidir' 'dist/build' '-stubdir' 'dist/build' '-i' '-idist/build' '-i.' '-idist/build/autogen' '-Idist/build/autogen' '-Idist/build' '-optP-include' '-optPdist/build/autogen/cabal_macros.h' '-package-name' 'templateHaskell-0.1' '-hide-all-packages' '-package-db' 'dist/package.conf.inplace' '-package-id' 'base-4.6.0.1-5cb691aa2f6d3760b9c6e0f050ec5716' '-package-id' 'template-haskell-2.8.0.0-62b331739753ccf905ede7eaac4b9b09' '-XHaskell98' '-XTemplateHaskell' 'Lib' 'TH'
[1 of 2] Compiling TH               ( TH.hs, dist/build/TH.dyn_o )
[2 of 2] Compiling Lib              ( Lib.hs, dist/build/Lib.dyn_o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array-0.4.0.1 ... linking ... done.
Loading package deepseq-1.3.0.1 ... linking ... done.
Loading package containers-0.5.0.0 ... linking ... done.
Loading package pretty-1.1.1.0 ... linking ... done.
Loading package template-haskell ... linking ... done.
Linking...
'/usr/bin/ar' '-r' 'dist/build/libHStemplateHaskell-0.1.a' 'dist/build/Lib.o' 'dist/build/TH.o'
/usr/bin/ar: creating dist/build/libHStemplateHaskell-0.1.a
'/usr/local/bin/ghc' '-shared' '-dynamic' '-package-name' 'templateHaskell-0.1' '-no-auto-link-packages' '-package-db' 'dist/package.conf.inplace' '-package-id' 'base-4.6.0.1-5cb691aa2f6d3760b9c6e0f050ec5716' '-package-id' 'template-haskell-2.8.0.0-62b331739753ccf905ede7eaac4b9b09' 'dist/build/Lib.dyn_o' 'dist/build/TH.dyn_o' '-o' 'dist/build/libHStemplateHaskell-0.1-ghc7.6.2.so'
In-place registering templateHaskell-0.1...
'/usr/local/bin/ghc-pkg' 'update' '-' '--global' '--user' '--package-db=dist/package.conf.inplace'
Preprocessing executable 'main' for templateHaskell-0.1...
Building executable main...
creating dist/build/main
creating dist/build/main/main-tmp
'/usr/local/bin/ghc' '--make' '-no-link' '-fbuilding-cabal-package' '-O' '-dynamic' '-osuf' 'dyn_o' '-hisuf' 'dyn_hi' '-odir' 'dist/build/main/main-tmp' '-hidir' 'dist/build/main/main-tmp' '-stubdir' 'dist/build/main/main-tmp' '-i' '-idist/build/main/main-tmp' '-i.' '-idist/build/autogen' '-Idist/build/autogen' '-Idist/build/main/main-tmp' '-optP-include' '-optPdist/build/autogen/cabal_macros.h' '-hide-all-packages' '-package-db' 'dist/package.conf.inplace' '-package-id' 'base-4.6.0.1-5cb691aa2f6d3760b9c6e0f050ec5716' '-package-id' 'template-haskell-2.8.0.0-62b331739753ccf905ede7eaac4b9b09' '-XHaskell98' '-XTemplateHaskell' './Exe.hs'
[1 of 2] Compiling TH               ( TH.hs, dist/build/main/main-tmp/TH.dyn_o )
[2 of 2] Compiling Main             ( Exe.hs, dist/build/main/main-tmp/Main.dyn_o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array-0.4.0.1 ... linking ... done.
Loading package deepseq-1.3.0.1 ... linking ... done.
Loading package containers-0.5.0.0 ... linking ... done.
Loading package pretty-1.1.1.0 ... linking ... done.
Loading package template-haskell ... linking ... done.
Exe.hs:6:16:
    cannot find normal object file `dist/build/main/main-tmp/TH.o'
    while linking an interpreted expression

PathsModule/Executable:
  : [OK]
PathsModule/Library:
  : [OK]
BuildDeps/TargetSpecificDeps1:
  : [OK]
BuildDeps/TargetSpecificDeps2:
  : [OK]
BuildDeps/TargetSpecificDeps3:
  : [OK]
BuildDeps/InternalLibrary1:
  : [OK]
BuildDeps/InternalLibrary2:
  : [OK]
BuildDeps/InternalLibrary3:
  : [OK]
BuildDeps/InternalLibrary4:
  : [OK]
PackageTests/CMain:
  : [OK]

         Test Cases   Total       
 Passed  19           19          
 Failed  3            3           
 Total   22           22          
Test suite package-tests: FAIL
Test suite logged to: dist/test/Cabal-1.17.0-package-tests.log
@bmillwood
Copy link
Contributor Author

I notice that Cabal/tests/PackageTests/TemplateHaskell/profiling/my.cabal seems to be missing TH from other-modules on the executable. But re-adding it seems to have no effect.

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 a pull request may close this issue.

1 participant