How to compile LibreCAD Source Code?

Firstly, we should install all dependencies required for compiling.

sudo apt-get install g++ gcc make git-core libqt4-dev 
  qt4-qmake libqt4-help qt4-dev-tools libboost-all-dev 
  libmuparser-dev libfreetype6-dev
$ sudo apt-get build-dep librecad

Now you have a development environment on your computer. You need to download the source of LibreCAD.

The source code including the latest development of LibreCAD is available from the project page at github, ,

$mkdir librecad
$cd librecad 
$ git clone


Now you can run qmake (or qmake-qt4) to create a makefile and run make to compile LibreCAD.

Commands to run:

Make sure that you are in the folder that you created( librecad). Now change the Directory( cd)  to LibreCAD ,

$cd LibreCAD
$make is a project file. qmake creates a makefile. Make command will compile the project. Compiling LibreCAD might take a while, depending on the speed of your computer, but just let it run until it finishes.

To finally run LibreCAD, execute the following commands:

$cd unix

Note: If you got error of muparser, no file found.Replace one line in code,

#include <muParser.h>
#include “/usr/include/muParser/muParser.h”

in the file LibreCAD/librecad/src/lib/math/rs_math.cpp

Then run:

Thats all.



$mkdir librecad
$cd librecad 
$ git clone

About Priyanka Kapoor

Simple, Hardworking & friendly.....
This entry was posted in Uncategorized. Bookmark the permalink.

One Response to How to compile LibreCAD Source Code?

  1. jasleen kaur says:

    To install dependencies, you had written two commands, one is sufficient. Either give the names of dependencies you want explicitly, as in 1st command, or use 2nd if you don’t remember what dependencies you need.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s