File: ff-get-dep.in

package info (click to toggle)
freefem%2B%2B 3.61.1%2Bdfsg1-4
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 17,108 kB
  • sloc: cpp: 141,214; ansic: 28,664; sh: 4,925; makefile: 3,142; fortran: 1,171; perl: 844; awk: 290; php: 199; pascal: 41; f90: 32
file content (38 lines) | stat: -rwxr-xr-x 941 bytes parent folder | download | duplicates (2)
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
#!/bin/sh
# ff-c++ `./ff-get-dep -ff metis.cpp`

case "$1" in
    -dlib)
	shift
	awk -F:  '/^[\/]+ff-c[+][+]-LIBRARY-dep:/  { printf("%s",$2); exit 0;}' $@
	exit 0; 
	;;
    -dcpp)
	shift
	awk -F:  '/^[\/]+ff-c[+][+]-cpp-dep:/  { printf("%s",$2); exit 0;}' $@
	exit 0; 
	;;
    -ff)
	shift;
#  ajout  de lib  with check
	libs=`$0 -dlib $@`
	cpp=`$0 -dcpp $@`" $@"
	;;
esac 
dircommand=`dirname $0`
if [   -f "WHERE_LIBRARY-download" ] ; then
dircommand="./"
elif [   -f "$dircommand/WHERE_LIBRARY-download" ] ; then
    dirwhere=$dircommand
elif [ -f '@ff_prefix_dir@/lib/WHERE_LIBRARY-download' ] ; then
    dirwhere='@ff_prefix_dir@/lib'
else
   echo " error no WHERE_LIBRARY  file "
   exit 1;
fi
cd "$dirwhere"
wherel=WHERE_LIBRARY-download
test -f WHERE_LIBRARY-config && wherel="$wherel  WHERE_LIBRARY-config"
test -f WHERE_LIBRARY && wherel="$wherel WHERE_LIBRARY"
awk -f ff-get-dep.awk -v libs="$libs"  -v cpp="$cpp" $wherel
exit $?