iv.nanovega: removed unnecessary bounds checking
[iv.d.git] / README
blob923441135d67b980acd046316d4c32fc5c3a161b
1 WARNING! the policy of "being compatible with Vanilla D" is dropped.
3 vanilla D (and dmd as its reference compiler) is going to be more and
4 more broken. stupid compiler refucktoring, dropping useful features...
5 i see it as a complete disaster.
7 thus, i did a hard fork of dmd, and will not "vanilize" any modules in
8 IV anymore.
10 go get Aliced today if you want to use IV!
13 how to get Aliced
14 =================
15 it is probably not that easy, but doable. you will need vanilla dmd 2.076
16 (other versions aren't tested, and versions starting from 2.078 are outright
17 broken).
19 then do this to get Aliced source code:
20 mkdir aliced
21 cd aliced
22 git clone git://repo.or.cz/ivdmd.git dmd
23 cd dmd
24 git checkout k8
25 cd ..
26 git clone git://repo.or.cz/ivdruntime.git druntime
27 cd druntime
28 git checkout k8
29 cd ..
30 git clone git://repo.or.cz/ivdphobos.git phobos
31 cd phobos
32 git checkout k8
33 cd ..
34 git clone git://repo.or.cz/ivdtools.git tools
35 cd tools
36 git checkout k8
37 cd ..
40 to build aliced:
41 cd aliced
42 cd dmd
43 HOST_DMD=/path/to/your/dmd076/dmd make -f posix.mak
44 cd ..
45 cd druntime
46 make -f posix.mak DMD=../dmd/src/dmd
47 cd ..
48 cd phobos
49 make -f posix.mak DMD=../dmd/src/dmd
50 cd ..
53 to install aliced, execute the following shell script from aliced/ directory
54 (note that you either have to be root, or have rights to create directories in /opt/):
56 ============================================
57 #!/bin/sh
58 DMD_INSTALL_PATH=/opt/dmd
59 ARCH=32
61 aliced_dir=`pwd`
62 cd "$aliced_dir"
63 aliced_dir=`pwd`
65 if [ -f phobos/generated/linux/release/${ARCH}/libphobos2.a ]; then
66   phorel="release"
67   echo "MSG: RELEASE Phobos found!"
68 elif [ -f phobos/generated/linux/debug/${ARCH}/libphobos2.a ]; then
69   phorel="debug"
70   echo "MSG: DEBUG Phobos found!"
71 else
72   echo "wtf?! where is Phobos?!"
73   exit 1
76 mkdir $DMD_INSTALL_PATH 2>/dev/null
78 echo "copying dmd..."
79 mkdir -p $DMD_INSTALL_PATH/bin
80 cp dmd/generated/linux/release/32/dmd $DMD_INSTALL_PATH/bin
82 echo "copying runtime..."
83 cd "$aliced_dir/druntime"
84 mkdir -p $DMD_INSTALL_PATH/include/d2
85 cp -r import/* $DMD_INSTALL_PATH/include/d2
86 cd src
87 cp -ar gc $DMD_INSTALL_PATH/include/d2
89 echo "copying phobos..."
90 cd "$aliced_dir/phobos"
91 mkdir -p $DMD_INSTALL_PATH/lib
92 cp -va generated/linux/$phorel/${ARCH}/libphobos2.a $DMD_INSTALL_PATH/lib
93 rm $DMD_INSTALL_PATH/lib/*.o 2>/dev/null
94 cp -ar std $DMD_INSTALL_PATH/include/d2
95 cp -ar etc $DMD_INSTALL_PATH/include/d2
96 rm -rf $DMD_INSTALL_PATH/include/d2/std/experimental 2>/dev/null
98 ( cat <<EOT
99 [Environment]
100 ; the special name %@P% is replaced with the path to this file.
101 DFLAGS=-defaultlib=libphobos2.a -I%@P%/../include/d2 -L-L%@P%/../lib -L--no-warn-search-mismatch -L--export-dynamic -L--demangle=dlang
103 ) >$DMD_INSTALL_PATH/bin/dmd.conf
105 echo "compiling rdmd..."
106 cd "$aliced_dir/tools"
107 $DMD_INSTALL_PATH/bin/dmd -conf=$DMD_INSTALL_PATH/bin/dmd.conf -O -release -of$DMD_INSTALL_PATH/bin/rdmd rdmd.d rpkgman.d -L-s -wi
108 rm $DMD_INSTALL_PATH/bin/*.o 2>/dev/null
110 strip -s $DMD_INSTALL_PATH/bin/* 2>/dev/null
112 cd "$aliced_dir"
113 ============================================
116 now you should have a fully functional Aliced compiler (still named dmd for historical reasons).
117 if you can't figure out what to change in case the script is not working, or what to do next,
118 Aliced is probably not for you. go get vanilla dmd.
120 and no, dub is not supported, and never will be.
123 ok, some last words. to use IV with rdmd, clone IV like this:
125   mkdir /opt/dlibs
126   git clone git://repo.or.cz/iv.d.git /opt/dlibs/iv
128 and add "-I/opt/dlibs" to 'dmd.conf' creation part in Aliced install script.
129 it is advisable to add "-J/opt/dlibs/iv" too.
131 note that it is IMPORTANT to clone IV in the way that it lands in iv/ directory,
132 and to -I a directory of one level upper than iv/.
134 also, it is VERY convenient to clone Adam D. Ruppe's ARSD repo too (i'm using it alot):
136   git clone https://github.com/adamdruppe/arsd.git /opt/dlibs/arsd
138 there is nothing to add to 'dmd.conf' at this stage (only /opt/dlibs is required, and we
139 already added it.)