[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[UDUNITS #BRT-487845]: udunits problem when running cfchecks



Si Liu,

The "expat" package is bundled with the UDUNITS-2 package but is not built and 
installed if the "expat" package is already on the computer (the configure(1) 
searches for the symbol XML_StopParser in the system libraries). Apparently, 
you already have an installed "expat" library.

You might look for the "expat" library and include its directory in your 
LD_LIBRARY_PATH.

> Dear Unidata support team,
> 
> I got a udunits2 error when working with cfchecks:
> 
> cfchecks ~/Examples/NCL/training2012/input.nc
> 
> Traceback (most recent call last):
> File
> "/glade/apps/opt/python/2.7.3/gnu-westmere/4.7.2/bin/cfchecks", line
> 8, in <module>
> load_entry_point('cfchecker==2.0.3', 'console_scripts',
> 'cfchecks')()
> File
> "/glade/apps/opt/python/2.7.3/gnu-westmere/4.7.2/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg/pkg_resources.py",
> line 318, in load_entry_point
> File
> "/glade/apps/opt/python/2.7.3/gnu-westmere/4.7.2/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg/pkg_resources.py",
> line 2221, in load_entry_point
> File
> "/glade/apps/opt/python/2.7.3/gnu-westmere/4.7.2/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg/pkg_resources.py",
> line 1954, in load
> File
> "/glade/apps/opt/python/2.7.3/gnu-westmere/4.7.2/lib/python2.7/site-packages/cfchecker/__init__.py",
> line 2, in <module>
> from cfchecker.cfchecks import getargs, CFChecker
> File
> "/glade/apps/opt/python/2.7.3/gnu-westmere/4.7.2/lib/python2.7/site-packages/cfchecker/cfchecks.py",
> line 48, in <module>
> udunits=CDLL("libudunits2.so")
> File
> "/glade/apps/opt/python/2.7.3/gnu-westmere/4.7.2/lib/python2.7/ctypes/__init__.py",
> line 365, in __init__
> self._handle = _dlopen(self._name, mode)
> OSError: /glade/apps/opt/udunits/2.1.24/gnu/4.7.2/lib/libudunits2.so:
> undefined symbol: XML_ParserCreate
> 
> FYI, I have manually put the path of libudunits2 in my LD_LIBRARY_PATH
> siliu@yslogin2:~/Packages/udunit0-2.1.24/udunits-2.1.24_GNU446> echo
> $LD_LIBRARY_PATH
> /ncar/opt/lsf/8.3/linux2.6-glibc2.3-x86_64/lib:/glade/apps/opt/udunits/2.1.24/gnu/4.7.2/lib
> 
> I searched the error information online and found the following
> discussion from the unidata forum:
> http://www.unidata.ucar.edu/support/help/MailArchives/udunits/msg00802.html
> But I can not figure out the exact solution.
> 
> Here is how I compiled my udunits-2.1.24:
> export cc=gcc
> export CXX=g++
> export F77=gfortran
> libtoolize --force --copy
> ./configure --prefix=/glade/u/home/siliu/udunits/2.1.24/gnu/4.7.2
> 
> I also checked my library directory:
> siliu@yslogin2:~/udunits/2.1.24/gnu/4.7.2> ls lib
> libudunits2.a  libudunits2.la  libudunits2.so  libudunits2.so.0
> libudunits2.so.0.1.0
> 
> siliu@yslogin2:~/udunits/2.1.24/gnu/4.7.2> nm lib/libudunits2.so |
> grep XML
> U XML_ErrorString
> U XML_GetBase
> U XML_GetCurrentColumnNumber
> U XML_GetCurrentLineNumber
> U XML_GetErrorCode
> U XML_Parse
> U XML_ParserCreate
> U XML_ParserFree
> U XML_SetBase
> U XML_SetCharacterDataHandler
> U XML_SetElementHandler
> U XML_SetXmlDeclHandler
> U XML_StopParser
> I want to know how I can have these symbols defined when installing
> udunits2.
> 
> Another problem that confused me is that I had some old installation
> of udunits2.
> It contains libexpat.so under "lib". (It does not work for cfchecks as
> well. )
> Should I get libexpat when installing udunits2?
> 
> ls /glade/apps/opt/udunits/2.1.24/gnu/4.4.6/lib
> libexpat.a  libexpat.la  libexpat.so  libexpat.so.0  libexpat.so.0.0.0
> libudunits2.a  libudunits2.la  libudunits2.so  libudunits2.so.0
> libudunits2.so.0.1.0
> 
> Thank you for your help in advance.
> 
> Best wishes,
> Sincerely Si Liu
> NCAR CISL Consultant
> 
> 
> 
> Si Liu
> Consulting Services Group
> NCAR Computational & Information Services Laboratory
> Knowledge Management Chair of SEA
> Office: Mesa Lab, Room 51A
> Phone: (303) 497-2430


Regards,
Steve Emmerson

Ticket Details
===================
Ticket ID: BRT-487845
Department: Support UDUNITS
Priority: Normal
Status: Closed