aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/libgcrypt/libgcrypt-1.2.2/autogen.sh
diff options
context:
space:
mode:
authorJay Threeth2011-04-04 11:48:26 -0700
committerJay Threeth2011-04-04 11:48:26 -0700
commit3c9cc506f741b980565ff5b3b001cd8b6ee36b12 (patch)
treecb862c57b3d5f74177cde3bd962a53fc377166f6 /linden/indra/libgcrypt/libgcrypt-1.2.2/autogen.sh
parentbuild fixes, might build on linux now (diff)
downloadmeta-impy-3c9cc506f741b980565ff5b3b001cd8b6ee36b12.zip
meta-impy-3c9cc506f741b980565ff5b3b001cd8b6ee36b12.tar.gz
meta-impy-3c9cc506f741b980565ff5b3b001cd8b6ee36b12.tar.bz2
meta-impy-3c9cc506f741b980565ff5b3b001cd8b6ee36b12.tar.xz
add source to libraries, and cruft for building under windows
Diffstat (limited to '')
-rwxr-xr-xlinden/indra/libgcrypt/libgcrypt-1.2.2/autogen.sh153
1 files changed, 153 insertions, 0 deletions
diff --git a/linden/indra/libgcrypt/libgcrypt-1.2.2/autogen.sh b/linden/indra/libgcrypt/libgcrypt-1.2.2/autogen.sh
new file mode 100755
index 0000000..96720e7
--- /dev/null
+++ b/linden/indra/libgcrypt/libgcrypt-1.2.2/autogen.sh
@@ -0,0 +1,153 @@
1#! /bin/sh
2# Run this to generate all the initial makefiles, etc.
3#
4# Copyright (C) 2003, 2004 g10 Code GmbH
5#
6# This file is free software; as a special exception the author gives
7# unlimited permission to copy and/or distribute it, with or without
8# modifications, as long as this notice is preserved.
9#
10# This program is distributed in the hope that it will be useful, but
11# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
12# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13
14configure_ac="configure.ac"
15
16cvtver () {
17 awk 'NR==1 {split($NF,A,".");X=1000000*A[1]+1000*A[2]+A[3];print X;exit 0}'
18}
19
20check_version () {
21 if [ `("$1" --version || echo "0") | cvtver` -ge "$2" ]; then
22 return 0
23 fi
24 echo "**Error**: "\`$1\'" not installed or too old." >&2
25 echo ' Version '$3' or newer is required.' >&2
26 [ -n "$4" ] && echo ' Note that this is part of '\`$4\''.' >&2
27 DIE="yes"
28 return 1
29}
30
31DIE=no
32
33
34# Used to cross-compile for Windows.
35if test "$1" = "--build-w32"; then
36 tmp=`dirname $0`
37 tsdir=`cd "$tmp"; pwd`
38 shift
39 if [ ! -f $tsdir/config.guess ]; then
40 echo "$tsdir/config.guess not found" >&2
41 exit 1
42 fi
43 build=`$tsdir/config.guess`
44
45 [ -z "$w32root" ] && w32root="$HOME/w32root"
46 echo "Using $w32root as standard install directory" >&2
47
48 # See whether we have the Debian cross compiler package or the
49 # old mingw32/cpd system
50 if i586-mingw32msvc-gcc --version >/dev/null 2>&1 ; then
51 host=i586-mingw32msvc
52 crossbindir=/usr/$host/bin
53 else
54 host=i386--mingw32
55 if ! mingw32 --version >/dev/null; then
56 echo "We need at least version 0.3 of MingW32/CPD" >&2
57 exit 1
58 fi
59 crossbindir=`mingw32 --install-dir`/bin
60 # Old autoconf version required us to setup the environment
61 # with the proper tool names.
62 CC=`mingw32 --get-path gcc`
63 CPP=`mingw32 --get-path cpp`
64 AR=`mingw32 --get-path ar`
65 RANLIB=`mingw32 --get-path ranlib`
66 export CC CPP AR RANLIB
67 fi
68
69 if [ -f "$tsdir/config.log" ]; then
70 if ! head $tsdir/config.log | grep "$host" >/dev/null; then
71 echo "Pease run a 'make distclean' first" >&2
72 exit 1
73 fi
74 fi
75
76 ./configure --enable-maintainer-mode --prefix=${w32root} \
77 --host=i586-mingw32msvc --build=${build} \
78 --with-gpg-error-prefix=${w32root} \
79 --disable-shared
80
81 exit $?
82fi
83
84
85
86
87# Grep the required versions from configure.ac
88autoconf_vers=`sed -n '/^AC_PREREQ(/ {
89s/^.*(\(.*\))/\1/p
90q
91}' ${configure_ac}`
92autoconf_vers_num=`echo "$autoconf_vers" | cvtver`
93
94automake_vers=`sed -n '/^min_automake_version=/ {
95s/^.*="\(.*\)"/\1/p
96q
97}' ${configure_ac}`
98automake_vers_num=`echo "$automake_vers" | cvtver`
99
100#gettext_vers=`sed -n '/^AM_GNU_GETTEXT_VERSION(/ {
101#s/^.*(\(.*\))/\1/p
102#q
103#}' ${configure_ac}`
104#gettext_vers_num=`echo "$gettext_vers" | cvtver`
105
106
107if [ -z "$autoconf_vers" -o -z "$automake_vers" ]
108then
109 echo "**Error**: version information not found in "\`${configure_ac}\'"." >&2
110 exit 1
111fi
112
113# Allow to override the default tool names
114AUTOCONF=${AUTOCONF_PREFIX}${AUTOCONF:-autoconf}${AUTOCONF_SUFFIX}
115AUTOHEADER=${AUTOCONF_PREFIX}${AUTOHEADER:-autoheader}${AUTOCONF_SUFFIX}
116
117AUTOMAKE=${AUTOMAKE_PREFIX}${AUTOMAKE:-automake}${AUTOMAKE_SUFFIX}
118ACLOCAL=${AUTOMAKE_PREFIX}${ACLOCAL:-aclocal}${AUTOMAKE_SUFFIX}
119
120#GETTEXT=${GETTEXT_PREFIX}${GETTEXT:-gettext}${GETTEXT_SUFFIX}
121#MSGMERGE=${GETTEXT_PREFIX}${MSGMERGE:-msgmerge}${GETTEXT_SUFFIX}
122
123
124if check_version $AUTOCONF $autoconf_vers_num $autoconf_vers ; then
125 check_version $AUTOHEADER $autoconf_vers_num $autoconf_vers autoconf
126fi
127if check_version $AUTOMAKE $automake_vers_num $automake_vers; then
128 check_version $ACLOCAL $automake_vers_num $autoconf_vers automake
129fi
130#if check_version $GETTEXT $gettext_vers_num $gettext_vers; then
131# check_version $MSGMERGE $gettext_vers_num $gettext_vers gettext
132#fi
133
134if test "$DIE" = "yes"; then
135 cat <<EOF
136
137Note that you may use alternative versions of the tools by setting
138the corresponding environment variables; see README.CVS for details.
139
140EOF
141 exit 1
142fi
143
144echo "Running aclocal -I m4 ${ACLOCAL_FLAGS:+$ACLOCAL_FLAGS }..."
145$ACLOCAL -I m4 $ACLOCAL_FLAGS
146echo "Running autoheader..."
147$AUTOHEADER
148echo "Running automake --gnu ..."
149$AUTOMAKE --gnu;
150echo "Running autoconf..."
151$AUTOCONF
152
153echo "You may now run \"./configure --enable-maintainer-mode && make\"."