forked from mneumann/rust-cross-dragonfly
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstage1-linux.sh
More file actions
executable file
·51 lines (41 loc) · 857 Bytes
/
stage1-linux.sh
File metadata and controls
executable file
·51 lines (41 loc) · 857 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
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
#!/bin/sh
if [ `uname -s` != "Linux" ]; then
echo "You have to run this on Linux!"
exit 1
fi
mkdir -p stage1-linux
cd stage1-linux
TOP=`pwd`
export CC="/usr/bin/gcc-4.8"
export CXX="/usr/bin/g++-4.8"
if [ ! -e rust ]; then
git clone https://github.com/rust-lang/rust.git
fi
cd rust
git submodule init
git submodule update
if [ ! -e .patched ]; then
patch -p1 < ${TOP}/../patch-rust
date > .patched
else
echo "Rust already patched on:" `cat .patched`
fi
./configure --prefix=${TOP}/install
cd src/jemalloc
if [ ! -e .patched ]; then
patch -p1 < ${TOP}/../patch-jemalloc
date > .patched
else
echo "jemalloc already patched on:" `cat .patched`
fi
cd ../llvm
if [ ! -e .patched ]; then
patch -p1 < ${TOP}/../patch-llvm
date > .patched
else
echo "LLVM already patched on:" `cat .patched`
fi
cd ../..
echo $PWD
make
make install