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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
12-13-2008, 06:52 AM
|
#1
|
LQ Newbie
Registered: Nov 2003
Posts: 27
Rep:
|
[SOLVED] Errors while compiling Faust: "PATH_MAX was not declared in this scope"
Hello everyone,
I've been trying to install Faust ( http://faust.grame.fr/), downloaded from http://sourceforge.net/projects/faudiostream/ (faust-0.9.9.4b.tar.gz). The README file says:
Code:
There is no configuration phase. To compile and install the Faust compiler do :
make
su
make install
Accordingly, after copying to /usr/local/ and doing 'tar -xvzf faust-0.9.9.4b.tar.gz' and entering the directory, I typed 'make'. After a stream of warning messages, this happened:
Code:
g++ -g -O3 -Wall -Wuninitialized -Iboxes -Ierrors -Ievaluate -Igenerator -Inormalize -Iparser -Ipropagate -Isignals -Itlib -Idraw -Idraw/device -Idraw/schema -Iextended -Ipatternmatcher -c -o parallelize/colorize.o parallelize/colorize.cpp
In file included from tlib/tlib.hh:165,
from parallelize/colorize.h:7,
from parallelize/colorize.cpp:7:
tlib/node.hh: In function ‘bool isZero(const Node&)’:
tlib/node.hh:157: warning: suggest parentheses around && within ||
tlib/node.hh: In function ‘bool isGEZero(const Node&)’:
tlib/node.hh:163: warning: suggest parentheses around && within ||
tlib/node.hh: In function ‘bool isGTZero(const Node&)’:
tlib/node.hh:169: warning: suggest parentheses around && within ||
tlib/node.hh: In function ‘bool isOne(const Node&)’:
tlib/node.hh:175: warning: suggest parentheses around && within ||
tlib/node.hh: In function ‘bool isMinusOne(const Node&)’:
tlib/node.hh:181: warning: suggest parentheses around && within ||
g++ -g -O3 -Wall -Wuninitialized -Iboxes -Ierrors -Ievaluate -Igenerator -Inormalize -Iparser -Ipropagate -Isignals -Itlib -Idraw -Idraw/device -Idraw/schema -Iextended -Ipatternmatcher -c -o parser/enrobage.o parser/enrobage.cpp
parser/enrobage.cpp: In function ‘std::ifstream* open_path_stream(const char*, const char*)’:
parser/enrobage.cpp:75: error: ‘PATH_MAX’ was not declared in this scope
parser/enrobage.cpp:80: error: ‘old’ was not declared in this scope
parser/enrobage.cpp:85: error: ‘free’ was not declared in this scope
parser/enrobage.cpp:93: error: ‘free’ was not declared in this scope
parser/enrobage.cpp: In function ‘std::ifstream* open_arch_stream(const char*)’:
parser/enrobage.cpp:108: error: ‘getenv’ was not declared in this scope
parser/enrobage.cpp: In function ‘FILE* fopensearch(const char*)’:
parser/enrobage.cpp:144: error: ‘getenv’ was not declared in this scope
parser/enrobage.cpp: In function ‘FILE* fopenpath(const char*, const char*)’:
parser/enrobage.cpp:153: error: ‘PATH_MAX’ was not declared in this scope
parser/enrobage.cpp:157: error: ‘old’ was not declared in this scope
parser/enrobage.cpp:164: error: ‘free’ was not declared in this scope
parser/enrobage.cpp:172: error: ‘free’ was not declared in this scope
make[1]: *** [parser/enrobage.o] Error 1
make[1]: Leaving directory `/usr/local/faust-0.9.9.4/compiler'
make: *** [all] Error 2
After a bit of googling, I found this: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=417185. Although it seems to be related, I didnt understand how to work around the problem.
I'm running Mandriva 2009.0.
Any help with this would be appreciated!
Thanks in advance,
Guru
Last edited by prasadbrg; 12-13-2008 at 10:07 PM.
Reason: Added [SOLVED] to the title
|
|
|
12-13-2008, 09:21 AM
|
#2
|
ReliaFree Maintainer
Registered: Aug 2004
Location: Kalamazoo, Michigan
Distribution: Slackware 14.2
Posts: 2,815
|
Download the patch they have and apply it. From the top of the faust source tree, execute patch -Np1 -i /path/to/faust-0.9.9.1-1.1-nmu.diff. Of course, replace the /path/to portion with the correct relative or absolute path.
|
|
|
12-13-2008, 12:12 PM
|
#3
|
LQ Newbie
Registered: Nov 2003
Posts: 27
Original Poster
Rep:
|
Thanks weilbullguy, for the response!
I downloaded the *.diff file, and moved it to the faust-0.9.9.4 directory (the one created by opening the tarball) - this is the same directory that contains the Makefile. I assumed this is what you referred to as the top of the source tree.
I ran
Code:
patch -Np1 -i faust-0.9.9.1-1-nmu.diff
, and this was the output:
Code:
can't find file to patch at input line 4
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff -u faust-0.9.9.1/debian/changelog faust-0.9.9.1/debian/changelog
|--- faust-0.9.9.1/debian/changelog
|+++ faust-0.9.9.1/debian/changelog
--------------------------
File to patch:
This is the output of ls:
Code:
[root@localhost faust-0.9.9.4]# ls
architecture/ documentation/ Makefile tools/
compiler/ examples/ README windows/
COPYING faust-0.9.9.1-1.1-nmu.diff syntax-highlighting/
I haven't used the 'patch' utility before - the command wasn't there on my system, I just installed it through urpmi. I would appreciate any help with this.
Thanks in advance,
Guru
|
|
|
12-13-2008, 01:42 PM
|
#4
|
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,520
|
Your command seems quite OK !
But you can't patch debian/ not present,
so just hit <Enter>
Asked for file to patch : <Enter>
( if it's not there )
Instead of patching for gcc-4.3, I just installed
g++4.2 ( # urpmi gcc4.2-c++ )
( reason : the patching didn't clear all errors. )
Then make can be run with the "new" compiler :
'CC=gcc4.2 CXX=g++4.2 make'
....
Last edited by knudfl; 12-13-2008 at 03:32 PM.
|
|
|
12-13-2008, 10:05 PM
|
#5
|
LQ Newbie
Registered: Nov 2003
Posts: 27
Original Poster
Rep:
|
Works!
Thanks knudfl for the response....
Your solution worked! I used the older gcc and it seems to have compiled - there is an executable now, and I need to learn how to get it to run.
Thanks once again.
Cheers,
Guru
|
|
|
12-14-2008, 10:36 AM
|
#6
|
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,520
|
It' easy to try out :
example
'faust "path-to-faust-0.9.9.4"/examples/bandfilter.dsp'
|
|
|
12-15-2008, 01:04 AM
|
#7
|
LQ Newbie
Registered: Nov 2003
Posts: 27
Original Poster
Rep:
|
Thanks! It's working fine!
|
|
|
All times are GMT -5. The time now is 04:55 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|