0

I have FreeNAS running and have created a jail to rip CDs. All works fine. I want to add the ability to grab the cover art as well and need glyr. This program is not available as a package or a port for FreeBSD as far as I can tell. I grabbed the git, installed the files needed to build the binary and am following instructions to build it.

I type:

cd glyr
cmake -DCMAKE_INSTALL_PREFIX=/usr .
make && sudo make install

And it appears to build everything then returns:

...    
[ 74%] Linking C shared library ../bin/libglyr.so
/usr/bin/ld: cannot find -lgthread-2.0
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Stop.
make[2]: stopped in /usr/home/kgrider/glyr
*** Error code 1

Stop.
make[1]: stopped in /usr/home/kgrider/glyr
*** Error code 1

Stop.
make: stopped in /usr/home/kgrider/glyr

I have grepped the 'lgthread-2.0' and have come across a lot of stuff about cairo and docker, but nothing that seems to be related.  How do I go further to get this built?

2 Answers 2

0

GThreads is part of Gnome and is included in glib.

# pkg info -l glib | grep libgthread
/usr/local/lib/libgthread-2.0.a
/usr/local/lib/libgthread-2.0.so
/usr/local/lib/libgthread-2.0.so.0
/usr/local/lib/libgthread-2.0.so.0.5600.1

I suggest that you use this library to resolve the dependencies.

3
  • I already have glib installed. # pkg info | grep glib glib-2.56.3_2,1 Some useful routines of C programming. If I try to install gnome-utils, I get a ton of X stuff which is not needed/wanted on a headless machine. Is this what you are suggesting? This seems a bit excessive just to get a tiny program to compile. pkg install gnome-utils The following 213 package(s) will be affected (of 0 checked): ...Number of packages to be installed: 213 The process will require 985 MiB more space. 199 MiB to be downloaded. Commented Jan 7, 2019 at 0:25
  • It was installed, I reinstalled form the port (same version) and still get the same result. Those 'libgthread' libraries are there. The build still says it cannot find them. [ 74%] Linking C shared library ../bin/libglyr.so /usr/bin/ld: cannot find -lgthread-2.0 cc: error: linker command failed with exit code 1 (use -v to see invocation) *** Error code 1 Commented Jan 15, 2019 at 1:16
  • Seems that this is a freeBSD issue as it compiles fine on Arch Linux with the same commands. Commented Jan 15, 2019 at 2:32
0

I figured it out. For whatever reason, FreeBSD installs libraries in /usr/local/lib, but does not include this in its path. I ran across another answer and tried this and it worked: 'export LIBRARY_PATH=/usr/local/lib' before I executed 'make'. Now it builds...

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .