#!/bin/sh

CS=gmcs

SOURCES="EncodedRectangleFactory.cs
Encodings/RawRectangle.cs
Encodings/ZrleRectangle.cs
Encodings/RreRectangle.cs
Encodings/EncodedRectangle.cs
Encodings/HextileRectangle.cs
Encodings/CopyRectRectangle.cs
Encodings/ZlibRectangle.cs
Encodings/CoRRE.cs
Encodings/CoRreRectangle.cs
Framebuffer.cs
Properties/AssemblyInfo.cs
Readers/BigEndianBinaryReader.cs
Utils/Robot.cs
Utils/ScreenTree/QuadTree.cs
Utils/ScreenTree/QuadNode.cs
Utils/ScreenHandler.cs
Utils/PixelGrabber.cs
Utils/Rectangle2.cs
VncHost.cs
VncServer.cs
Writers/BigEndianBinaryWriter.cs
Writers/ZlibCompressedWriter.cs"

ulimit -s 8192
set -x
exec $CS -debug -unsafe -target:library $SOURCES -out:NVNC.dll -r:zlib.net.dll -r:System.Drawing.dll -r:System.Windows.Forms.dll
