[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Please help building bwa on freebsd [noreply@buildd.debian.org: failed kfreebsd-amd64 build of bwa 0.7.12-1]



The solution may simply be to link with -lrt.

    $ cat shmopen.c
    #include <sys/mman.h>
    #include <stdio.h>
    int main() { printf("%p\n", shm_open); return 0; }
    $ gcc shmopen.c
    /tmp/ccRPQFME.o: In function `main':
    shmopen.c:(.text+0x5): undefined reference to `shm_open'
    collect2: error: ld returned 1 exit status
    $ gcc shmopen.c -lrt && ./a.out
    0x400540
    $ lsb_release  -d
    Description:    Debian GNU/kFreeBSD 8.0 (jessie)
    $ dpkg-query -S /usr/lib/x86_64-kfreebsd-gnu/librt.so
    libc0.1-dev:kfreebsd-amd64: /usr/lib/x86_64-kfreebsd-gnu/librt.so
    $ apt-cache policy libc0.1-dev | head -2
    libc0.1-dev:
      Installed: 2.19-13

Jeff


Reply to: