spinix-hive/build_spinix

82 lines
1.6 KiB
Plaintext
Raw Normal View History

# Clean directories and remake them
rm -rf root
mkdir root
mkdir root/bin
mkdir root/tmp
mkdir root/manpages
mkdir root/devel
mkdir root/demos
mkdir root/forth
mkdir root/scripts
# Build the boot program
./build_boot
# Copy license and startup script to root
cp license.txt root
cp src/_shellrc root/bin
# Generate _sysparm and copy to root
cd src
date +%s >_sysparm
echo -6 3 0 >>_sysparm
echo 0 0 0 >>_sysparm
echo "GPWD /" >>_sysparm
echo "LSCRIPT_FILE /bin/_shellrc" >>_sysparm
echo "P# 0" >>_sysparm
cd ..
cp src/_sysparm root
# Build the bin apps
./build_src
# Copy the devel files
cp devel/* root/devel
# Copy the man pages
cp manpages/* root/manpages
# Build lerner
cd lerner
cp ../src/sysdefs.spin .
cp ../src/exit.spin .
bstc -b -O cgru lerner.spin
cp lerner.binary ../root/demos/lerner
rm *.binary
cd ..
# Build vga512
cd vga512
cp ../src/sysdefs.spin .
cp ../src/exit.spin .
bstc -b VGA_512x384_Bitmap_Demo.spin
cp VGA_512x384_Bitmap_Demo.binary ../root/demos/vga512
rm *.binary
cd ..
# Move vgatdemo from bin to demos
mv root/bin/vgatdemo root/demos
# Copy the C demos
cp cdemos/dry/dry.binary root/demos/dry
cp cdemos/fibo/fibo.binary root/demos/fibo
cp cdemos/hello/hello.binary root/demos/hello
# Copy C filetest program
cp filetest/filetest.binary root/demos/filetest
# Copy C chess program
cp chess/chess.binary root/demos/chess
# Build pfth and copy the Forth files
cd pfth
bstc -b ospfth.spin
cp ospfth.binary ../root/bin/pfth
cp *.fth ../root/forth
cp *.txt ../root/forth
mv ../root/forth/_startup.fth ../root
cd ..
# Copy the script files
cp scripts/* root/scripts