14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Megatest. If not, see <http://www.gnu.org/licenses/>.
# Configure the build
#======================================================================
# Configure stuff needed for eggs
#======================================================================
function configure_dependencies () {
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Megatest. If not, see <http://www.gnu.org/licenses/>.
# Configure the build
if [[ "$1"x == "x" ]];then
PREFIX=$PWD
else
PREFIX=$1
fi
if [[ -e /usr/bin/sw_vers ]]; then
ARCHSTR=$(/usr/bin/sw_vers -productVersion)
else
ARCHSTR=$(lsb_release -sr)
fi
#======================================================================
# Arch dependent stuff
#======================================================================
# IUP Arch key
case $ARCHSTR in
18.04)
IUPARCH=415
CDVER=5.12
IMVER=3.13
IUPVER=3.28
IUPEGGVER=":1.9.0"
;;
dunno)
IUPARCH=44
CDVER=5.12
IMVER=3.13
IUPVER=3.28
;;
*)
IUPARCH=26g4
CDVER=5.10
IMVER=3.11
IUPVER=3.19.1
IUPEGGVER=
;;
esac
#======================================================================
# Required software checks
#======================================================================
if [[ ! $(type fossil) ]];then
echo "Please install fossil from http://fossil-scm.org"
exit 1
fi
#======================================================================
# Configure stuff needed for eggs
#======================================================================
function configure_dependencies () {
|
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
}
#======================================================================
# Initialize makefile.inc
#======================================================================
echo "" > makefile.inc
#======================================================================
# Do we need Chicken?
#======================================================================
if [[ ! $(type csi) ]];then
echo "Chicken build needed."
echo "BUILD_CHICKEN=yes" >> makefile.inc
configure_dependencies
echo "include chicken.makefile" >> makefile.inc
fi
echo "All done creating makefile.inc, feel free to edit it!"
|
>
>
>
>
>
>
>
>
>
>
>
|
>
>
>
>
|
>
>
>
>
>
>
>
>
|
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
|
}
#======================================================================
# Initialize makefile.inc
#======================================================================
echo "" > makefile.inc
echo "" > makefile2.inc
#======================================================================
# Do we need Chicken?
#======================================================================
CHICKEN_PREFIX=$PREFIX/bin/.$ARCHSTR
echo "CHICKEN_PREFIX=$CHICKEN_PREFIX" >> makefile.inc
echo "PREFIX=$PREFIX" >> makefile.inc
echo "ARCHSTR=$ARCHSTR" >> makefile.inc
echo "IUPARCH=$IUPARCH" >> makefile.inc
echo "CDVER=$CDVER" >> makefile.inc
echo "IMVER=$IMVER" >> makefile.inc
echo "IUPVER=$IUPVER" >> makefile.inc
echo "IUPEGGVER=$IUPEGGVER" >> makefile.inc
if [[ ! $(type csi) ]];then
echo "Chicken build needed."
echo "BUILD_CHICKEN=yes" >> makefile.inc
configure_dependencies
echo "include chicken.makefile" >> makefile2.inc
else
echo "CSIPATH=$(which csi)" >> makefile.inc
echo "CKPATH=$(dirname $(dirname $CSIPATH))" >> makefile.inc
fi
# Make setup scripts
echo "#!/bin/bash" > setup.sh
echo "export PATH=$CHICKEN_PREFIX/bin:\$PATH" >> setup.sh
echo "export LD_LIBRARY_PATH=$CHICKEN_PREFIX/lib" >> setup.sh
echo 'exec "$@"' >> setup.sh
chmod a+x setup.sh
echo "setenv PATH $CHICKEN_PREFIX/bin:\$PATH" > setup.csh
echo "setenv LD_LIBRARY_PATH $CHICKEN_PREFIX/lib" >> setup.csh
echo "All done creating makefile.inc, feel free to edit it!"
echo "run \"setup.sh bash\" or source setup.csh to get PATH and LD_LIBRARY_PATH adjusted"
|