]> andersk Git - gssapi-openssh.git/blame - nmi/testscript
always build in a clean directory
[gssapi-openssh.git] / nmi / testscript
CommitLineData
365b751e 1#!/bin/sh
2set -e # exit on any error
365b751e 3GLOBUS_LOCATION=$_CONDOR_SCRATCH_DIR/globus
753b352b 4ZLIB_LOCATION=$_CONDOR_SCRATCH_DIR/zlib
365b751e 5LOGNAME=$USER
6X509_CERT_DIR=$GLOBUS_LOCATION/share/certificates
7export GLOBUS_LOCATION LOGNAME X509_CERT_DIR
8(
e4500fc3 9if test -n "${_NMI_PREREQ_openssl_0_9_8k_shared_ROOT}"; then
10 PKG_CONFIG_PATH="${_NMI_PREREQ_openssl_0_9_8k_shared_ROOT}/lib/pkgconfig"
11 OPENSSL_CFLAGS="-I${_NMI_PREREQ_openssl_0_9_8k_shared_ROOT}/include"
12 OPENSSL_INCLUDES="-I${_NMI_PREREQ_openssl_0_9_8k_shared_ROOT}/include"
13 OPENSSL_LDFLAGS="-L${_NMI_PREREQ_openssl_0_9_8k_shared_ROOT}/lib"
14 OPENSSL_LIBS="-lssl -lcrypto"
15 export PKG_CONFIG_PATH
16 export OPENSSL_CFLAGS OPENSSL_INCLUDES OPENSSL_LDFLAGS OPENSSL_LIBS
17elif test -n "${_NMI_PREREQ_openssl_0_9_8e_shared_ROOT}"; then
ba95588b 18 PKG_CONFIG_PATH="${_NMI_PREREQ_openssl_0_9_8e_shared_ROOT}/lib/pkgconfig"
19 OPENSSL_CFLAGS="-I${_NMI_PREREQ_openssl_0_9_8e_shared_ROOT}/include"
20 OPENSSL_INCLUDES="-I${_NMI_PREREQ_openssl_0_9_8e_shared_ROOT}/include"
21 OPENSSL_LDFLAGS="-L${_NMI_PREREQ_openssl_0_9_8e_shared_ROOT}/lib"
22 OPENSSL_LIBS="-lssl -lcrypto"
23 export PKG_CONFIG_PATH
24 export OPENSSL_CFLAGS OPENSSL_INCLUDES OPENSSL_LDFLAGS OPENSSL_LIBS
25elif test -n "${_NMI_PREREQ_openssl_0_9_7_shared_ROOT}"; then
26 PKG_CONFIG_PATH="${_NMI_PREREQ_openssl_0_9_7_shared_ROOT}/lib/pkgconfig"
27 OPENSSL_CFLAGS="-I${_NMI_PREREQ_openssl_0_9_7_shared_ROOT}/include"
28 OPENSSL_INCLUDES="-I${_NMI_PREREQ_openssl_0_9_7_shared_ROOT}/include"
29 OPENSSL_LDFLAGS="-L${_NMI_PREREQ_openssl_0_9_7_shared_ROOT}/lib"
30 OPENSSL_LIBS="-lssl -lcrypto"
31 export PKG_CONFIG_PATH
32 export OPENSSL_CFLAGS OPENSSL_INCLUDES OPENSSL_LDFLAGS OPENSSL_LIBS
33fi
34if test -n "${LD_LIBRARY_PATH}" -a -z "${LIBPATH}"; then
35 LIBPATH=$LD_LIBRARY_PATH
36 export LIBPATH
37fi
365b751e 38echo ==================================================
39echo Environment variables:
40env
41echo ==================================================
42echo Directory contents:
43ls -Rl
44echo ==================================================
9de400ec 45if test -d /prereq/zlib-1.2.3; then
46 ZLIB_LOCATION=/prereq/zlib-1.2.3
47 echo zlib found in $ZLIB_LOCATION
48else
49 echo Building zlib-1.2.3...
50 cd zlib-1.2.3
51 ./configure --prefix=$ZLIB_LOCATION
52 make
53 make install
54 cd ..
55fi
791bf08c 56for installer in `ls gt*-all-source-installer.tar.gz *nightly.tar.gz`; do
67b4c7ad 57 echo ==================================================
791bf08c 58 echo Installing Globus Toolkit \($installer\)...
59 tar xfz $installer
60 cd gt*-installer
61 ./configure --prefix=$GLOBUS_LOCATION --with-buildopts="-verbose" \
62 --with-gsiopensshargs="--with-zlib=$ZLIB_LOCATION"
63 make gsi-openssh install
64 . $GLOBUS_LOCATION/etc/globus-user-env.sh
67b4c7ad 65 cd ..
66 echo ==================================================
791bf08c 67 echo Environment variables:
68 env
69 echo ==================================================
70 GLOBUS_FLAVOR_NAME=`gpt-query -name=gsi_openssh | perl -n -e 'if (/gsi_openssh-(.*)-pgm/){print "$1\n";}'|head -1`
71 export GLOBUS_FLAVOR_NAME
72 echo GPT GLOBUS_FLAVOR_NAME is $GLOBUS_FLAVOR_NAME.
73 if test -f gsi_openssh_bundle-*.tar.gz; then
74 echo ==================================================
75 echo Building GSI-OpenSSH GPT bundle...
5a591e4f 76 rm -rf BUILD
791bf08c 77 gpt-build -force -verbose gsi_openssh_bundle-*.tar.gz $GLOBUS_FLAVOR_NAME \
bf43e758 78 GSI_OPENSSH_GPTMACRO="--with-zlib=$ZLIB_LOCATION"
bf43e758 79 fi
791bf08c 80 if test -d gssapi-openssh/openssh; then
4d997295 81 echo ==================================================
791bf08c 82 echo Installing autotools...
83 cd autotools
84 ./install-autotools $GLOBUS_LOCATION
4d997295 85 cd ..
86 echo ==================================================
5a591e4f 87 cd gssapi-openssh
88 cp -r openssh openssh.build
89 cd openssh.build
791bf08c 90 if test -f make_gpt_dist; then
91 echo Building GSI-OpenSSH GPT package from CVS...
19ba7c71 92 rm -f gsi_openssh-*.tar.gz
791bf08c 93 ./make_gpt_dist
94 gpt-build -force -verbose gsi_openssh-*.tar.gz $GLOBUS_FLAVOR_NAME \
95 GSI_OPENSSH_GPTMACRO="--with-zlib=$ZLIB_LOCATION"
96 else
97 echo Building GSI-OpenSSH from CVS trunk...
98 autoreconf
99 ./configure --prefix=$GLOBUS_LOCATION \
100 --with-globus-flavor=$GLOBUS_FLAVOR_NAME \
101 --with-zlib=$ZLIB_LOCATION \
102 --with-privsep-user=$USER --with-privsep-path=$GLOBUS_LOCATION/var/empty
103 make install-nokeys # nonroot
4d997295 104 fi
5a591e4f 105 cd ..
106 rm -rf openssh.build
107 cd ..
791bf08c 108 fi
109 rm -rf gt*-installer $GLOBUS_LOCATION
110done
365b751e 111) 2>&1 # we want stdout & stderr mixed in the output file
This page took 0.087221 seconds and 5 git commands to generate.