LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
LinkBack Search this Thread
Old 08-18-2007, 01:07 PM   #1
Thirteenth Zodiac
LQ Newbie
 
Registered: Jul 2007
Posts: 13

Rep: Reputation: 0
"Make" errors when trying to install FST (FreeST)


I am trying to install FST so I can start using the VST plugins I need for my music production. After spending a lot of time tracking all the dependencies (seems I needed the Dev packages for all the dependencies), when I enter "Make", I get the following result:

Quote:
dominic@Floreffe:~/fst-1.8$ make
cp -a `find . | grep 'vstsdk[^/]*\$'`/source/common ./vst
sed -i '/struct VstFileType\|struct VstFileSelect/,/};/d' vst/aeffectx.h
winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o audiomaster.o audiomaster.c
audiomaster.c: In function ‘jack_host_callback’:
audiomaster.c:119: warning: incompatible implicit declaration of built-in function ‘floor’
winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o fst.o fst.c
winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o fstinfofile.o fstinfofile.c
fstinfofile.c: In function ‘load_fst_info_file’:
fstinfofile.c:36: warning: incompatible implicit declaration of built-in function ‘malloc’
fstinfofile.c: In function ‘fst_info_from_plugin’:
fstinfofile.c:162: warning: incompatible implicit declaration of built-in function ‘malloc’
winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o gtk.o gtk.c
winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o jfst.o jfst.c
winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o vsti.o vsti.c
vsti.c: In function ‘queue_midi’:
vsti.c:79: warning: assignment from incompatible pointer type
winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o vstwin.o vstwin.c
vstwin.c: In function ‘fst_load’:
vstwin.c:480: warning: assignment from incompatible pointer type
winegcc -mwindows -o fst.exe audiomaster.o fst.o fstinfofile.o gtk.o jfst.o vsti.o vstwin.o `pkg-config --libs gtk+-2.0` `pkg-config --libs jack` `pkg-config --libs alsa` `pkg-config --libs lash-1.0` -L/usr/X11R6/lib -lX11 -luuid
jfst.o: In function `main':
jfst.c.text+0xa4c): undefined reference to `pthread_create'
vsti.o: In function `stop_midireceiver':
vsti.c.text+0x562): undefined reference to `pthread_join'
collect2: ld returned 1 exit status
winegcc: i486-linux-gnu-gcc failed.
make: *** [fst.exe] Error 2
dominic@Floreffe:~/fst-1.8$
I don't understand what the problem is. I downloaded the package at http://joebutton.co.uk/fst/ and followed the instructions, installed the Steinberg SDK and all. I'm using Ubuntu Feisty Fawn. I tried running Make as root, both with Jack running and not, with my Timidity MIDI server running and not, and it always gives the same results. Does anyone have any idea?
 
Old 08-18-2007, 03:03 PM   #2
colucix
Moderator
 
Registered: Sep 2003
Location: Bologna
Distribution: OpenSUSE 12.1 CentOS 6.2
Posts: 9,003

Rep: Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349
Code:
jfst.c.text+0xa4c ): undefined reference to `pthread_create'
vsti.c.text+0x562 ): undefined reference to `pthread_join'
From these two lines it seems the compilation does not know where the libpthread.so library is. After checking if you have this library on your system, you can check if the options passed to winegcc include the correct path and library name.
Since it uses pkg-config to locate libraries and their dependencies, you can test from the command line by echoing the winegcc lines themselves. I mean, you can try to do the following:
Code:
echo winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o jfst.o jfst.c
that is: type echo on the command line and then past exactly the relevant winegcc line from the output of make. In this way all the pkg-config commands will be executed (expanded) and you will see all the option passed to winegcc. If you don't notice anything like
Code:
-lpthread
on the resulting command lines, probably you have to edit the Makefile to add the proper location and/or name of the required library. Hope this will help a little.

Last edited by colucix; 08-18-2007 at 03:04 PM.
 
Old 08-18-2007, 09:04 PM   #3
Thirteenth Zodiac
LQ Newbie
 
Registered: Jul 2007
Posts: 13

Original Poster
Rep: Reputation: 0
Thanks!

The library is indeed in my system, in the usr/lib directory. I'm not sure how I can echo the make command, since when I type Make, a huge command appears. It seems to make up 4 or 5 lines, but it looks like it's just one command that's so long that the text wraps around. So I believe it's just one line. I copied that whole thing and tried the echo, like this:
Quote:
dominic@Floreffe:~/fst-1.8$ echo winegcc -mwindows -o fst.exe audiomaster.o fst.o fstinfofile.o gtk.o jfst.o vsti.o vstwin.o `pkg-config --libs gtk+-2.0` `pkg-config --libs jack` `pkg-config --libs alsa` `pkg-config --libs lash-1.0` -L/usr/X11R6/lib -lX11 -luuid
Which resulted in this:
Quote:
winegcc -mwindows -o fst.exe audiomaster.o fst.o fstinfofile.o gtk.o jfst.o vsti.o vstwin.o -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lm -lpangocairo-1.0 -lfontconfig -lXext -lXrender -lXinerama -lXi -lXrandr -lXcursor -lXfixes -lpango-1.0 -lcairo -lX11 -lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0 -ljack -lasound -llash -ljack -lasound -L/usr/X11R6/lib -lX11 -luuid
With a straight return to the command prompt, not anything else. So I tried to go on with the next step you suggested, but I can't figure out how to edit the makefile. I suppose I should add the path and filename somewhere in the Libraries section:
Quote:
LIBRARIES = `pkg-config --libs gtk+-2.0` `pkg-config --libs jack` `pkg-config --libs alsa` `pkg-config --libs lash-1.0` -L/usr/X11R6/lib -lX11
But what's the proper syntax? Should it look like this:
Quote:
LIBRARIES = `pkg-config --libs libpthread.so` `pkg-config --libs gtk+-2.0` `pkg-config --libs jack` `pkg-config --libs alsa` `pkg-config --libs lash-1.0` -L/usr/X11R6/lib -lX11
? And what about the path to libpthread.so (/usr/lib)? Or should it go somewhere else in the makefile?
 
