added README_changes.txt
[wrffire.git] / wrfv2_fire / chem / KPP / configure_kpp
blobdce3126a2e62e607396739137cf799e20adf0297
1 #!/bin/sh
3 # much of the nice documentation for some of the options was taken from
4 # KPP's Makefile.defs. To give a little credit let's
5 cat chem/KPP/documentation/wkc_kpp.txt
8 # The name of your lexical analizer. KPP requires FLEX to be used.
9 # FLEX is a public domain lexical analizer and you can download it from
10 # http://www.gnu.org/software/flex/ or any other mirror site. If flex
11 # directory is not included in your path use the complete pathname.
13 FLEX="flex"
18 # The complete pathname of the FLEX library (libfl.a).
19 # On many systems this is: /usr/local/util/lib/flex
20 # on other systems, the path can be a bit strange
21 # FLEX_LIB_DIR=/afs/ipp-garching.mpg.de/rs_aix53/soft/gnu/lib
22 # the default is FLEX_LIB_DIR="/usr/lib"
25 # Look for flex lib dirctory
26 # if FLEX_LIB_DIR environment variable is not set then check in /usr/lib
28 if test -z "$FLEX_LIB_DIR" ; then
29 for p in /usr/lib
31 if test -d $p ; then
32 FLEX_LIB_DIR=$p
33 break
35 done
36 # fi
38 # if FLEX_LIB_DIR environment variable is not set then check in /usr/lib64
40 # if test -z "$FLEX_LIB_DIR" ; then
41 for p in /usr/lib64
43 if test -d $p ; then
44 FLEX_LIB_DIR=$p
45 break
47 done
50 # Platform independent C compiler flags. By default "-O" is used which
51 # turns on optimisation. If you are experiencing problems you may try
52 # "-g" to include debuging informations.
54 CC_FLAGS="-O"
58 export FLEX
59 export FLEX_LIB_DIR
60 export CC_FLAGS
62 echo "------------------------------------------"
63 echo " configure_kpp, settings:"
65 # see if we can find libfl.a
66 if test -e "${FLEX_LIB_DIR}/libfl.a" ; then
67 echo location of flex library: ${FLEX_LIB_DIR}/libfl.a
69 else
70 echo No libfl.a in ${FLEX_LIB_DIR}
71 echo ' check if FLEX_LIB_DIR environment variable is set correctly'
72 echo ' (FLEX_LIB_DIR should be the complete pathname of the FLEX library libfl.a)'
73 echo ' OR: Enter full path to flex library on your system'
74 read FLEX_LIB_DIR
75 if test ! -e ${FLEX_LIB_DIR}/libfl.a ; then
76 echo PROBLEM: libfl.a NOT FOUND IN ${FLEX_LIB_DIR}
77 read FLEX_LIB_DIR
78 fi
84 # get SCC from configure.wrf
86 PCC=`grep -e CC ./configure.wrf | grep -v make | grep -e "=" | grep -v SCC | grep -v TOOLS`
87 PSCC=`grep -e SCC ./configure.wrf | grep -v make | grep -e "="`
90 ##PSCC="SCC = cc"
92 export PCC
93 export PSCC
96 echo $PCC
97 echo $PSCC
98 echo writing chem/${WKC_DIRNAME}/configure.kpp
99 pwd
100 echo "-----------------------------------------"
104 cat <<END1 >chem/${WKC_DIRNAME}/configure.kpp
106 # This file was automatically written by the configure_kpp script
107 # MANUAL CHANGES WILL BE LOST !
109 # this file is in parts based on the original Makefile.defs from KPP
113 $PCC
114 $PSCC
117 YACC=yacc -d
120 # The name of your lexical analizer. KPP requires FLEX to be used.
121 # FLEX is a public domain lexical analizer and you can download it from
122 # http://www.gnu.org/software/flex/ or any other mirror site. If flex
123 # directory is not included in your path use the complete pathname.
126 FLEX=$FLEX
129 # The complete pathname of the FLEX library (libfl.a).
130 # On many systems this is: /usr/local/util/lib/flex
131 FLEX_LIB_DIR = $FLEX_LIB_DIR
138 CC_FLAGS=$CC_FLAGS
140 ##############################################################################
142 END1
144 exit