Liam Healy | 4 May 2012 05:01
Picon

Cannot load cffi-tests

I cannot load cffi-tests (from the master branch).  I am on Ubuntu 11.10 amd64.  I can't even make sense of what the error is; it can't compile libtest.c?

Liam

This is SBCL 1.0.51.34-43a5265, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://www.sbcl.org/>.

SBCL is free software, provided as is, with absolutely no warranty.
It is mostly in the public domain; some portions are provided under
BSD-style licenses.  See the CREDITS and COPYING files in the
distribution for more information.
CL-USER(1): (ql:quickload "cffi-tests")
To load "cffi-tests":
  Load 1 ASDF system:
    cffi-tests
; Loading "cffi-tests"
..................................................
[package cffi-features]
debugger invoked on a ASDF:OPERATION-ERROR in thread #<THREAD
                                                       "initial thread" RUNNING
                                                        {1002F81371}>:
  Error while invoking #<COMPILE-OP (:VERBOSE NIL) {1003900621}> on
  #<C-TEST-LIB "cffi-tests" "tests" "libtest">

Type HELP for debugger help, or (SB-EXT:QUIT) to exit from SBCL.

restarts (invokable by number or by possibly-abbreviated name):
  0: [RETRY ] Retry compiling #<C-TEST-LIB "cffi-tests" "tests" "libtest">.
  1: [ACCEPT] Continue, treating
              compiling #<C-TEST-LIB "cffi-tests" "tests" "libtest"> as having
              been successful.
  2: [ABORT ] Give up on "cffi-tests"
  3:          Exit debugger, returning to top level.

((SB-PCL::FAST-METHOD ASDF:PERFORM
  (ASDF:COMPILE-OP CFFI-TESTS-SYSTEM::C-TEST-LIB))
 #<unavailable argument>
 #<unavailable argument>
 #<ASDF:COMPILE-OP (:VERBOSE NIL) {1003900621}>
 #<CFFI-TESTS-SYSTEM::C-TEST-LIB "cffi-tests" "tests" "libtest">)
0] :ba

