From owner-freebsd-ports@FreeBSD.ORG Thu Sep 26 14:11:49 2013 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 8379A3AB for ; Thu, 26 Sep 2013 14:11:49 +0000 (UTC) (envelope-from freebsd@grem.de) Received: from mail.grem.de (outcast.grem.de [213.239.217.27]) by mx1.freebsd.org (Postfix) with SMTP id E123F2C99 for ; Thu, 26 Sep 2013 14:11:48 +0000 (UTC) Received: (qmail 75294 invoked by uid 89); 26 Sep 2013 14:05:06 -0000 Received: from unknown (HELO bsd64.grem.de) (mg@grem.de@194.97.158.66) by mail.grem.de with ESMTPA; 26 Sep 2013 14:05:06 -0000 Date: Thu, 26 Sep 2013 16:05:05 +0200 From: Michael Gmelin To: Alexandr Kovalenko Subject: Re: CMake, libexecinfo, ${LOCALBASE}/lib and ldconfig Message-ID: <20130926160505.007c7827@bsd64.grem.de> In-Reply-To: References: X-Mailer: Claws Mail 3.9.1 (GTK+ 2.24.18; amd64-portbld-freebsd9.1) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-ports@freebsd.org X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Sep 2013 14:11:49 -0000 On Thu, 26 Sep 2013 14:00:32 +0100 Alexandr Kovalenko 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