Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <2017 Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <2017
<== Date ==> <== Thread ==>

Subject: Notes on building EDM for Linux Mint 17
From: <>
To: <>
Date: Thu, 16 Feb 2017 15:28:04 +0000
As I found building EDM from source was not a particularly simple task I have listed here the most important steps I took, many of which I collected together from several other tech talk posts.  In future perhaps it would be possible to adjust the makefiles to eliminate some to the extra steps I describe below?

The system I built EDM on is an Acer Travel Mate 8371G running 64 bit Linux Mint 17.3 (Rosa) 

My installation used the following EPICS versions

EDM version 105 contains the extra NULL argument in calls to DGifOpenFileName( name ) and DGifCloseFile( gif ) in  If an older version of EDM is to be built then there is a patch provided with version 105 that can be applied to earlier versions.

baseR3.14.12.6.tar.gz and extensionsTop_20120904.tar.gz are unzipped into ~/epics and edm-1-12-105.tgz is unzipped into ~/epics/extensions/src

I recommend initiating a git project in ~/epics to keep track of any modifications you try in your make and config files. You will need to add the object and binary folders generated by the build processes to your .gitignore file to enable you to just track the changes that you initiate and not track the many files and folders created by make. I also recommend the use of remake rather than make to run all the source builds as remake provides more detail on any make file problems and also allows full debug facilities in the make process if any problems are encountered.  However these are just my personal preferences and not essential for the following steps.

The Linux Mint distribution will require several development libraries to be installed to avoid one or more missing header file messages causing the make process to fail.  I believe I have listed all those required with the relevant build steps below.

A build of EDM requires EPICS base to be built first. Base requires the following development libraries to be installed on Mint 17 before initiating the make file:
libreadline-dev libgif-dev 

Using remake and keeping a record of all the build messages in a log file bild1, I then issued the following command to build base from my working directory in ~/epics/base-

sudo remake  2>&1 | tee build1

No errors were encountered and in  ~/epics/base- a total of 49 executable and perl files were created indicating a successful build.

I then created a soft link to /base using

ln -s ~/epics/base- ~/epics/base

Before building EDM the following additional libraries must be installed:
libxtst-dev libmotif-dev libxt-dev libxmu-dev libpng-dev libxp-dev libgif-dev

Some library file locations must also be adjusted in 
 ~/epics/extensions/configure/os/CONFIG_SITE.linux-x86_64.linux-x86_64 as follows:

by default the following library file locations are referenced

edit these as follows:

Further changes to the libraries referenced by ~/epics/extensions/src/edm/giflib are also required, edit references to ungif in Makefile.Host and Makefile to refer instead to gif

Finally the Makefile in ~/epics/extensions/src/edm/src/edmMain needs a small edit, locate the line
    edm_LIBS_Linux += Xm Xmu Xt Xp Xtst X11
and add the extra line
    USR_LDFLAGS_Linux += -Wl,--no-as-needed
Not doing this last edit will cause edm to crash with the following error messages after it is built and launched:
X error: code=3, msg: BadWindow (invalid Window parameter)
X error: code=3, msg: BadWindow (invalid Window parameter)
X error: code=3, msg: BadWindow (invalid Window parameter)
Error: No realize class procedure defined

Now it should be possible to run the build of edm without any fatal errors, move your working directory to 
~/epics/extensions/src/edm and build edm using 
sudo remake EPICS_HOST_ARCH=linux-x86_64 2>&1 | tee build2

Again I suggest the use of remake for more information and keeping the makefile log as build2.  You should now find a newly built edm binary in  ~/epics/extensions/bin/linux-x86_64

It is now necessary to build the edmObjects and edmPvObjects lists using the script in ~/epics/extensions/src/edm/setup/

Move your working directory to 
then enter the commands
export HOST_ARCH=linux-x86_64

This should generate the required files, now have a look at the default fonts.list in the /setup directory, it will probably not list any of the fonts available by default in Mint Mate.  I found instead that the following list was sufficient to get started:

3 0 0

Note you can extend this list with the help of the xfontsel utility, launch this and explore the fonts that are available by selecting one of the options under -fndry- then select fonts that have both a regular and italic or oblique variant under -slant and also a medium and bold weight under -wght- Once you have found a suitable font family to add follow the structure listed in the example above including the two font weights in brackets and the slant options in brackets and finally the point size -ptSz- in brackets. 

For initial testing it is advisable to launch edm from a shell script that also exports the key environment variables needed by EDM, the following is an example of a script that I used for initial testing:

# EPICS Environment
EPICS_CA_ADDR_LIST=""  #  <- <- change this line to the IP address of your IOC if you have one running

# EDM Environment
EDMHELPFILES=$EPICS_EXTENSIONS/src/edm/helpFiles  # Location of the help files. helpMain.edl in there is opened.
EDMFILES=$EPICS_EXTENSIONS/edmobjects  # Location of fonts.list and colors.list. 
EDMDATAFILES=/home/epics  # Location of display files given as a search path similar to the PATH variable. Example
LD_LIBRARY_PATH=$EDMLIBS:$EPICS_BASE/lib/$EPICS_HOST_ARCH # location of the edm shared library files *.so
echo "PATH =$PATH "
edm -m user=$USER &

Finally, before running the test script to launch edm, if you have a edmPrintDef printer definition file copy it to =$EPICS_EXTENSIONS/src/edm/setup alternatively copy the one provided in $EPICS_EXTENSIONS/src/edm/edmMain

It should now be possible to launch edm from the shell script with few if any font warning messages and begin live testing.

Bob Anderson, ISIS LINAC RF Section
STFC Rutherford Appleton Laboratory
Building R12, Room 15B
Harwell Science and Innovation Campus
OX11 0QX
Telephone (Direct dial) 01235-567112
RAL Mobile 0779-504-6410

Navigate by Date:
Prev: Re: IOC Connecting Problem Rod Nussbaumer
Next: Re: How access to an array value from a process variable using ca_array_get()? J. Lewis Muir
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <2017
Navigate by Thread:
Prev: Re: EDM compiling problems Mike Westfall
Next: EDM install on fedora20-64 bit system problem: " cannot open shared object file: No such file or directory" lzf neu
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  <2017
ANJ, 16 Feb 2017 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·