View
@@ -1,9 +1,9 @@
#!/bin/bash
# If you are running a large number of installs back to back
# (e.g. for FwBm development), then setting this variable
# will cause apt-get and wget to use your proxy server. If
# your proxy server has a cache for static content, this can
# If you are running a large number of installs back to back
# (e.g. for FwBm development), then setting this variable
# will cause apt-get and wget to use your proxy server. If
# your proxy server has a cache for static content, this can
# save you quite a lot of download time
# export http_proxy=http://10.0.1.0:3128
@@ -29,7 +29,7 @@ fw_untar() {
echo "Running 'tar xf $@'...please wait"
tar xf "$@"
echo "Removing compressed tar file"
# use -f to avoid printing errors if they gave additional arguments
rm -f "$@"
}
@@ -42,16 +42,17 @@ fw_unzip() {
rm -f "$@"
}
# Download *.deb file and install into IROOT without using sudo
# Does not download dependant packages
#
# Download *.deb file and install into IROOT
# Caution:
# Without using sudo,
# Does not download dependant packages.
# Example: fw_apt_to_iroot <package> [<directory>]
fw_apt_to_iroot() {
DIR=${2:-$1}
echo "Downloading $1 to $IROOT"
apt-get download $1
sudo apt-get download $1
echo "Extracting $1 to $DIR"
dpkg-deb -x $1*.deb "$IROOT/$DIR" && rm $1*.deb
sudo dpkg-deb -x $1*.deb "$IROOT/$DIR" && sudo rm $1*.deb
}
# Was there an error for the current dependency?
@@ -71,15 +72,15 @@ fw_traperror () {
wd=$(pwd)
relative_wd=\$FWROOT${wd#$FWROOT}
echo "ERROR: $(echo ${bashstack[1]#$FWROOT}): Command '$command' exited with status $err (dependency=$depend) (cwd=$relative_wd)"
#echo " Function stack : ${funcstack[@]}"
#echo " Bash source stack : ${bashstack[@]}"
#echo " Bash line stack : ${linestack[@]}"
}
# Requires dependencies to come in order e.g. Nimrod before
# Jester, etc. Users should be know this
# Jester, etc. Users should be know this
# fairly well (e.g. you can't use Yaf without PHP)
fw_depends() {
@@ -108,10 +109,10 @@ fw_depends() {
touch $IROOT/prerequisites.installed; }
# Find and run the installer.sh file for this dependency
# Turn on some bash options before sourcing:
# Turn on some bash options before sourcing:
# - (x) errtrace : Print commands before they are run
# Note: A shebang is just a comment when you source a script,
# so if you need to modify the default options use
# Note: A shebang is just a comment when you source a script,
# so if you need to modify the default options use
# `set -e` instead of `#!/bin/bash -e`
if [ -f $FWROOT/toolset/setup/linux/systools/${depend}.sh ]; then
echo Installing system tool: $depend in $relative_wd
@@ -161,12 +162,12 @@ fw_depends() {
}
# Echo's 0 if file or directory exists
# To be used with or || blocks, avoids triggering our ERR
# To be used with or || blocks, avoids triggering our ERR
# trap with a return 1 statement
fw_exists() {
if [ -f $1 ] || [ -d $1 ]; then
echo 0
else
echo 1
fi
fi
}
View
@@ -16,8 +16,7 @@ echo "deb http://jenkins.mono-project.com/repo/debian sid main" | sudo tee /etc/
sudo apt-get update
# Find the most recent snapshot
#SNAPSHOT=$(apt-cache search 'mono-snapshot-.*-assemblies' | cut -d'-' -f3 | tail -1)
SNAPSHOT="20150202010831"
SNAPSHOT=$(apt-cache search 'mono-snapshot-.*-assemblies' | cut -d'-' -f3 | tail -1)
# save environment
@@ -37,16 +36,22 @@ source $IROOT/mono.installing
rm -rf $MONO_HOME && mkdir -p $MONO_HOME
# Download and extract debs
echo "모노스냅샷인스톨시작"
fw_apt_to_iroot mono-snapshot-$SNAPSHOT
fw_apt_to_iroot mono-snapshot-$SNAPSHOT-assemblies mono-snapshot-$SNAPSHOT
echo "모노스냅샷인스톨성공"
# Simplify paths
mv $MONO_HOME/opt/mono-*/* $MONO_HOME
file $MONO_HOME/bin/* | grep "POSIX shell script" | awk -F: '{print $1}' | xargs sed -i "s|/opt/mono-$SNAPSHOT|$MONO_HOME|g"
sed -i "s|/opt/mono-$SNAPSHOT|$MONO_HOME|g" $MONO_HOME/lib/pkgconfig/*.pc $MONO_HOME/etc/mono/config
sudo mv $MONO_HOME/opt/mono-*/* $MONO_HOME
echo "꿀빨아"
file $MONO_HOME/bin/* | grep "POSIX shell script" | awk -F: '{print $1}' | xargs sudo sed -i "s|/opt/mono-$SNAPSHOT|$MONO_HOME|g"
echo "크리스마스"
sudo sed -i "s|/opt/mono-$SNAPSHOT|$MONO_HOME|g" $MONO_HOME/lib/pkgconfig/*.pc $MONO_HOME/etc/mono/config
echo "멜롱"
echo "mozroots --import --sync" >> $IROOT/mono.installing
mv $IROOT/mono.installing $IROOT/mono.installed
sudo mv $IROOT/mono.installing $IROOT/mono.installed
source $IROOT/mono.installed
echo "모노 끝났어"
View
@@ -2,23 +2,32 @@
fw_depends mono
echo "!!!!!!!!!! XSP START !!!!!!!!!!"
RETCODE=$(fw_exists ${IROOT}/xsp.installed)
[ ! "$RETCODE" == 0 ] || { \
source $IROOT/xsp.installed
return 0; }
echo "!!!!!!!!!! XSP get !!!!!!!!!!"
# get
git clone git://github.com/mono/xsp
cd xsp
git checkout e272a2c006211b6b03be2ef5bbb9e3f8fefd0768
echo "!!!!!!!!!! XSP build !!!!!!!!!!"
# build
./autogen.sh --prefix=$MONO_HOME --disable-docs
echo "!!!!!!!!!! XSP build POINT1 !!!!!!!!!!"
make
make install
echo "!!!!!!!!!! XSP build POINT2 !!!!!!!!!!"
sudo make install
echo "!!!!!!!!!! XSP cleanup !!!!!!!!!!"
# cleanup
cd ..
rm -rf xsp
echo "" > $IROOT/xsp.installed
echo "!!!!!!!!!! XSP END !!!!!!!!!!"