3

I'm trying to install GNU Guile so that I can later install Guix. My environment is pretty locked down, but they do allow us build tools. I've been trying to get pianobar installed for the past few days, and it works, but I get the output "Cannot Open Audio Device". I have to compile libao-pulse, which requires Guile, but no matter what arguments I pass to the configure script, it always ends on configure: error: GNU libltdl (Libtool) not found, see README.

I've tried setting LD_LIBRARY_PATH, LD_FLAGS, CFLAGS, and several others, but I can't seem to get it to get past this step.

My build environment looks like this:

├── ~/local
   ├── bin
   ├── build
   ├── include
   ├── lib
   └── share

I have environment variables ($PREFIX, $build, and $PATH) set to reflect this setup.

What am I doing wrong?

config.log: https://gist.github.com/ijustlovemath/e197ee17db459ab46c1a

ijustlovemath
  • 703
  • 10
  • 21

1 Answers1

1

The telling lines from your log are these:

configure:44552: checking for libltdl
configure:44574: gcc -o conftest -g -O2 -I/home/redacted/local/include -L/home/redacted/local/lib conftest.c /home/redacted/local/lib/libltdl.so -L/usr/lib /usr/lib/libdl.so -Wl,-rpath -Wl,/home/redacted/local/lib -Wl,-rpath -Wl,/usr/lib  >&5
/usr/lib/libdl.so: could not read symbols: File in wrong format
collect2: ld returned 1 exit status

That is the only place in your config.log that mentions /usr/lib/libdl.so. My hunch is that your local copy of libtool is misconfigured.

C. K. Young
  • 219,335
  • 46
  • 382
  • 435
  • You mean the one in /usr/lib? Or the one in $PREFIX/lib? How would I have to configure it to fix it? Also, you have made an appearance on this exact question in the past, are you some kind of Guile compilation wizard? – ijustlovemath Feb 23 '16 at 23:16
  • I mean that I believe your local copy of libtool (in `$PREFIX/lib`) is misconfigured somehow to refer to `/usr/lib/libdl.so`. It should just use `-ldl`, without reference to `/usr/lib`. (Not sure what platform you're on, but on my Debian system, `libdl.so` is in `/usr/lib/x86_64-linux-gnu`.) As for your second question, I have used Guile for a long time and know the GNU build tools fairly well. :-) – C. K. Young Feb 23 '16 at 23:25
  • I believe it's a RHEL system, judging from the lack of apt-get and presence of yum. What might cause this behavior? How can I fix it? Also, can we move this to chat? – ijustlovemath Feb 23 '16 at 23:28
  • So I found that libltdl.la in $PREFIX/lib refers to /usr/lib and changed it, same error. Should I be recompiling libltdl? – ijustlovemath Feb 24 '16 at 00:48
  • Yeah, you should probably rebuild libtool, and run `make check` to ensure it works correctly. If you're using pretty standard flags and it still creates a borked `libltdl`, Gist the libtool `config.log` and I'll take a peek at it when I find the time. – C. K. Young Feb 24 '16 at 00:56
  • 1
    Rebuilding libtool did the trick. Wow! Can't believe that was the problem the whole time. Still didn't make, but at least we're on to new problems. Cheers, I'll mark this as closed. – ijustlovemath Feb 24 '16 at 01:46
  • Yep, feel free to post a new question with your new problem (again with the new `config.log` output). :-) – C. K. Young Feb 24 '16 at 01:49
  • Unfortunately I have a similar problem. I recompiled libtool but that did not help; I removed all old versions of libtool but imagemagick still complains. I think it really is time to deprecate libtool in general - it is holding us back really. I mean, who is going to sift through like +5000 lines of shell code to find out what it is doing, whenever something goes awry nowadays? – shevy Mar 19 '21 at 15:15