From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Jeffrey Walton Newsgroups: gmane.lisp.guile.devel Subject: Does Guile honor its configuration options and make flags? Date: Tue, 24 Oct 2017 10:31:42 -0400 Message-ID: Reply-To: noloader@gmail.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" X-Trace: blaine.gmane.org 1508855546 27078 195.159.176.226 (24 Oct 2017 14:32:26 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 24 Oct 2017 14:32:26 +0000 (UTC) To: guile-devel@gnu.org Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Tue Oct 24 16:32:14 2017 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e70FJ-0003xe-Oi for guile-devel@m.gmane.org; Tue, 24 Oct 2017 16:31:57 +0200 Original-Received: from localhost ([::1]:44114 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e70FP-0002p9-1O for guile-devel@m.gmane.org; Tue, 24 Oct 2017 10:32:03 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48555) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e70FD-0002m5-HJ for guile-devel@gnu.org; Tue, 24 Oct 2017 10:31:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e70F7-00057i-DR for guile-devel@gnu.org; Tue, 24 Oct 2017 10:31:51 -0400 Original-Received: from mail-oi0-x231.google.com ([2607:f8b0:4003:c06::231]:56693) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e70F7-00057K-7k for guile-devel@gnu.org; Tue, 24 Oct 2017 10:31:45 -0400 Original-Received: by mail-oi0-x231.google.com with SMTP id v9so37191635oif.13 for ; Tue, 24 Oct 2017 07:31:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:reply-to:from:date:message-id:subject:to; bh=M3QcEOMVxP5WlcV57NSveTnneLJztf91FgJnptVNB1g=; b=BGUWbwVh+pmRKCLya+/fFAE3svbqJcwe+xt9QDEfWNRcW5OEWgrbhXWUGZM99Z+cvh qUFMMPg7naBcrDG4EppD9jYTB7lxlbzjYX0gga0PUqZlzk2H9Adl2X8Fa81I+bANnztz aDFzmMVVOIs5LZ5rQMsSdJkicFn3qbYWHkhwd2dNSOSAxvSicM34h5+ThwzBf3DwWJO6 pEnQ9nvrYWMgW3LE/gc7mHBSMKItdchkYL14uI/mOtxO9zhEdrigBYryPQ0emU+WKsXI sf+5HWpD1+r3mR+KKy4mpGConOwWgrsrhaBvR30ocHFvm1YO38JppuxTj/mSBi/+wgUK IvyQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:from:date:message-id :subject:to; bh=M3QcEOMVxP5WlcV57NSveTnneLJztf91FgJnptVNB1g=; b=IQwqTCv7lF1lx2tsByOSQqmhNkrbd4qPc+N3zkjdZOcLs6NldXy2yGkq5oI/4carC+ wTL05PNWWE0dcarM4NP8L197J0vUv12Nn5sypRR22cD/dGsDOfa1cdcVo/khUjXRimIF AAacHQj3/V0AVNHKfWa8qKgqIizoGQdgmo06xpjbuxW3kInM936YBPWNsrbN9qtgQxVy Y9cgWwpZGBhroYvGMc1njWAwsOgIYGWKmFQdx5JP+zhDLbxwH+28IPeCD2V8Od6WYeTU DEEVygiCn4rXqUH6dnA6bc1V8xVzDtNn6fMTUrVYP+uL2+ZjYrz9EBfgsCXvKzoSvNCu +Yyg== X-Gm-Message-State: AMCzsaWn7/UTAokF+V98R0+2mZdQ6F2KvvfyRRdi65SW8mh5Sluvm9HX k/X0tuKJRh93rnaMXkmFoPRaZUxf6cNkbnnZPKkwbWG6 X-Google-Smtp-Source: ABhQp+TLrwldps4B362fbBMQoeO4ZR7bYVw+eGoZR0eswcO6mLffKvsPvGGT6yNaUfx31g/S5UvEynv7sFK736zq4lo= X-Received: by 10.202.244.77 with SMTP id s74mr6349144oih.388.1508855504052; Tue, 24 Oct 2017 07:31:44 -0700 (PDT) Original-Received: by 10.74.19.87 with HTTP; Tue, 24 Oct 2017 07:31:42 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4003:c06::231 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: "guile-devel" Xref: news.gmane.org gmane.lisp.guile.devel:19341 Archived-At: I'm having trouble with some linking. Guile was configured with --with-pic, and its dependent libraries were built with -fPIC. I'm building on x86_64, so CFLAGS and CXXFLAGS include "-m64 -march=native". My build of Readline installed in /usr/local has -fPIC applied. The same applies to Termcap and Ncurses. I've gone back to my build records and confirmed the three were built with -fPIC, -m64 (and friends) and the proper relocation data is available. However, when Guile links, I get loads of "recompile with -fPIC". A sample is shown below. My first question is, is Guile actually honoring --with-pic, --with-readline-prefix and the flags it was configured with? My second question is, is Guile using the libraries provided in /usr/local? Or is it using some other libraries with an arbitrary configuration? My third question is, how do I get Guile to __STOP__ hiding output? `make V=1` does not seem to do it. I can't diagnose a problem I don't see, and the missing outputs are extremely frustrating. **************************************** libtool: link: gcc -std=gnu11 -shared -fPIC -DPIC .libs/readline.o -Wl,--whole-archive ../lib/.libs/libgnu.a -Wl,--no-whole-archive -Wl,-rpath -Wl,/home/jwalton/Build-Scripts/guile-2.2.2/libguile/.libs -Wl,-rpath -Wl,/usr/local/lib64 -Wl,-rpath -Wl,/usr/local/lib64 -L/usr/local/lib64 -lreadline -lncurses ../libguile/.libs/libguile-2.2.so -lgc -lffi /usr/local/lib64/libgmp.so /usr/local/lib64/libltdl.so /usr/local/lib64/libunistring.so /usr/local/lib64/libiconv.so -lcrypt -ldl -lpthread -lm -m64 -march=native -m64 -Wl,-rpath -Wl,/usr/local/lib64 -Wl,--enable-new-dtags -Wl,-soname -Wl,guile-readline.so.0 -o .libs/guile-readline.so.0.0.0 /bin/ld: /usr/local/lib64/libncurses.a(lib_termcap.o): relocation R_X86_64_32S against symbol `_nc_globals' can not be used when making a shared object; recompile with -fPIC /bin/ld: /usr/local/lib64/libncurses.a(lib_tparm.o): relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; recompile with -fPIC /bin/ld: /usr/local/lib64/libncurses.a(lib_tputs.o): relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; recompile with -fPIC /bin/ld: /usr/local/lib64/libncurses.a(comp_error.o): relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; recompile with -fPIC /bin/ld: /usr/local/lib64/libncurses.a(lib_baudrate.o): relocation R_X86_64_32S against `.rodata' can not be used when making a shared object; recompile with -fPIC **************************************** Here's part of the script I am using to drive things on my side. All of the OPT_ array are valid. 30 or so other Autotool projects configure fine with them. It feels like Guile is just ignoring what I am telling it to do. PKG_CONFIG_PATH="${OPT_PKGCONFIG[*]}" \ CPPFLAGS="${OPT_CPPFLAGS[*]}" \ CFLAGS="${OPT_CFLAGS[*]}" CXXFLAGS="${OPT_CXXFLAGS[*]}" \ LDFLAGS="${OPT_LDFLAGS[*]}" LIBS="${OPT_LIBS[*]}" \ ./configure --prefix="$INSTALL_PREFIX" --libdir="$INSTALL_LIBDIR" \ --enable-shared --enable-static --with-pic \ --disable-deprecated \ --with-libgmp-prefix="$INSTALL_PREFIX" \ --with-libunistring-prefix="$INSTALL_PREFIX" \ --with-libiconv-prefix="$INSTALL_PREFIX" \ --with-libltdl-prefix="$INSTALL_PREFIX" \ --with-readline-prefix="$INSTALL_PREFIX" \ --with-libintl-prefix="$INSTALL_PREFIX" if [[ "$?" -ne "0" ]]; then echo "Failed to configure Guile" [[ "$0" = "${BASH_SOURCE[0]}" ]] && exit 1 || return 1 fi MAKE_FLAGS=("-j" "$MAKE_JOBS" "V=1") if ! "$MAKE" "${MAKE_FLAGS[@]}" then echo "Failed to build Guile" [[ "$0" = "${BASH_SOURCE[0]}" ]] && exit 1 || return 1 fi