2017-06-20 3 views
0

J'ai ghc-8.0.1 et llvm-3.7.0 tous les deux 64bit. Je suis en train d'installer 'texte' paquet comme ceci:Impossible de créer un paquet 'text' avec le backend llvm

cabal install text-1.2.2.2 --ghc-options="-fllvm -pgmlo opt -pgmlc llc -optlc-O4 -v -keep-llvm-files -keep-tmp-files" 

Il échoue avec le message suivant:

fichier
*** Assembler: 
"C:\Program Files\Haskell Platform\8.0.1\lib/../mingw/bin/gcc.exe" "-fno-stack-protector" "-DTABLES_NEXT_TO_CODE" "-I.\Data\Text" "-Idist/dist-sandbox-a883bd5e\build" "-Idist/dist-sandbox-a883bd5e\build" "-Idist/dist-sandbox-a883bd5e\build\autogen" "-Idist/dist-sandbox-a883bd5e\build" "-Iinclude" "-IC:\Program Files\Haskell Platform\8.0.1\mingw\include" "-x" "assembler" "-c" "C:\Users\alex\AppData\Local\Temp\ghc7728_0\ghc_190.s" "-o" "dist/dist-sandbox-a883bd5e\build\Data\Text\Read.o" 
C:\Users\alex\AppData\Local\Temp\ghc7728_0\ghc_190.s: Assembler messages: 
C:\Users\alex\AppData\Local\Temp\ghc7728_0\ghc_190.s:29453: Error: junk at end of line, first unrecognized character is `,' 
C:\Users\alex\AppData\Local\Temp\ghc7728_0\ghc_190.s:29490: Error: junk at end of line, first unrecognized character is `,' 
C:\Users\alex\AppData\Local\Temp\ghc7728_0\ghc_190.s:29539: Error: junk at end of line, first unrecognized character is `,' 
`gcc.exe' failed in phase `Assembler'. (Exit code: 1) 
cabal: Leaving directory 'C:\Users\alex\AppData\Local\Temp\cabal-tmp-9212\text-1.2.2.2' 
cabal: Error: some packages failed to install: 
text-1.2.2.2 failed during the building phase. The exception was: 
ExitFailure 1 

et C:\Users\alex\AppData\Local\Temp\ghc7728_0\ghc_190.s contient:

29453 près de la ligne:

29442: c4pto_info$def: 
29443: # BB#0:         # %c4pto 
29444:  movsd %xmm1, 32(%rbp) 
29445:  addq $8, %rbp 
29446:  rex64 jmp c4ppb_entry$def # TAILCALL 
29447: 
29448:  .def  c4prM_info$def; 
29449:  .scl 3; 
29450:  .type 32; 
29451:  .endef 
29452:  .globl [email protected] 
29453:  .section .rdata,"dr",discard,[email protected] 
29454:  .align 8 
29455: [email protected]: 
29456:  .quad 4621819117588971520  # double 10 
29457:  .text 
29458:  .align 16, 0x90 
29459:  .quad (S470B_srt$def-c4prM_info$def)+1024 # @"c4prM_info$def" 
29460:  .quad 1925     # 0x785 
29461:  .quad 4294967328    # 0x100000020 
29462: c4prM_info$def: 

près de la ligne 29490:

29479: .LBB697_4:        # %u4pwu 
29480:  addq $48, %rbp 
29481:  movq textzm1zi2zi2zi2zm9RlRQEEESJb1LT1TjepTtH_DataziTextziRead_zdszc1_closure$def(%rip), %rax 
29482:  movl $textzm1zi2zi2zi2zm9RlRQEEESJb1LT1TjepTtH_DataziTextziRead_zdszc1_closure$def, %ebx 
29483:  rex64 jmpq *%rax   # TAILCALL 
29484: 
29485:  .def  c4psR_info$def; 
29486:  .scl 3; 
29487:  .type 32; 
29488:  .endef 
29489:  .globl [email protected] 
29490:  .section .rdata,"dr",discard,[email protected] 
29491:  .align 16 
29492: [email protected]: 
29493:  .quad -9223372036854775808 # 0x8000000000000000 
29494:  .quad -9223372036854775808 # 0x8000000000000000 
29495:  .text 
29496:  .align 16, 0x90 
29497:  .quad 1925     # @"c4psR_info$def" 
29498:           # 0x785 
29499:  .quad 32      # 0x20 
29500: c4psR_info$def: 

