source: scripts/scripts/native-scripts/temp-tcl.sh @ c7ec163

clfs-1.2clfs-2.1clfs-3.0.0-systemdclfs-3.0.0-sysvinitsystemdsysvinit
Last change on this file since c7ec163 was c7ec163, checked in by Jim Gifford <clfs@…>, 18 years ago

r2473@server (orig r1230): ryan | 2006-03-06 23:56:13 -0800

r1232@rei: lfs | 2006-03-07 18:03:13 +1100
Gah, push in long forgotten changes (must sync more often)


  • Property mode set to 100755
File size: 1.7 KB
Line 
1#!/bin/bash
2
3# cross-lfs temporary tcl build (for running testsuites)
4# ------------------------------------------------------
5# $LastChangedBy$
6# $LastChangedDate$
7# $LastChangedRevision$
8# $HeadURL$
9#
10
11cd ${SRC}
12LOG=tcl-temp.log
13
14# Test if the 64 script has been called.
15# This should only really get called during bi-arch builds
16SELF=`basename ${0}`
17set_buildenv
18set_libdirname
19setup_multiarch
20
21if [ "${USE_SYSROOT}" = "Y" ]; then
22   BUILD_PREFIX=/usr
23else
24   BUILD_PREFIX=${TGT_TOOLS}
25fi
26
27unpack_tarball tcl${TCL_VER}-src &&
28cd ${PKGDIR}/unix
29
30if [ ! "${libdirname}" = "lib" ]; then
31   extra_conf="--libdir=${BUILD_PREFIX}/${libdirname}"
32
33   # Change TCL_LIBRARY in Makefile so it is under $(libdir)
34   test -f Makefile.in-ORIG || cp -p Makefile.in Makefile.in-ORIG
35   sed '/TCL_LIBRARY/s@\$(prefix)/lib@$(libdir)@g' \
36      Makefile.in-ORIG > Makefile.in
37fi
38
39max_log_init Tcl ${TCL_VER} "temp (shared)" ${CONFLOGS} ${LOG}
40CC="${CC-gcc} ${ARCH_CFLAGS}" \
41./configure --prefix=${BUILD_PREFIX} ${extra_conf} \
42   >> ${LOGFILE} 2>&1 &&
43echo " o Configure OK" &&
44
45min_log_init ${BUILDLOGS} &&
46make ${PMFLAGS} LDFLAGS="-s" \
47   >> ${LOGFILE} 2>&1 &&
48echo " o Build OK" &&
49
50min_log_init ${TESTLOGS} &&
51make test \
52   >>  ${LOGFILE} 2>&1 &&
53echo " o Test OK" &&
54# clock test may fail... not a real concern for our purposes...
55
56min_log_init ${INSTLOGS} &&
57make install \
58   >> ${LOGFILE} 2>&1 &&
59echo " o Install OK" || barf
60
61# Following for ~tcl 8.4.12
62case ${TCL_VER} in
63   8.4.1[2-9]* )
64      make install-private-headers \
65         >>  ${LOGFILE} 2>&1 &&
66      echo " o install-private-headers OK" || barf
67   ;;
68esac
69
70# Create symlink for tclsh
71TCLSH=$(basename $(find ${BUILD_PREFIX}/bin -type f -name tclsh\*))
72test "tclsh" != "${TCLSH}" &&
73   ln -sf ./${TCLSH} ${BUILD_PREFIX}/bin/tclsh
74
Note: See TracBrowser for help on using the repository browser.