Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 26 Sep 2013 16:05:05 +0200
From:      Michael Gmelin <freebsd@grem.de>
To:        Alexandr Kovalenko <never@nevermind.kiev.ua>
Cc:        freebsd-ports@freebsd.org
Subject:   Re: CMake, libexecinfo, ${LOCALBASE}/lib and ldconfig
Message-ID:  <20130926160505.007c7827@bsd64.grem.de>
In-Reply-To: <CAJ2Kz1Ad%2BR_gyWsqZ1-RkKTzJws4=WbT=zjwUz9f20%2B29kv6vg@mail.gmail.com>
References:  <CAJ2Kz1Ad%2BR_gyWsqZ1-RkKTzJws4=WbT=zjwUz9f20%2B29kv6vg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 26 Sep 2013 14:00:32 +0100
Alexandr Kovalenko <never@nevermind.kiev.ua> wrote:

> Hello,
> 
> I'm working on 5.5.33a MariaDB port now and got trouble making cmake
> to find libexecinfo (stub for linuxish backtrace() function).
> 
> I'm desperate now in trying to fight this thing:
> 
> Determining if the function backtrace exists failed with the
> following output: Change
> Dir: /usr/ports/databases/mariadb55-server/work/mariadb-5.5.33a/CMakeFiles/CMakeTmp
> 
> Run Build Command:/usr/local/bin/gmake
> "cmTryCompileExec343489733/fast" /usr/local/bin/gmake -f
> CMakeFiles/cmTryCompileExec343489733.dir/build.make
> CMakeFiles/cmTryCompileExec343489733.dir/build
> gmake[1]: Entering directory
> `/usr/ports/databases/mariadb55-server/work/mariadb-5.5.33a/CMakeFiles/CMakeTmp'
> /usr/local/bin/cmake -E cmake_progress_report
> /usr/ports/databases/mariadb55-server/work/mariadb-5.5.33a/CMakeFiles/CMakeTmp/CMakeFiles
> 1
> Building C object
> CMakeFiles/cmTryCompileExec343489733.dir/CheckFunctionExists.c.o
> /usr/bin/clang  -D_LARGEFILE_SOURCE -D_LARGE_FILES
> -D_FILE_OFFSET_BITS=64 -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS
> -D__STDC_FORMAT_MACROS -O2 -pipe -fno-strict-aliasing
> -DCHECK_FUNCTION_EXISTS=backtrace   -o
> CMakeFiles/cmTryCompileExec343489733.dir/CheckFunctionExists.c.o   -c
> /usr/local/share/cmake/Modules/CheckFunctionExists.c
> Linking C executable cmTryCompileExec343489733
> /usr/local/bin/cmake -E cmake_link_script
> CMakeFiles/cmTryCompileExec343489733.dir/link.txt --verbose=1
> /usr/bin/clang   -O2 -pipe -fno-strict-aliasing
> -DCHECK_FUNCTION_EXISTS=backtrace
> CMakeFiles/cmTryCompileExec343489733.dir/CheckFunctionExists.c.o  -o
> cmTryCompileExec343489733  -lexecinfo
> /usr/bin/ld: cannot find -lexecinfo
> clang: error: linker command failed with exit code 1 (use -v to see
> invocation) gmake[1]: Leaving directory
> `/usr/ports/databases/mariadb55-server/work/mariadb-5.5.33a/CMakeFiles/CMakeTmp'
> gmake[1]: *** [cmTryCompileExec343489733] Error 1
> gmake: *** [cmTryCompileExec343489733/fast] Error 2
> 
> 
> root@vbox:~ # ldconfig -r | grep execinfo
>         141:-lexecinfo.1 => /usr/local/lib/libexecinfo.so.1
> 
> Could anyone, please, explain me, why clang can't see libexecinfo
> during link phase and how to fix it?
> 
> Thanks in advance!
> 

Hi Alexandr,

Since you're working on 5.5.33a it would be great if you could
incorporate the patches I just submitted to allow building mariadb
using clang's libc++ http://www.freebsd.org/cgi/query-pr.cgi?pr=182408 .

As for your problem, there's been an ldconfig bug in the ports tree a
few days ago, maybe updating it will fix this for you (this is just a
wild speculation, I didn't really check if it is related). Feel free
to send me a tarball of the port skeleton off-list in case you're stuck.

Cheers,
Michael


-- 
Michael Gmelin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130926160505.007c7827>