source: optimize/optimize_functions@ 2c2471d

experimental
Last change on this file since 2c2471d was 2c2471d, checked in by Manuel Canales Esparcia <manuel@…>, 19 years ago

Added optimize/optimize_functions.

  • Property mode set to 100644
File size: 600 bytes
Line 
1#!/bin/bash
2
3# $Id$
4
5set +e
6
7
8#----------------------------------#
9wrt_optimize() { # Apply pkg specific opt's to build
10#----------------------------------#
11 local pkg=$1
12 local optLvl optVal OPT_VAR
13
14 optLvl=`awk -v pkg="$pkg" '$1 == pkg { print $2 }' $JHALFSDIR/opt_override`
15 if [[ "$optLvl" = "" ]] ; then
16 optLvl=$DEF_OPT_LVL;
17 fi
18
19 for OPT_VAR in $ACTIVE_OPT_VARS ; do
20 eval optVal=\$${OPT_VAR}_$optLvl
21
22 if [[ "$optVal" != "unset" ]]; then
23(
24cat << EOF
25 @echo "export $OPT_VAR=\"$optVal\"" >> envars
26EOF
27) >> $MKFILE.tmp
28 else
29 continue
30 fi
31 done
32}
Note: See TracBrowser for help on using the repository browser.