See https://github.com/LibreCAD/LibreCAD_3/wiki/Building
If we want to support associative drawings, this is a good introduction to get started:
Understanding how dimensions are associated with objects
http://cadkit.blogspot.nl/p/sample-dxf-files.html