1#!/bin/sh
2
3prefix=@prefix@
4exec_prefix=@exec_prefix@
5
6bindir=@bindir@
7libexecdir=@libexecdir@
8datadir=@datadir@
9sysconfdir=@sysconfdir@
10sharedstatedir=@sharedstatedir@
11localstatedir=@localstatedir@
12libdir=@libdir@
13infodir=@infodir@
14mandir=@mandir@
15includedir=@includedir@
16
17LIBS="@SYNFIG_LIBS@"
18
19VERSION=@VERSION@
20PACKAGE=@PACKAGE@
21
22CFLAGS="@CONFIG_CFLAGS@"
23
24usage()
25{
26	cat <<EOF
27Usage: synfig-config [OPTION]...
28
29Generic options
30  --version	print installed version of synfig.
31  --help        display this help and exit.
32
33Compilation support options
34  --cflags      print pre-processor and compiler flags
35  --libs        print library linking information
36  
37Install directories
38  --prefix --exec-prefix --bindir --libexecdir --datadir
39  --sysconfdir --sharedstatedir --localstatedir --libdir --infodir
40  --mandir --includedir
41
42EOF
43
44	exit 1
45}
46
47if test $# -eq 0; then
48	usage 1
49fi
50
51case $1 in
52--version)
53	echo $PACKAGE $VERSION
54	exit 0
55	;;
56--exec-prefix)
57	echo $exec_prefix
58	exit 0
59	;;
60--prefix)
61	echo $prefix
62	exit 0
63	;;
64--help)
65	usage 0
66	;;
67--cflags)
68	echo $CFLAGS
69	exit 0
70	;;
71--cxxflags)
72	echo $CFLAGS
73	exit 0
74	;;
75--libs)
76	echo $LIBS
77	exit 0
78	;;
79esac
80
81echo Unknown option "$1"
82exit 4
83