Hello,

Compiling Chicken (git/master) under FreeBSD-9.1 stable (r246700) with 
clang-3.2, 'gmake check' stopped with an error near the very end of the test 
run:

======================================== deploym
ent tests
retrieving ...
..
clang rev-app.c -o rev-app.o -c  -fno-strict-aliasing -fwrapv 
-DHAVE_CHICKEN_CONFIG_H -DC_ENABLE_PTABLES -Os -fomit-frame-pointer 
-DC_PRIVATE_REPOSITORY -I.. -I"/usr/local/include/chicken"
rm rev-app.c
clang rev-app.o -o rev-app/rev-app -L.. -L"/usr/local/lib"  -Wl,-R"\$ORIGIN" -z 
origin -lchicken -lm -lpthread
clang: error: no such file or directory: 'origin'

Error: shell command terminated with non-zero exit status 256: clang rev-app.o 
-o rev-app/rev-app -L.. -L"/usr/local/lib"  -Wl,-R"\$ORIGIN" -z origin 
-lchicken -lm -lpthread
gmake[1]: *** [check] Error 1

This did not happen with gcc-4.6, which finished with no errors.

I wasn't familiar with the '-z' option, and I gleaned it's used by the gnu 
linker.  Since this option is invoked only with "-deploy" in the test suite, 
I'm not really sure of its purpose.  It may be needed by gcc, but '-z origin' 
was indigestible by clang.

After applying this small patch to csc.scm,

-- csc-orig.scm 2013-02-12 20:47:23.194996000 -0800
    csc.scm     2013-02-12 20:47:23.194996000 -0800
@@ -274,7  274,9 @@
         (else
          (list (conc "-L\"" library-dir "\""))))
    (if (and deployed (eq? (software-version) 'freebsd))
-       (list "-z origin")
           (if (string=? compiler "clang")
                   (list "")
                   (list "-z origin"))
        '())
    (cond ((get-environment-variable "CHICKEN_C_LIBRARY_PATH") =>
          (lambda (path)

then recompiling with clang and reinstalling, all tests completed without 
error.  This might suggest '-z origin' is problematic with clang under FreeBSD, 
as it interferes with use of '-deploy' as shown by the test results.

Unconnected to the above, I'll mention there appears to be a (very) small error 
in types.db that's been hanging on for quite a while.  The declaration for 
"join" is:
(join (#(procedure #:clean #:enforce) join (list list) list))

When compiling  (join r) ...  where r is a list of lists --
  Warning: in toplevel procedure `prints-util#qry-subdirs':
    (prints-util.scm:118) in procedure call to `join', expected 2 arguments, 
but was given 1
  argument

Since the second list specifier is optional (defaulting to '()), perhaps it 
should be:
(join (#(procedure #:clean #:enforce) join (list #!optional list) list))

Thanks,
J. Altfas
_______________________________________________
Chicken-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/chicken-users

Reply via email to