Your dislike of cross-posting isn't really on topic.

-- 
Matt Benjamin
Red Hat, Inc.
315 West Huron Street, Suite 140A
Ann Arbor, Michigan 48103

http://www.redhat.com/en/technologies/storage

tel.  734-761-4689
fax.  734-769-8938
cel.  734-216-5309

----- Original Message -----
> From: "William Allen Simpson" <william.allen.simp...@gmail.com>
> To: "Niels de Vos" <nde...@redhat.com>
> Cc: "Matt Benjamin" <mbenja...@redhat.com>, "NFS Ganesha Developers" 
> <nfs-ganesha-devel@lists.sourceforge.net>
> Sent: Sunday, October 4, 2015 7:41:10 PM
> Subject: Re: [Nfs-ganesha-devel] versioned libibverbs issue
> 
> On 10/4/15 10:40 AM, Matt Benjamin wrote:
> >>> Sure looks to me like this is the mismatch (with librdmacm above)!
> >>
> >> Should lib64/libntirpc.so not be linked against libibverbs.so too? The
> >> ldd command above does not show the dynamic linkage. Still the symbol is
> >> used, but with an unknown version (likely because it was not explicitly
> >> checked during linking).
> >
> > Yes, it should.  This is the issue I suggested we check on 3 weeks ago, and
> > again last week, when we looked over the ntirpc link line together, on
> > your laptop.
> >
> Although I brought this to your attention 3 weeks ago,
> bringing my laptop to your office, I don't see the fix in
> your patch, nor Dan's later patches.
> 
> The link line we looked at again last week was the Ganesha line.
> (with the VERBOSE=1 flag)
> 
> Since neither I nor you nor Dan appear to know how to set a link
> version on a library in cmake, I'm hoping somebody on this list does!

I do know how to select from a desired range of library files matching the 
pattern, because I google'd it.  I don't see any documentation on selecting for 
a version namespace at link time, but what I DO know is:

1. if the GNU toolchain allows that, it's not commonly done

2. as I think I and Dan (and most GNU developers know), there is a convention 
in wide use to encode the library version in the filename, and using it the 
packager would supply a libibverbs.so.1.0 and later a libibverbs.so.1.1.0 and 
libibverbs.so would be a symlink to the latest supported

3. I reviewed what Mellanox Accelio does, because it uses these APIs 
successfully, and, as I expected and Niels suggests, what you do to make use of 
it in an intermediate shared library seems to be just dd -libverbs and -lrdmacm 
to the library link line;  I don't see them doing anything interesting to 
select a library version, they have dynamic linkage, and this just works


> 
> 
> >>> Does anybody out there know how to tell a library to use a
> >>> specific library version?
> >>
> >> When building libntirpc, make sure that -libverbs is passed in the
> >> LD_FLAGS. I expect that libntirpc.so will have a versioned dependency on
> >> the symbol after that.
> >>
> >> I might be able to try this out later this week. You are also more
> >> familiar with the libntirpc build process, and might be able to test
> >> this much quicker than me.
> >>
> Thanks, Niels.  How do we do that?

There are a lot of examples, including the CMakeLists.txt file in nfs-ganesha.

I think there is more than one way, but I believe that the Ganesha 
CMakeLists.txt file in ntirpc should just add:

set(CMAKE_SHARED_LINKER_FLAGS, "${CMAKE_SHARED_LINKER_FLAGS} -libverbs 
-lrdmacm")

I would have described this in prior weeks, if I realized it was a blocker.  
Maybe it isn't, but let's try it shall we?

Matt

> 
> 
> 

------------------------------------------------------------------------------
_______________________________________________
Nfs-ganesha-devel mailing list
Nfs-ganesha-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs-ganesha-devel

Reply via email to