Building GUIs on Linux - nrc-cnrc/EGSnrc GitHub Wiki
If you wish to compile the Qt GUIs yourself, for example to make changes to egs_gui, egs_view, egs_inprz or egs_configure, it is necessary to install the Qt developer tools. The following are instructions to compile dynamically linked EGSnrc Qt graphical user interfaces on Linux. These instructions are meant for users that are well-acquainted with Linux terminal command and environment variables, and who can install software on their computer (otherwise, please seek support from your system administrator).
Note that qmake uses its own compiler configuration, in $QTDIR/mkspecs
Qt5 Instructions
- Ensure you have installed and configured the EGSnrc on your system.
- Install the Qt5 development tools. On Ubuntu, the required components are
build-essential qtbase5-dev qtbase5-dev-tools qttools5-dev. - Go to
$HEN_HOUSE/egs++/viewand issue themake clean; makecommand. If compilers have changed, first issuemake realclean.
To build all GUIs
- Go to
$HEN_HOUSE/guiand issue the commandmake clean; maketo build all of egs_gui, egs_inprz and egs_configure. If compilers have changed, first issuemake realcleanin each of the three subdirectories. - If the compiler complains it cannot find the
zlib.hfile, install the package that provides this basic header. On Ubuntu, for example, issue the following command in a terminal:sudo apt-get install zlib1g-dev.
To build individual GUIs
- Go to
$HEN_HOUSE/gui/egs_guiand issue themake realclean; makecommand. - Go to
$HEN_HOUSE/gui/egs_inprzand issue themake realclean; makecommand. - Go to
$HEN_HOUSE/gui/egs_configureand issue themake realclean; makecommand. - If the compiler complains it cannot find the
zlib.hfile, install the package that provides this basic header. On Ubuntu, for example, issue the following command in a terminal:sudo apt-get install zlib1g-dev.
Qt4 Instructions
In the 2018 release of the master branch, the GUIs are compatible with Qt4.
- Install the Qt4 development tools (
libqt4-devorlibqt4-develpackage in many distributions). - Define the
QTDIRenvironment variable as the path to the Qt4 development directory on your system. For example, on CentOS issue the commandexport QTDIR=/usr/lib64/qt4. On Ubuntu issueexport QTDIR=/usr/share/qt4. - Go to
$HEN_HOUSE/egs++/viewand issue themake clean; makecommand. If compilers have changed, first issuemake realclean.
To build all GUIs
- Go to
$HEN_HOUSE/guiand issue the commandmake clean; maketo build all of egs_gui, egs_inprz and egs_configure. If compilers have changed, first issuemake realcleanin each of the three subdirectories.
To build individual GUIs
- Go to
$HEN_HOUSE/gui/egs_guiand issue themake realclean; makecommand. - Go to
$HEN_HOUSE/gui/egs_inprzand issue themake realclean; makecommand. - Go to
$HEN_HOUSE/gui/egs_configureand issue themake realclean; makecommand.