File: faustpath

package info (click to toggle)
faust 2.30.5~ds0-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 279,348 kB
  • sloc: cpp: 239,368; javascript: 32,310; ansic: 17,442; sh: 11,925; java: 5,903; objc: 3,879; makefile: 3,030; cs: 1,139; python: 987; ruby: 951; xml: 693; yacc: 537; lex: 239; lisp: 201; awk: 110
file content (55 lines) | stat: -rwxr-xr-x 2,396 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#! /bin/bash -e

#####################################################################
#                                                                   #
#               Search where Faust is installed and defines   		#
#				$FAUSTLIB and $FAUSTINC so that we can use			#
#				-L$FAUSTLIB and -I$FAUSTINC where needed.			#
#               (c) Grame, 2013                                    #
#                                                                   #
#####################################################################

#-------------------------------------------------------------------------------
# Search where Faust is installed. Store '.../share/faust/' in $FAUSTLIB
# and '.../include/(faust)' in $FAUSTINC 
#
# USAGE :
# add line << . faustpath >> to your script
# and use -L$FAUSTLIB and -I$FAUSTINC where needed

FAUSTLDDIR=$(faust -libdir); 
FAUSTLIB=$(faust -dspdir); 
FAUSTINC=$(faust -includedir); 
[ -n "$FAUSTARCH" ] || FAUSTARCH=$(faust -archdir); 

[ -n "$MAXSDK" ] || MAXSDK=/usr/local/include/c74support/
CSOUND_MACSDK=/Library/Frameworks/CsoundLib64.framework
# try and guess a good place for Pd header files. Taking the first entry in /Applications/Pd- and taking the folder containing m_pd.h
[ -n "$PUREDATA_MACSDK" ] || PUREDATA_MACSDK=`ls -d /Applications/Pd-* 2> /dev/null | head -n1 | xargs -I REPL find REPL -name m_pd.h -exec dirname {} \; | head -n1`
[ -n "$PUREDATA_LINUXSDK" ] || PUREDATA_LINUXSDK=`find /usr/include/pd /usr/include/libpd/ /usr/include/pdextended /usr/local/include/pd /usr/local/include/libpd -name m_pd.h -exec dirname {} \; 2>/dev/null| head -n1`
VSTSDK=""
[ -n "$SUPERCOLLIDER_HEADERS" ] || SUPERCOLLIDER_HEADERS=/usr/local/include/SuperCollider/

FPATH="$FAUST_INSTALL /usr/local /usr /opt /opt/local"; # <- where to search
if [ -z "$FAUSTLIB" -o -z "$FAUSTINC" ]; then 
for f in $FPATH; do
	if [ -e $f/share/faust ]; 	then FAUSTLIB=$f/share/faust;	fi
	if [ -e $f/include/faust ];	then FAUSTINC=$f/include/; fi
done
fi

for f in $FPATH; do
	if [ -e $f/lib/libmicrohttpd.a ]; 	then HTTPLIB=$f/share/faust;	fi
done

if [ -e /etc/faust/faustpath ]; then
 . /etc/faust/faustpath
fi
if [ -e ${HOME}/.faust/faustpath ]; then
 . ${HOME}/.faust/faustpath
fi

if [ -z "$FAUSTLIB" -o -z "$FAUSTINC" ]; then 
	echo "ERROR : $0 cannot find Faust directories (normally /usr/local/include/faust and /usr/local/share/faust)"; 
	exit 1;
fi