près de la ligne 29539:

29521: .LBB698_4:        # %c4ptk 
29522:  movq $ghczmprim_GHCziTuple_Z2T_con_info, 24(%rax) 
29523:  leaq -47(%r12), %rdx 
29524:  movq %rdx, 32(%rax) 
29525:  movq %rcx, 40(%rax) 
29526:  movq $base_DataziEither_Right_con_info, 48(%rax) 
29527:  leaq -31(%r12), %rcx 
29528:  movq %rcx, 56(%rax) 
29529:  movq 48(%rbp), %rax 
29530:  addq $48, %rbp 
29531:  leaq -6(%r12), %rbx 
29532:  rex64 jmpq *%rax   # TAILCALL 
29533:  
29534:  .def  c4ps8_info$def; 
29535:  .scl 3; 
29536:  .type 32; 
29537:  .endef 
29538:  .globl [email protected] 
29539:  .section .rdata,"dr",discard,[email protected] 
29540:  .align 8 
29541: [email protected]: 
29542:  .quad 4607182418800017408  # double 1 
29543:  .text 
29544:  .align 16, 0x90 
29545:  .quad 1925     # @"c4ps8_info$def" 
29546:           # 0x785 
29547:  .quad 32      # 0x20 
29548: c4ps8_info$def: 

J'ai installé d'autres paquets avec backend LLVM, jusqu'à présent que 'texte' échoue.

Répondre

0

Sur un système OS-X à l'aide LLVM 3.7 et 8.0.2 GHC, j'ai pu (dans un répertoire temporaire):

cabal sandbox init 
cabal install text-1.2.2.2 --ghc-options="-fllvm -pgmlo opt -pgmlc llc -optlc-O4 -v -keep-llvm-files -keep-tmp-files" 

Ce qui a donné le texte significatif se terminant par:

... 
Created temporary directory: /var/folders/0x/hlxcgy9n5714ryp0gkn5hkmm0000gp/T/ghc6374_0 
*** C Compiler: 
/usr/bin/gcc -m64 -fno-stack-protector -DTABLES_NEXT_TO_CODE -x c /var/folders/0x/hlxcgy9n5714ryp0gkn5hkmm0000gp/T/16807282475249.c -o /var/f 
olders/0x/hlxcgy9n5714ryp0gkn5hkmm0000gp/T/ghc6374_0/ghc_1.s -fno-common -U__PIC__ -D__PIC__ -Wimplicit -S '-D__GLASGOW_HASKELL__=800' -inclu 
de /usr/local/lib/ghc-8.0.2/include/ghcversion.h -I/usr/local/lib/ghc-8.0.2/base-4.9.1.0/include -I/usr/local/lib/ghc-8.0.2/integer-gmp-1.0.0 
.1/include -I/usr/local/lib/ghc-8.0.2/include 
*** Clang (Assembler): 
clang -m64 -fno-stack-protector -DTABLES_NEXT_TO_CODE -fno-common -U__PIC__ -D__PIC__ -Qunused-arguments -x assembler -c /var/folders/0x/hlxc 
gy9n5714ryp0gkn5hkmm0000gp/T/ghc6374_0/ghc_1.s -o /var/folders/0x/hlxcgy9n5714ryp0gkn5hkmm0000gp/T/1622650073984943658.o 
Resolving dependencies... 
Notice: installing into a sandbox located at /private/tmp/x/.cabal-sandbox 
Configuring text-1.2.2.2... 
Building text-1.2.2.2... 
Installed text-1.2.2.2 
cabal install text-1.2.2.2 218.77s user 8.27s system 98% cpu 3:49.67 total 

Bref, c'est un problème de plateforme/outillage non reproductible (par moi-même). Je vous suggère d'essayer GHC 8.0.2 puisque 8.0.1 est, eh bien, moindre. Il pourrait également être intéressant de jeter un coup d'œil sur les bogues spécifiques à Windows sur le trac GHC.