[Insight-developers] Problem again in NRRDIO

Michel Audette michel.audette at kitware.com
Wed Mar 24 16:20:35 EDT 2010


Hi Daniel and Gordon,

in the last itk_NrrdIO_mangle.h that I sent yesterday, airStrtokQuoting was
handled as
#define airStrtokQuoting itk_airStrtokQuoting
(line 107).

Is this not what is required? What should I expect to find, and where is it
deficient now?

If I just do a match for [B], I still get
#define airStrtokQuoting itk_airStrtokQuoting
right now.

Which ones are not being picked up and fail to be converted to itk_xxx , and
which ones are wrongly being converted to itk_xxx?

Cheers,

Michel

On Tue, Mar 23, 2010 at 6:02 PM, Gordon L. Kindlmann <glk at uchicago.edu>wrote:

> Hi,
>
> Okay, so that means that the problem is fairly well-contained.  Can you try
> to debug why mangle.pl is not handling airStrtokQuoting correctly, if it
> is not appearing in itk_NrrdIO_mangle.h as it should?
>
> Gordon
>
>
> On Mar 23, 2010, at 4:41 PM, Michel Audette wrote:
>
>  Again, does not appear with underscore, but without, appears next to a
>> B...
>>
>> string.o:
>>                 U _IO_getc
>>                 U __ctype_b_loc
>>                 U __ctype_tolower_loc
>>                 U __ctype_toupper_loc
>> 0000000000000330 T airEndsWith
>>                 U airFree
>> 0000000000000000 T airOneLine
>> 00000000000004b0 T airOneLinify
>> 00000000000003a0 T airStrdup
>> 0000000000000310 T airStrlen
>> 0000000000000810 T airStrntok
>> 0000000000000720 T airStrtok
>> 0000000000000000 B airStrtokQuoting
>> 00000000000001c0 T airStrtrans
>> 0000000000000170 T airToLower
>> 0000000000000120 T airToUpper
>> 00000000000003f0 T airUnescape
>>                 U malloc
>>                 U strcpy
>>                 U strcspn
>>                 U strlen
>>                 U strncmp
>>                 U strspn
>>                 U ungetc
>>
>>
>> Michel
>>
>> On Tue, Mar 23, 2010 at 5:37 PM, Gordon L. Kindlmann <glk at uchicago.edu>
>> wrote:
>> Hi-
>>
>> Michel, can you grep for _airStrtokQuoting in the nm output and see what
>> letter code is being used?  Some other tweak to mangle.pl may be
>> required.
>>
>> Daniel, the things in your Tmp.txt are not from a svn checkout of ITK, I'm
>> guessing, so they include some older things that no longer appear in
>> libNrrdIO.  Is it okay if we ignore them for now?
>>
>> Gordon
>>
>>
>> On Mar 23, 2010, at 4:53 PM, Daniel Blezek wrote:
>>
>> Ok,  at least one symbol made it through unscathed.
>>
>> ld: duplicate symbol _airStrtokQuoting in
>> /Users/blezek/Source/Insight-macosx/bin/libITKNrrdIO.a(string.o) and
>> ../bin/libteem.a(string.o)
>>
>> Here are the non-itk procteced symbols:
>>
>> nm /Users/blezek/Source/Insight-macosx/bin/libITKNrrdIO.a | grep -v itk >
>> Tmp.txt
>>
>> + some editing.
>>
>>
>> On 3/23/10 2:33 PM, "Michel Audette" <michel.audette at kitware.com> wrote:
>>
>> Hi Daniel,
>>
>> here it is...
>>
>> Michel
>>
>> On Tue, Mar 23, 2010 at 4:29 PM, Gordon L. Kindlmann <glk at uchicago.edu>
>> wrote:
>> Hi,
>>
>> so can you try changing in mangle.pl <http://mangle.pl>
>>
>>       s|.* [TDRS] (.*)|$1|g;
>>
>> to
>>
>>       s|.* [TBDRS] (.*)|$1|g;
>>
>> and send the resulting itk_NrrdIO_mangle.h to Daniel so he can see if it
>> fixes the problem?
>>
>> Gordon
>>
>>
>>
>> On Mar 23, 2010, at 3:25 PM, Michel Audette wrote:
>>
>> defaultsNrrd.o:
>> 0000000000000010 D nrrdDefaultCenter
>> 0000000000000018 D nrrdDefaultSpacing
>> 0000000000000004 D nrrdDefaultWriteBareText
>> 0000000000000008 D nrrdDefaultWriteCharsPerLine
>> 0000000000000000 D nrrdDefaultWriteEncodingType
>> 000000000000000c D nrrdDefaultWriteValsPerLine
>> 0000000000000020 D nrrdStateAlwaysSetContent
>> 0000000000000008 B nrrdStateDisableContent
>> 000000000000000c B nrrdStateGrayscaleImage3D
>> 0000000000000004 B nrrdStateKeyValuePairsPropagate
>> 0000000000000010 B nrrdStateKeyValueReturnInternalPointers
>> 0000000000000014 B nrrdStateKindNoop
>> 0000000000000028 D nrrdStateUnknownContent
>> 0000000000000000 B nrrdStateVerboseIO
>>
>> We can talk on the phone if you prefer... Let me know.
>>
>> Cheers,
>>
>> Michel
>>
>> On Tue, Mar 23, 2010 at 4:23 PM, Gordon L. Kindlmann <glk at uchicago.edu>
>> wrote:
>> Hello,
>>
>> Ok, so the question is, *how* is nrrdStateGrayscaleImage3D listed?  there
>> is probably some cryptic single letter code that identifies the type of
>> symbol.  mangle.pl <http://mangle.pl>  is using these letter codes to
>> distinguish between symbols that the NrrdIO library is actually supplying,
>> versus merely using, and the problem is that nrrdStateGrayscaleImage3D is
>> actually being supplied, but is not being recorded as such in the output of
>> mangle.pl <http://mangle.pl> .  Line 66 of mangle.pl <http://mangle.pl>
>>  is where this decision is made; so it may need tweaking.
>>
>> Gordon
>>
>>
>> On Mar 23, 2010, at 3:18 PM, Michel Audette wrote:
>>
>> Hi Gordon,
>>
>> According to this procedure, _nrrdStateGrayscaleImage3D fails to appear,
>> although nrrdStateGrayscaleImage3D is listed in the result of nm.
>>
>> What next?
>>
>> Michel
>>
>> On Tue, Mar 23, 2010 at 2:07 PM, Gordon L. Kindlmann <glk at uchicago.edu>
>> wrote:
>> Hello,
>>
>> Shoot- sorry about this; I was just thinking the NrrdIO update was
>> finished!
>>
>> There indeed probably aren't any tests for checking compiling applications
>> against both Teem (containing the air, biff, and nrrd libraries that these
>> symbols are coming from) and ITK (containing NrrdIO, the fraction of Teem
>> required for Nrrd file IO).  Aren't Slicer builds doing this?  Are there
>> analogous tests for, say, compiling applications against non-ITK zlib and
>> ITK name-mangled zlib, which can be copied from?
>>
>> I can tell that these names are for the global variables that exist in
>> NrrdIO.  These are probably not getting correctly picked up from the list of
>> symbols in the NrrdIO library, which mangle.pl <http://mangle.pl>  does
>> by using "nm".
>>
>> Michel, can go through the NrrdIO process on whatever platform you used
>> last, and at the point of running mangle.pl <http://mangle.pl> , can you
>> run "nm" manually and grep for, say, _nrrdStateGrayscaleImage3D, and see how
>> that symbol is identified?  Line 66 of mangle.pl <http://mangle.pl>
>>  apparently is missing this.
>>
>> Gordon
>>
>>
>> On Mar 23, 2010, at 12:33 PM, Daniel Blezek wrote:
>>
>> Hi,
>>
>>  We link both against NRRD and ITK in our applications.  At the end of
>> February, the mangled ITK names were changed from what I fixed.  Clearly,
>> this is not tested properly, because today I updated ITK and re-built:
>>
>> 34>ITKNrrdIO.lib(string.obj) : error LNK2005: _airStrtokQuoting already
>> defined in teem.lib(string.obj)
>> 34>ITKNrrdIO.lib(defaultsNrrd.obj) : error LNK2005: _nrrdStateVerboseIO
>> already defined in teem.lib(defaultsNrrd.obj)
>> 34>ITKNrrdIO.lib(defaultsNrrd.obj) : error LNK2005:
>> _nrrdStateKeyValuePairsPropagate already defined in
>> teem.lib(defaultsNrrd.obj)
>> 34>ITKNrrdIO.lib(defaultsNrrd.obj) : error LNK2005:
>> _nrrdStateDisableContent already defined in teem.lib(defaultsNrrd.obj)
>> 34>ITKNrrdIO.lib(defaultsNrrd.obj) : error LNK2005:
>> _nrrdStateGrayscaleImage3D already defined in teem.lib(defaultsNrrd.obj)
>> 34>ITKNrrdIO.lib(defaultsNrrd.obj) : error LNK2005:
>> _nrrdStateKeyValueReturnInternalPointers already defined in
>> teem.lib(defaultsNrrd.obj)
>> 34>ITKNrrdIO.lib(defaultsNrrd.obj) : error LNK2005: _nrrdStateKindNoop
>> already defined in teem.lib(defaultsNrrd.obj)
>> 34>ITKNrrdIO.lib(biffmsg.obj) : error LNK2005: __biffMsgNoop already
>> defined in teem.lib(biffmsg.obj)
>> 34>ITKNrrdIO.lib(dio.obj) : error LNK2005: _airDisableDio already defined
>> in teem.lib(dio.obj)
>>
>> Could “Michel” (according to CVS) please have a closer look at this?  I
>> had tweaked this once before, and my changes were blown away by the (broken)
>> mangle.pl <http://mangle.pl>  script.
>>
>> I’ll go back through and manually add the names if necessary.
>>
>> Cheers,
>> -dan
>>
>> --
>> Daniel Blezek, PhD
>> Medical Imaging Informatics Innovation Center
>>
>> P 127 or (77) 8 8886
>> T 507 538 8886
>> E blezek.daniel at mayo.edu
>>
>> Mayo Clinic
>> 200 First St. S.W.
>> Harwick SL-44
>> Rochester, MN 55905
>> mayoclinic.org
>>
>> <Tmp.txt>
>>
>>
>>
>>
>> --
>> Michel Audette, Ph.D.
>> R & D Engineer,
>> Kitware Inc.,
>> Chapel Hill, N.C.
>>
>>
>


-- 
Michel Audette, Ph.D.
R & D Engineer,
Kitware Inc.,
Chapel Hill, N.C.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20100324/e3f4d5c5/attachment.htm>


More information about the Insight-developers mailing list