Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmake: remove unnecessary linked libs from libcephfs #10081

Merged
merged 1 commit into from Jul 1, 2016

Conversation

tchaikov
Copy link
Contributor

@tchaikov tchaikov commented Jul 1, 2016

  • some of the libs shares the same .cc which has static C++ variables. if
    we link against the different libs sharing the same static C++
    variables, and the dtor of the C++ variables has side-effects, among
    other things, deallocates a memory chunk. then, we are in the trouble of
    double free.
  • some of the libs are referenced by the linked lib, so no need to link
    against them again. for example, BLKID_LIBRARIES are linked by
    libcommon, so we can remove it from the linked libs list.

Fixes: http://tracker.ceph.com/issues/16556
Signed-off-by: Kefu Chai kchai@redhat.com

* some of the libs shares the same .cc which has static C++ variables. if
  we link against the different libs sharing the same static C++
  variables, and the dtor of the C++ variables has side-effects, among
  other things, deallocates a memory chunk. then, we are in the trouble of
  double free. so "osd" lib is removed.
* some of the libs are referenced by the linked lib, so no need to link
  against them again. for example, BLKID_LIBRARIES are linked by
  libcommon, so we can remove it from the linked libs list.
* and lib "os" and "cls_references_objs" are not used by libcephfs at all,
  so remove them.

Fixes: http://tracker.ceph.com/issues/16556
Signed-off-by: Kefu Chai <kchai@redhat.com>
@jcsp jcsp merged commit 22670bb into ceph:master Jul 1, 2016
@jcsp
Copy link
Contributor

jcsp commented Jul 1, 2016

Tested this locally

@tchaikov tchaikov deleted the wip-16556 branch July 1, 2016 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants