configure: error: can't find Xm (motif) library
I'm trying to configure (install and run) a program on Red Hat Enterprise Linux WS release 4 (Nahant Update 7). The last section in my failing configure log file is:
checking for X... libraries /usr/X11R6/lib64, headers /usr/X11R6/include checking whether -R must be followed by a space... neither works checking for gethostbyname... yes checking for connect... yes checking for remove... yes checking for shmat... yes checking for IceConnectionNumber in -lICE... yes checking X11/Intrinsic.h usability... yes checking X11/Intrinsic.h presence... yes checking for X11/Intrinsic.h... yes checking for X11/Intrinsic.h... (cached) yes checking Xm/Xm.h usability... yes checking Xm/Xm.h presence... yes checking for Xm/Xm.h... yes checking for Xm/Xm.h... (cached) yes checking if Xm.h defines XmSCROLL_HOR... yes checking if GL/GLwDrawA.h can be found... yes checking if GLw/GLwDrawA.h can be found... no checking if X11/GLw/GLwDrawA.h can be found... no checking for main in -lX11... yes checking for main in -lXt... yes checking for main in -lXmu... yes checking for library containing _XmStrings... no configure: error: can't find Xm (motif) library Any suggestions on how best to proceed would be greatly appreciated. Thanks. |
You will have to install 'openmotif-devel'
..... |
openmotif-devel already installed, get same configure error
Thanks for your response. I tried to install the openmotif-devel package but it seems it's already installed:
# up2date openmotif-devel Fetching Obsoletes list for channel: rhel-x86_64-ws-4... Fetching rpm headers... Name Version Rel ---------------------------------------------------------- The following packages you requested are already updated: openmotif-devel I then tried to configure my program again but I got the same failure: checking for Xm/Xm.h... (cached) yes checking if Xm.h defines XmSCROLL_HOR... yes checking if GL/GLwDrawA.h can be found... yes checking if GLw/GLwDrawA.h can be found... no checking if X11/GLw/GLwDrawA.h can be found... no checking for main in -lX11... yes checking for main in -lXt... yes checking for main in -lXmu... yes checking for library containing _XmStrings... no configure: error: can't find Xm (motif) library I'd very much appreciate any other suggestions you may have. Thanks very much. |
Sorry for misreading post #1.
Try 'rpm -ql openmotif-devel' to see that the required libXm.so is in /usr/X11R6/lib64/ . May be, you will have to make a symlink to /usr/lib64/ so it can be found ? ? Difficult to answer, with "unknown application". ..... |
Thanks again for your help. Turned out that I didn't have a 64-bit version of the openmotif-devel package installed. That, and when I tried to install that package my version of RedHat Linux said either that the package was already installed or that it was unavailable. I ended up forcing the installation using: $ up2date --arch=x86_64 -i openmotif-devel . My software packages from the CTBTO (Comprehensive Nuclear-Test-Ban Treaty Organization) now configure, compile and run!
|
if you need libXm.so.2.n you can also just download source and do:
$ cd motif-2.5.0 $ ./configure [opts] $ make $ make install $ ldconfig (you dont have to use rpm or rh binaries and separate packages - which you do depends on what you find easier) http://sourceforge.net/projects/motif250/ is Motif 2.n which works with more recent automake (year 2010+) Motif , motif 2.0-2.2 Panner support is back and optional GNU/configure now builds easy Imake is back too, Everything builds Quality Assurance Tests QUATS |
^^ the above works if your automake is year 2010+, however if your linux distro customized things greatly - they might have broken it and also all other source code - meaning your forced to use their hacked version of all software.
now to answer question , $ mdir="`find / -name libXm.so`" $ dir="`dirname $mdir`" this means configure must create files that add "-L${mdir}" to any code that links against libXm.so ./configure --with-motif-dir=${dir} First as always we say: make sure you have motif and motif-dev installed if your using "distro pkgs" (not the method shown above), the right ones from your OS (which may need to be backported - difficult - if your distro dropped suport for motif-ver that you need in their "recent release") However - the configure may not have a --with-motif option to let you tell it where motif is. In that case you'll just have to Diy. read the configure script searching for motif, if you see no rules to contend with there, check the Makefile*, and see where it "hopes to find libXm" you might see "-lXm" and "-L/usr/X11/lib" you need "-lXm" and (mdir) "-L/usr/Motif/lib" (but you may install motif anywhere, even /usr/lib, if you compiled it yourself, in which case you can tell it where to install where things are looking for it) newer X.org uses pkgconfig however no motif source code currenly makes a motif.pc (see /usr/X11/lib/pkgconfig/*.pc). you can copy a similar .pc and make one but any configure looking for Motif will not check for it, since motif "doesnt make one" -------------------- as far as "libXm" for other architecture - obviously if you have only a 64 binary for whichever app, then you need a corresponding lib64/foo.so , and if you dont you would need to find or make one |
debguy, this will be a bit difficult on
Red Hat Enterprise Linux WS release 4 rhel4 is end of life there is no support from redhat for rhel4 ( well some extra extended life support for CRITICAL security fixes until 2016) and if someone is still running a RHEL4 server it is WAY past time to upgrade to RHEL 6 or 7 |
All times are GMT -5. The time now is 09:10 AM. |