Bug 797394

Summary: pkgconfig doesn't include corosync common so file
Product: [Retired] Corosync Cluster Engine Reporter: Steven Dake <sdake>
Component: unknownAssignee: Jan Friesse <jfriesse>
Status: CLOSED NOTABUG QA Contact:
Severity: urgent Docs Contact:
Priority: unspecified    
Version: 1.4CC: asalkeld, fdinitto, jfriesse, sdake
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-02-26 05:43:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Steven Dake 2012-02-25 15:25:27 UTC
Description of problem:
pkgconfig doesn't include corosync common so file

Version-Release number of selected component (if applicable):
latest best

How reproducible:
andrew was complaining that pkgconfig didn't pull in the symbols he needed from the common object.

Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Angus Salkeld 2012-02-26 01:41:08 UTC
I did this as Fabio said it should not be included in the other lib's
pkgconfig.

so
pkg-config --libs libcpg
should only return libcpg as that is all you need to access it's
api. However if you want to access the symbols in common lib directly
from your app then you need to add $(pkg-config --libs libcorosync_common)

<that is the way I understood it>

Comment 2 Fabio Massimo Di Nitto 2012-02-26 05:43:32 UTC
And this is the correct behaviour.

If you use symbols from the common library you need to link with it directly.

We ship the pkg-config snippet and all for it, but it's not correct to pull it in automatically when linking with other libraries, otherwise all applications that do NOT use those symbols will be bloated by pulling it automatically.

Some distributions have very strict rules about NOT linking against libraries you don't use (so we would see complains opposite to this one).

Andrew uses those symbols directly and so he needs to link.