Revision 17074,
1.9 KB
checked in by ghudson, 23 years ago
(diff) |
Punt ATHTOOLROOT support.
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | |
---|
3 | glib_libs="@glib_libs@" |
---|
4 | glib_cflags="@glib_cflags@" |
---|
5 | glib_thread_libs="@glib_thread_libs@" |
---|
6 | glib_thread_cflags="@glib_thread_cflags@" |
---|
7 | |
---|
8 | prefix=@prefix@ |
---|
9 | exec_prefix=@exec_prefix@ |
---|
10 | exec_prefix_set=no |
---|
11 | |
---|
12 | usage() |
---|
13 | { |
---|
14 | cat <<EOF |
---|
15 | Usage: gtk-config [OPTIONS] [LIBRARIES] |
---|
16 | Options: |
---|
17 | [--prefix[=DIR]] |
---|
18 | [--exec-prefix[=DIR]] |
---|
19 | [--version] |
---|
20 | [--libs] |
---|
21 | [--cflags] |
---|
22 | Libraries: |
---|
23 | gtk |
---|
24 | gthread |
---|
25 | EOF |
---|
26 | exit $1 |
---|
27 | } |
---|
28 | |
---|
29 | if test $# -eq 0; then |
---|
30 | usage 1 1>&2 |
---|
31 | fi |
---|
32 | |
---|
33 | lib_gtk=yes |
---|
34 | |
---|
35 | while test $# -gt 0; do |
---|
36 | case "$1" in |
---|
37 | -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
---|
38 | *) optarg= ;; |
---|
39 | esac |
---|
40 | |
---|
41 | case $1 in |
---|
42 | --prefix=*) |
---|
43 | prefix=$optarg |
---|
44 | if test $exec_prefix_set = no ; then |
---|
45 | exec_prefix=$optarg |
---|
46 | fi |
---|
47 | ;; |
---|
48 | --prefix) |
---|
49 | echo_prefix=yes |
---|
50 | ;; |
---|
51 | --exec-prefix=*) |
---|
52 | exec_prefix=$optarg |
---|
53 | exec_prefix_set=yes |
---|
54 | ;; |
---|
55 | --exec-prefix) |
---|
56 | echo_exec_prefix=yes |
---|
57 | ;; |
---|
58 | --version) |
---|
59 | echo @GTK_MAJOR_VERSION@.@GTK_MINOR_VERSION@.@GTK_MICRO_VERSION@ |
---|
60 | ;; |
---|
61 | --cflags) |
---|
62 | echo_cflags=yes |
---|
63 | ;; |
---|
64 | --libs) |
---|
65 | echo_libs=yes |
---|
66 | ;; |
---|
67 | gtk) |
---|
68 | lib_gtk=yes |
---|
69 | ;; |
---|
70 | gthread) |
---|
71 | lib_gthread=yes |
---|
72 | ;; |
---|
73 | *) |
---|
74 | usage 1 1>&2 |
---|
75 | ;; |
---|
76 | esac |
---|
77 | shift |
---|
78 | done |
---|
79 | |
---|
80 | if test "$echo_prefix" = "yes"; then |
---|
81 | echo $prefix |
---|
82 | fi |
---|
83 | |
---|
84 | if test "$echo_exec_prefix" = "yes"; then |
---|
85 | echo $exec_prefix |
---|
86 | fi |
---|
87 | |
---|
88 | if test "$lib_gthread" = "yes"; then |
---|
89 | glib_cflags="$glib_thread_cflags" |
---|
90 | glib_libs="$glib_thread_libs" |
---|
91 | fi |
---|
92 | |
---|
93 | if test "$echo_cflags" = "yes"; then |
---|
94 | echo -I@includedir@/gtk-1.2 $glib_cflags @x_cflags@ |
---|
95 | fi |
---|
96 | |
---|
97 | if test "$echo_libs" = "yes"; then |
---|
98 | my_glib_libs= |
---|
99 | libdirs=-L@libdir@ |
---|
100 | for i in $glib_libs ; do |
---|
101 | if test $i != -L@libdir@ ; then |
---|
102 | if test -z "$my_glib_libs" ; then |
---|
103 | my_glib_libs="$i" |
---|
104 | else |
---|
105 | my_glib_libs="$my_glib_libs $i" |
---|
106 | fi |
---|
107 | fi |
---|
108 | done |
---|
109 | |
---|
110 | echo $libdirs @x_ldflags@ -lgtk -lgdk $my_glib_libs @INTLLIBS@ @x_libs@ @GDK_WLIBS@ -lm |
---|
111 | fi |
---|
112 | |
---|
Note: See
TracBrowser
for help on using the repository browser.