CEPH filesystem development
 help / color / mirror / Atom feed
From: Christian Brunner <chb@muc.de>
To: Sage Weil <sage@newdream.net>
Cc: ceph-devel@vger.kernel.org
Subject: [PATCH] cclass: fix .so loading file
Date: Mon, 2 Aug 2010 21:58:30 +0200	[thread overview]
Message-ID: <20100802195830.GC4923@chb-desktop> (raw)

On Fri, Jul 09, 2010 at 09:41:24AM -0700, Sage Weil wrote:
> On Fri, 9 Jul 2010, Christian Brunner wrote:
> > Hi,
> > 
> > in the following I'll send a few fixes and additions for the rpm spec file.
> > Please commit the patches that you like to the repository.
> 
> Thanks, committing now.
> 
> There's one other pitfall I ran into with the debs... by default symbols 
> are stripped from all binaries, but the libcls_rbd.so shared object needs 
> to _not_ be stripped, or else the class loading doesn't work.  I have no 
> idea where/when/if this is done during the rpmbuild.  The version in the 
> built package should look like so:
> 
> $ nm .libs/libcls_rbd.so
> 000000000000797d T __cls_init
> 000000000020ce50 D __cls_name
> 000000000020ce7c B __cls_name__rbd
> 000000000020ce78 B __cls_ver__1_1
> 000000000020ce48 D __cls_ver_maj
> 000000000020ce4c D __cls_ver_min
> 
> Thanks-
> sage

Hi Sage,

shared objects are not stript on our system. So I can't reproduce this.

The only thing I've found, is that the *.so files are included in the -devel
rpm. This leads to the fact that the 'find' in cclass doesn't return any
files. I'd suggest the attached change in the script.

Christian

---
 src/cclass.in |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/cclass.in b/src/cclass.in
index 69513fa..1a2a807 100755
--- a/src/cclass.in
+++ b/src/cclass.in
@@ -85,7 +85,7 @@ load() {
 }
 
 load_all() {
-	all=`find $libdir -name 'libcls_*.so'`;
+	all=`find $libdir -name 'libcls_*.so*' -type f`;
 	if [ -n "$all" ]; then
 		for fn in $all; do
 			echo Loading class: $fn: `$BINDIR/cclsinfo $fn`
-- 
1.7.0.4



                 reply	other threads:[~2010-08-02 19:58 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100802195830.GC4923@chb-desktop \
    --to=chb@muc.de \
    --cc=ceph-devel@vger.kernel.org \
    --cc=sage@newdream.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox