FreeBSD - sbcl compile fails when compiling gc

Bug #1277080 reported by AndreasDavour
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SBCL
Invalid
Undecided
Unassigned

Bug Description

uname -a
FreeBSD tiny 10.0-RELEASE FreeBSD 10.0-RELEASE #0 r260789: Thu Jan 16 22:34:59 UTC 2014 <email address hidden>:/usr/obj/usr/src/sys/GENERIC amd64

git log output
$ git log
ESC[33mcommit 5fb8a6e8db4d1187ebf6af504ace231433a2993dESC[m
Author: Douglas Katzman <email address hidden>
Date: Wed Feb 5 15:37:39 2014 -0500

This is my command line and the error message I get (since FBSD 10 uses clang, a tried with cc as an alias to gcc and it still failed exactly the same)
$ sh make.sh --fancy --prefix=/home/ante/bin/sbcl

... (screenfuls of compile and then this) ...

beginning GENESIS, creating headers in "src/runtime/genesis"
NIL
* 132.80 real 124.85 user 6.44 sys
//entering make-target-1.sh
//building runtime system and symbol table file
gmake: Entering directory `/usr/home/ante/src/Lisp/sbcl/src/runtime'
rm -f *.[do] sbcl sbcl.nm sbcl.h core *.tmp
gmake: Leaving directory `/usr/home/ante/src/Lisp/sbcl/src/runtime'
gmake: Entering directory `/usr/home/ante/src/Lisp/sbcl/src/runtime'
echo '#include "genesis/config.h"' >sbcl.h
echo '#include "genesis/constants.h"' >>sbcl.h
gmake: Leaving directory `/usr/home/ante/src/Lisp/sbcl/src/runtime'
gmake: Entering directory `/usr/home/ante/src/Lisp/sbcl/src/runtime'
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o alloc.o alloc.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o backtrace.o backtrace.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o breakpoint.o breakpoint.c
breakpoint.c:119:24: warning: comparison of integers of different signs: 'uword_t' (aka 'unsigned long')
      and 'long' [-Wsign-compare]
            if (offset >= (N_WORD_BYTES * fixnum_value(codeptr->code_size)))
                ~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o coreparse.o coreparse.c
coreparse.c:342:25: warning: format specifies type 'void *' but the argument has type 'uword_t'
      (aka 'unsigned long') [-Wformat]
                        (uword_t)addr, (uword_t)DYNAMIC_SPACE_START);
                        ^~~~~~~~~~~~~
coreparse.c:342:40: warning: format specifies type 'void *' but the argument has type 'uword_t'
      (aka 'unsigned long') [-Wformat]
                        (uword_t)addr, (uword_t)DYNAMIC_SPACE_START);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
coreparse.c:369:25: warning: format specifies type 'void *' but the argument has type 'uword_t'
      (aka 'unsigned long') [-Wformat]
                        (uword_t)addr, (uword_t)STATIC_SPACE_START);
                        ^~~~~~~~~~~~~
coreparse.c:369:40: warning: format specifies type 'void *' but the argument has type 'uword_t'
      (aka 'unsigned long') [-Wformat]
                        (uword_t)addr, (uword_t)STATIC_SPACE_START);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
coreparse.c:376:25: warning: format specifies type 'void *' but the argument has type 'uword_t'
      (aka 'unsigned long') [-Wformat]
                        (uword_t)addr, (uword_t)READ_ONLY_SPACE_START);
                        ^~~~~~~~~~~~~
coreparse.c:376:40: warning: format specifies type 'void *' but the argument has type 'uword_t'
      (aka 'unsigned long') [-Wformat]
                        (uword_t)addr, (uword_t)READ_ONLY_SPACE_START);
                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
coreparse.c:407:15: warning: comparison of integers of different signs: 'ssize_t' (aka 'long') and
      'os_vm_size_t' (aka 'unsigned long') [-Wsign-compare]
    if (count < os_vm_page_size) {
        ~~~~~ ^ ~~~~~~~~~~~~~~~
7 warnings generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o dynbind.o dynbind.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o funcall.o funcall.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o gc-common.o gc-common.c
gc-common.c:1716:32: warning: format specifies type 'void *' but the argument has type 'uword_t'
      (aka 'unsigned long') [-Wformat]
                "by locks.\n", (uword_t)&where[2]);
                               ^~~~~~~~~~~~~~~~~~
1 warning generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o globals.o globals.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o interr.o interr.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o interrupt.o interrupt.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o largefile.o largefile.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o monitor.o monitor.c
monitor.c:151:29: warning: unused variable 'sptr' [-Wunused-variable]
            unsigned short *sptr = (unsigned short *)addr;
                            ^
1 warning generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o os-common.o os-common.c
os-common.c:132:12: warning: returning 'volatile void *' from a function with result type 'void *'
      discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
    return ret;
           ^~~
1 warning generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o parse.o parse.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o print.o print.c
print.c:96:31: warning: comparison of integers of different signs: 'unsigned int' and 'int'
      [-Wsign-compare]
                for (i = 0; i < n_output_flags; i++)
                            ~ ^ ~~~~~~~~~~~~~~
print.c:117:23: warning: comparison of integers of different signs: 'unsigned int' and 'int'
      [-Wsign-compare]
                if (i == n_output_flags)
                    ~ ^ ~~~~~~~~~~~~~~
2 warnings generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o purify.o purify.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o pthread-futex.o pthread-futex.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o regnames.o regnames.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o run-program.o run-program.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o runtime.o runtime.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o safepoint.o safepoint.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o save.o save.c
save.c:377:20: warning: passing 'unsigned char []' to parameter of type 'const char *' converts between
      pointers to integer types with different sign [-Wpointer-sign]
    idlen = strlen(build_id) - 1;
                   ^~~~~~~~
/usr/include/string.h:95:28: note: passing argument to parameter here
size_t strlen(const char *) __pure;
                            ^
save.c:410:35: warning: comparison of integers of different signs: 'size_t' (aka 'unsigned long') and
      'os_vm_offset_t' (aka 'long') [-Wsign-compare]
    if (core_offset != -1 && size > core_offset)
                             ~~~~ ^ ~~~~~~~~~~~
2 warnings generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o search.o search.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o thread.o thread.c
thread.c:432:22: warning: comparison of unsigned expression >= 0 is always true [-Wtautological-compare]
    if(th->tls_cookie>=0) arch_os_thread_cleanup(th);
       ~~~~~~~~~~~~~~^ ~
1 warning generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o time.o time.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o util.o util.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o validate.o validate.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o vars.o vars.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o wrap.o wrap.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o x86-64-arch.o x86-64-arch.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o bsd-os.o bsd-os.c
bsd-os.c:248:50: warning: incompatible pointer types passing '__siginfohandler_t *' (aka 'void (*)(int,
      struct __siginfo *, void *)') to parameter of type 'interrupt_handler_t' (aka 'void (*)(int,
      siginfo_t *, os_context_t *)') [-Wincompatible-pointer-types]
                                                 (__siginfohandler_t *)
                                                 ^~~~~~~~~~~~~~~~~~~~~~
./interrupt.h:159:45: note: passing argument to parameter 'handler' here
                        interrupt_handler_t handler);
                                            ^
1 warning generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o x86-64-bsd-os.o x86-64-bsd-os.c
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o gencgc.o gencgc.c
gencgc.c:1237:53: warning: comparison of integers of different signs: 'unsigned long' and 'sword_t'
      (aka 'long') [-Wsign-compare]
    gc_assert((byte_cnt-orig_first_page_bytes_used) == nbytes);
               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~
./gc-internal.h:38:11: note: expanded from macro 'gc_assert'
    if (!(ex)) gc_abort(); \
          ^
gencgc.c:1407:15: warning: comparison of integers of different signs: 'sword_t' (aka 'long') and
      'os_vm_size_t' (aka 'unsigned long') [-Wsign-compare]
    if (nbytes>=large_object_size)
        ~~~~~~^ ~~~~~~~~~~~~~~~~~
gencgc.c:2073:44: warning: incompatible pointer to integer conversion passing 'lispobj *'
      (aka 'unsigned long *') to parameter of type 'lispobj' (aka 'unsigned long'); dereference with *
      [-Wint-conversion]
    return looks_like_valid_lisp_pointer_p(pointer, start_addr);
                                           ^~~~~~~
                                           *
./gc-internal.h:160:52: note: passing argument to parameter 'pointer' here
extern int looks_like_valid_lisp_pointer_p(lispobj pointer, lispobj *start_addr);
                                                   ^
gencgc.c:4022:24: warning: comparison of integers of different signs: 'page_index_t' (aka 'long') and
      'unsigned long' [-Wsign-compare]
            for (i=0; i<GENCGC_CARD_BYTES/sizeof(sword_t); i++) {
                      ~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
gencgc.c:4251:16: warning: comparison of integers of different signs: 'sword_t' (aka 'long') and
      'os_vm_size_t' (aka 'unsigned long') [-Wsign-compare]
    if (nbytes > large_allocation)
        ~~~~~~ ^ ~~~~~~~~~~~~~~~~
gencgc.c:4268:16: warning: comparison of integers of different signs: 'sword_t' (aka 'long') and
      'os_vm_size_t' (aka 'unsigned long') [-Wsign-compare]
    if (nbytes >= bytes_consed_between_gcs)
        ~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~
6 warnings generated.
cc -g -Wall -Wsign-compare -O3 -fno-omit-frame-pointer -I. -DSBCL_PREFIX=\"'/home/ante/bin/sbcl'\" -c -o x86-64-assem.o x86-64-assem.S
x86-64-assem.S:622:9: error: unknown directive
        .end
        ^
gmake: *** [x86-64-assem.o] Error 1
gmake: Leaving directory `/usr/home/ante/src/Lisp/sbcl/src/runtime'
        5.68 real 4.67 user 0.94 sys

Revision history for this message
Stas Boukarev (stassats) wrote :

You are using clang, aren't you? Clang, apparently, doesn't like ".end" anymore. Use gcc instead.

Changed in sbcl:
status: New → Invalid
Revision history for this message
AndreasDavour (koraq) wrote :

That's was what I tried to do by using an alias for cc. Clearly it didn't work. I'd gladly take any suggestions on how to shortcut out clang without using aliases.

Revision history for this message
Stas Boukarev (stassats) wrote :

export CC=gcc should do.

Revision history for this message
AndreasDavour (koraq) wrote :

That worked fine. Thanks Stas!

Now something else failed, but that's another bug report.

This issue can be closed.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.