diff --git a/www/Makefile b/www/Makefile new file mode 100644 index 0000000000..9a2e76e095 --- /dev/null +++ b/www/Makefile @@ -0,0 +1,44 @@ +ACTION=@echo preprocessing $@; rm -f $@; fcpp -WWW -Uunix -H -C -V -LL >$@ + +SRC := $(wildcard *.t) +OBJS := $(SRC:%.t=%.html) + +.SUFFIXES: .t .html + +%.html : %.t + $(ACTION) $< + +all: $(OBJS) descramble descramble.static.bz2 sh2d sh2d.static.bz2 \ + scramble scramble.static.bz2 + @(cd schematics; $(MAKE)) + @(cd docs; $(MAKE)) + @(cd mods; $(MAKE)) + +main.html: main.t activity.html + +descramble: descramble.c + cc -Wall -ansi -O2 -s -o $@ $< + chmod a+r descramble + +descramble.static.bz2: descramble.c + cc -static -O2 -s -o descramble.static $< + bzip2 -f descramble.static + chmod a+r descramble.static.bz2 + +scramble: scramble.c + cc -Wall -ansi -O2 -s -o $@ $< + chmod a+r scramble + +scramble.static.bz2: scramble.c + cc -static -O2 -s -o scramble.static $< + bzip2 -f scramble.static + chmod a+r scramble.static.bz2 + +sh2d: sh2d.c + cc -O2 -s -o $@ $< + chmod a+r sh2d + +sh2d.static.bz2: sh2d.c + cc -static -O2 -s -o sh2d.static $< + bzip2 -f sh2d.static + chmod a+r sh2d.static.bz2 diff --git a/www/activity.t b/www/activity.t new file mode 100644 index 0000000000..eabd0be18b --- /dev/null +++ b/www/activity.t @@ -0,0 +1,12 @@ +#define STATUS(_a_,_b_,_c_) \ +
Person | Activity | Current status |
---|---|---|
+In this example I will assume that you are running Linux with the bash shell. +We will only build the C compiler along with the assembler, linker and stuff. +
+You will need the following archives: +
+
+ /home/linus> tar zxf binutils-2.11.tar.gz + /home/linus> tar zxf gcc-3.0.3.tar.gz + /home/linus> tar zxf newlib-1.10.0.tar.gz + /home/linus> tar zxf gdb-5.1.1.tar.gz ++
+
+ /home/linus> mkdir build + /home/linus> cd build + /home/linus/build> mkdir binutils + /home/linus/build> mkdir gcc + /home/linus/build> mkdir gdb ++
+The GCC configuration script finds the newlib and libgloss files if they are in the GCC tree. Let's create two soft links. +
+ /home/linus> cd gcc-3.0.3 + /home/linus/gcc-3.0.3> ln -s ../newlib-1.10.0/newlib . + /home/linus/gcc-3.0.3> ln -s ../newlib-1.10.0/libgloss . ++
+Now is the time to decide where you want the tools to be installed. This is +the directory where all binaries, libraries, man pages and stuff end up when +you do "make install". +
+In this example I have chosen "/home/linus/sh1" as my installation directory, or prefix as it is called. Feel free to use any prefix, like +/usr/local/sh1 for example. +
+We will start with building the binutils (the assembler, linker and stuff). +This is pretty straightforward. We will be installing the whole tool chain +in the /home/linus/sh1 directory. +
+ /home/linus> cd build/binutils + /home/linus/build/binutils> ../../binutils-2.11/configure --target=sh-elf --prefix=/home/linus/sh1 + /home/linus/build/binutils> make + /home/linus/build/binutils> make install ++
+Now you are ready to build GCC. To do this, you must have the newly built +binutils in the PATH. +
+ /home/linus> export PATH=/home/linus/sh1/bin:$PATH + /home/linus> cd build/gcc + /home/linus/gcc> ../../gcc-3.0.3/configure --target=sh-elf --prefix=/home/linus/sh1 --with-newlib --enable-languages=c + /home/linus/build/binutils> make + /home/linus/build/binutils> make install ++
+If you are planning to debug your code with GDB, you have to build it as well. +
+ /home/linus> export PATH=/home/linus/sh1/bin:$PATH + /home/linus> cd build/gdb + /home/linus/gdb> ../../gdb-5.1.1/configure --target=sh-elf --prefix=/home/linus/sh1 + /home/linus/build/binutils> make + /home/linus/build/binutils> make install ++
+If someone up there likes you, you now have a working tool chain for SH1. +To compile a file with gcc: +
+ /home/linus> sh-elf-gcc -c main.o main.c ++Good luck! +
+Linus + +#include "foot.t" diff --git a/www/foot.t b/www/foot.t new file mode 100644 index 0000000000..459aa2d339 --- /dev/null +++ b/www/foot.t @@ -0,0 +1,4 @@ +