0: ((SB-PCL::FAST-METHOD ASDF:PERFORM
     (ASDF:COMPILE-OP CFFI-TESTS-SYSTEM::C-TEST-LIB))
    #<unavailable argument>
    #<unavailable argument>
    #<ASDF:COMPILE-OP (:VERBOSE NIL) {1003900621}>
    #<CFFI-TESTS-SYSTEM::C-TEST-LIB "cffi-tests" "tests" "libtest">)
1: ((SB-PCL::EMF ASDF:PERFORM)
    #<unavailable argument>
    #<unavailable argument>
    #<ASDF:COMPILE-OP (:VERBOSE NIL) {1003900621}>
    #<CFFI-TESTS-SYSTEM::C-TEST-LIB "cffi-tests" "tests" "libtest">)
2: ((LAMBDA ()))
3: ((FLET SB-THREAD::WITH-RECURSIVE-LOCK-THUNK))
4: ((FLET #:WITHOUT-INTERRUPTS-BODY-[CALL-WITH-RECURSIVE-LOCK]333))
5: (SB-THREAD::CALL-WITH-RECURSIVE-LOCK
    #<CLOSURE (FLET SB-THREAD::WITH-RECURSIVE-LOCK-THUNK) {7FFFF69AEC09}>
    #<SB-THREAD:MUTEX "World Lock"
        owner: #<SB-THREAD:THREAD "initial thread" RUNNING {1002F81371}>>)
6: ((FLET SB-C::WITH-IT))
7: ((SB-PCL::FAST-METHOD ASDF::PERFORM-PLAN (LIST))
    #<unused argument>
    #<unused argument>
    ((#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "package">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "definitions">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "binding">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "strings">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "conditions">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "hash-tables">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "symbols">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "macros">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "functions">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "lists">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "io">)
     (#<ASDF:LOAD-OP (:VERBOSE NIL) {10041368E1}>
      . #<ASDF:CL-SOURCE-FILE "alexandria" "control-flow">)
     ...))
8: ((LAMBDA ()))
9: (ASDF::CALL-WITH-SYSTEM-DEFINITIONS #<CLOSURE (LAMBDA #) {10038DFA29}>)
10: ((SB-PCL::FAST-METHOD ASDF:OPERATE (T T))
     #<unused argument>
     #<unused argument>
     ASDF:LOAD-OP
     "cffi-tests"
     :VERBOSE
     NIL)
11: ((SB-PCL::EMF ASDF:OPERATE)
     #<unused argument>
     #<unused argument>
     ASDF:LOAD-OP
     "cffi-tests"
     :VERBOSE
     NIL)
12: (QUICKLISP-CLIENT::CALL-WITH-MACROEXPAND-PROGRESS
     #<CLOSURE (LAMBDA #) {10038DF939}>)
13: (QUICKLISP-CLIENT::AUTOLOAD-SYSTEM-AND-DEPENDENCIES
     "cffi-tests"
     :PROMPT
     NIL)
14: ((SB-PCL::FAST-METHOD QL-IMPL-UTIL::%CALL-WITH-QUIET-COMPILATION (T T))
     #<unavailable argument>
     #<unavailable argument>
     #<unavailable argument>
     #<CLOSURE (FLET QUICKLISP-CLIENT::QL) {10033AD129}>)
15: ((SB-PCL::FAST-METHOD QL-IMPL-UTIL::%CALL-WITH-QUIET-COMPILATION :AROUND
      (QL-IMPL:SBCL T))
     #<unavailable argument>
     #S(SB-PCL::FAST-METHOD-CALL
        :FUNCTION #<FUNCTION #>
        :PV NIL
        :NEXT-METHOD-CALL NIL
        :ARG-INFO (2))
     #<QL-IMPL:SBCL {10005F8BB1}>
     #<CLOSURE (FLET QUICKLISP-CLIENT::QL) {10033AD129}>)
16: ((SB-PCL::FAST-METHOD QUICKLISP-CLIENT:QUICKLOAD (T))
     #<unused argument>
     #<unused argument>
     #<unavailable argument>
     :PROMPT
     NIL
     :VERBOSE
     NIL)
17: (QL-DIST::CALL-WITH-CONSISTENT-DISTS #<CLOSURE (LAMBDA #) {1003394369}>)
18: (SB-INT:SIMPLE-EVAL-IN-LEXENV
     (QUICKLISP-CLIENT:QUICKLOAD "cffi-tests")
     #<NULL-LEXENV>)
19: (EVAL (QUICKLISP-CLIENT:QUICKLOAD "cffi-tests"))
20: (INTERACTIVE-EVAL (QUICKLISP-CLIENT:QUICKLOAD "cffi-tests") :EVAL NIL)
21: (SB-ACLREPL::REP-ONE)
22: (SB-ACLREPL::REPL :BREAK-LEVEL 0 :NOPRINT NIL :INSPECT NIL :CONTINUABLE NIL)
23: ((LAMBDA (SB-ACLREPL::NOPRINT)) NIL)
24: ((LAMBDA ()))
25: (SB-IMPL::%WITH-REBOUND-IO-SYNTAX #<CLOSURE (LAMBDA #) {10032B0079}>)
26: (SB-IMPL::TOPLEVEL-REPL NIL)
27: (SB-IMPL::TOPLEVEL-INIT)
28: ((FLET #:WITHOUT-INTERRUPTS-BODY-[RESTART-LISP]38))
29: ((LABELS SB-IMPL::RESTART-LISP))

0]

_______________________________________________
cffi-devel mailing list
cffi-devel <at> common-lisp.net
http://lists.common-lisp.net/cgi-bin/mailman/listinfo/cffi-devel
Luís Oliveira | 4 May 2012 11:03
Picon
Gravatar

Re: Cannot load cffi-tests

On Fri, May 4, 2012 at 4:01 AM, Liam Healy <lnp <at> healy.washington.dc.us> wrote:
> I cannot load cffi-tests (from the master branch).  I am on Ubuntu 11.10 amd64.  I can't even make sense
of what the error is; it can't compile libtest.c?

(asdf:load-system :cffi-tests :verbose t) should give you more
information. Alternatively, cd into to tests/ and run make.

Cheers,

--
Luís Oliveira
http://r42.eu/~luis/
Liam Healy | 4 May 2012 15:02
Picon

Re: Cannot load cffi-tests

On Fri, May 4, 2012 at 5:03 AM, Luís Oliveira <luismbo <at> gmail.com> wrote:
On Fri, May 4, 2012 at 4:01 AM, Liam Healy <lnp <at> healy.washington.dc.us> wrote:
> I cannot load cffi-tests (from the master branch).  I am on Ubuntu 11.10 amd64.  I can't even make sense of what the error is; it can't compile libtest.c?

(asdf:load-system :cffi-tests :verbose t) should give you more
information. Alternatively, cd into to tests/ and run make.

Thanks Luis.

 This is SBCL 1.0.53.76-0dda509, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://www.sbcl.org/>.

SBCL is free software, provided as is, with absolutely no warranty.
It is mostly in the public domain; some portions are provided under
BSD-style licenses.  See the CREDITS and COPYING files in the
distribution for more information.
CL-USER(1): (asdf:load-system :cffi-tests :verbose t) 

; Loading system definition from /home/healy/languages/lisp/cffi/cffi-tests.asd
; into #<PACKAGE "ASDF0">
; Registering #<SYSTEM "cffi-tests">
; Loading system definition from
; /home/healy/languages/lisp/quicklisp/dists/quicklisp/software/rt-20101006-git/rt.asd
; into #<PACKAGE "ASDF0">
; Registering #<SYSTEM "rt">
; Loading system definition from
; /home/healy/languages/lisp/quicklisp/dists/quicklisp/software/bordeaux-threads-0.8.1/bordeaux-threads.asd
; into #<PACKAGE "ASDF0">
; Registering #<SYSTEM "bordeaux-threads">
; Loading system definition from /home/healy/languages/lisp/cffi/cffi.asd into
; #<PACKAGE "ASDF0">
; Registering #<SYSTEM "cffi">
; Loading system definition from
; /home/healy/languages/lisp/quicklisp/dists/quicklisp/software/babel-20110730-git/babel.asd
; into #<PACKAGE "ASDF0">
; Registering #<SYSTEM "babel">
; $ cd /home/healy/languages/lisp/cffi/tests/; make
gcc -m32 -o libtest32.so -shared -Wall -std=c99 -pedantic libtest.c
In file included from /usr/include/features.h:378,
                 from /usr/include/stdio.h:28,
                 from libtest.c:34:
/usr/include/gnu/stubs.h:7:27: error: gnu/stubs-32.h: No such file or directory
make: [libtest32.so] Error 1 (ignored)
gcc -m32 -o libtest2_32.so -shared -Wall -std=c99 -pedantic libtest2.c
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.4.5/libgcc.a when searching for -lgcc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.4.5/libgcc.a when searching for -lgcc
/usr/bin/ld: cannot find -lgcc
collect2: ld returned 1 exit status
make: *** [libtest2_32.so] Error 1

debugger invoked on a ASDF:OPERATION-ERROR in thread #<THREAD
                                                       "initial thread" RUNNING
                                                        {10046491F3}>:
  Error while invoking #<COMPILE-OP (:VERBOSE T) {1006316F83}> on
  #<C-TEST-LIB "cffi-tests" "tests" "libtest">

Type HELP for debugger help, or (SB-EXT:QUIT) to exit from SBCL.

restarts (invokable by number or by possibly-abbreviated name):
  0: [RETRY ] Retry compiling #<C-TEST-LIB "cffi-tests" "tests" "libtest">.
  1: [ACCEPT] Continue, treating
              compiling #<C-TEST-LIB "cffi-tests" "tests" "libtest"> as having
              been successful.
  2: [ABORT ] Exit debugger, returning to top level.

((SB-PCL::FAST-METHOD ASDF:PERFORM
  (ASDF:COMPILE-OP CFFI-TESTS-SYSTEM::C-TEST-LIB))
 #<unavailable argument>
 #<unavailable argument>
 #<ASDF:COMPILE-OP (:VERBOSE T) {1006316F83}>
 #<CFFI-TESTS-SYSTEM::C-TEST-LIB "cffi-tests" "tests" "libtest">)
0] 


I guess this is trying to build a 32-bit version on a 64-bit OS?   (I'm at work now, 64 bit Debian squeeze, but same error as the Ubuntu laptop.)

Liam
_______________________________________________
cffi-devel mailing list
cffi-devel <at> common-lisp.net
http://lists.common-lisp.net/cgi-bin/mailman/listinfo/cffi-devel
Luís Oliveira | 4 May 2012 15:47
Picon
Gravatar

Re: Cannot load cffi-tests

On Fri, May 4, 2012 at 2:02 PM, Liam Healy <lnp <at> healy.washington.dc.us> wrote:
> I guess this is trying to build a 32-bit version on a 64-bit OS?   (I'm at
> work now, 64 bit Debian squeeze, but same error as the Ubuntu laptop.)

Yes, the Makefile attempts to cross-compile a 32-bit version. However,
it should be optional. And in fact, as you can see in the error
message, make ignores the failure to compile libtest32.so. I've pushed
a fix to make it do the same for libtest2_32.so and libfsbv_32.so.

Cheers,

--

-- 
Luís Oliveira
http://r42.eu/~luis/

Gmane