Old 08-19-2007, 03:59 AM   #4
colucix
Moderator
 
Registered: Sep 2003
Location: Bologna
Distribution: OpenSUSE 12.1 CentOS 6.2
Posts: 9,003

Rep: Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349
Quote:
dominic@Floreffe:~/fst-1.8$ echo winegcc -mwindows -o fst.exe audiomaster.o fst.o fstinfofile.o gtk.o jfst.o vsti.o vstwin.o `pkg-config --libs gtk+-2.0` `pkg-config --libs jack` `pkg-config --libs alsa` `pkg-config --libs lash-1.0` -L/usr/X11R6/lib -lX11 -luuid
The command you echoed is ok: indeeed this is a single long command line that has been wrapped from the terminal. The echo command simply echoes the same line without doing anything but the expansion of the pkg-config "inline" commands.
Quote:
winegcc -mwindows -o fst.exe audiomaster.o fst.o fstinfofile.o gtk.o jfst.o vsti.o vstwin.o -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lm -lpangocairo-1.0 -lfontconfig -lXext -lXrender -lXinerama -lXi -lXrandr -lXcursor -lXfixes -lpango-1.0 -lcairo -lX11 -lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0 -ljack -lasound -llash -ljack -lasound -L/usr/X11R6/lib -lX11 -luuid
Here the -lpthread option does not appear! To be sure you can verify also the lines:
Code:
echo winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o jfst.o jfst.c
echo winegcc -c `pkg-config --cflags gtk+-2.0` `pkg-config --cflags jack` `pkg-config --cflags jack` `pkg-config --cflags lash-1.0` -DHAVE_LASH -I. -o vsti.o vsti.c
that make the compilation of the two wrong object files: jfst.o and vsti.o (the ones for which you got the "undefined symbol" errors).
To edit the make file you can try to add
Code:
-L/usr/lib -lpthread
to some variable in the header (LIBRARIES may be good) or - as alternative - you can leave the Makefile unchanged and define an environment variable called CFLAGS, e.g. by the command
Code:
export CFLAGS="-L/usr/lib -lpthread"
This is because most likely the make process will look for this (and other) variables and add their value as options to the compiler. You will see the differences in the output from make.

To reply to your last questions: the syntax pkg-config --libs libpthread.so is wrong because pkg-config is a utility that look for config files with the .pc extension. These files are named as the application to which they are associated and contain information about includes, library paths, dependencies and so on. Usually they are in /usr/lib/pkgconfig/. You may have a look at "man pkg-config" for details.
 
Old 08-19-2007, 09:31 AM   #5
Thirteenth Zodiac
LQ Newbie
 
Registered: Jul 2007
Posts: 13

Original Poster
Rep: Reputation: 0
Talking

Grazie Mille colucix! It worked! I echoed both commands you provided and still didn't have -lpthread in them, so I simply edited the Makefile adding the line you gave. Now I'm getting the "can't load plugin" error. But FST is installed and runs, so I can start looking around for debugging. Thanks again!
 
Old 08-19-2007, 10:56 AM   #6
colucix
Moderator
 
Registered: Sep 2003
Location: Bologna
Distribution: OpenSUSE 12.1 CentOS 6.2
Posts: 9,003

Rep: Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349Reputation: 1349
Prego! As a final comment, it sounds strange to me that the pthread library is not seen anyway, since it is in a default location. Probably you have to update the library cache. See
Code:
man ldconfig
for details. You can try (as root)
Code:
ldconfig -p | grep pthread
to see if the library is stored in the current cache. And if not, you can try to update (just for future use). Cheers!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
So many errors when I typed the "make" and "make install" command Niceman2005 Linux - Software 23 07-22-2009 02:33 PM
window maker "make" / "make install" problem xiekke Fedora 2 08-08-2007 10:55 AM
"make install" kernel errors deadlinx Linux - Kernel 5 03-31-2007 12:26 PM
Constant errors during "make" or "make install" with SUSE 10.1 Alpha 4 TehFlyingDutchman Linux - Software 3 12-30-2005 06:25 PM
FC4 install errors, "diabling IRQ #10" "nobody cares" error message??? A6Quattro Fedora 6 07-20-2005 12:49 PM


All times are GMT -5. The time now is 05:30 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration