Bug 977115 - Please provide pkg-config file for libpq library
Summary: Please provide pkg-config file for libpq library
Keywords:
Status: CLOSED CANTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: postgresql
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Pavel Raiskup
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-06-23 16:09 UTC by Pavel Alexeev
Modified: 2013-08-12 06:21 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-08-12 06:21:44 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Pavel Alexeev 2013-06-23 16:09:17 UTC
Description of problem:
Please include in postgresql-libs (or devel) package pkgconfig file /usr/lib64/pkgconfig/libpq.pc. Base content should be similar to:

prefix=/usr
exec_prefix=${prefix}
libdir=${prefix}/lib64/pgsql
includedir=${prefix}/include/pgsql

Name: LibPQ
Version: 5.0.0
Description: Library PQ
Requires:
Libs: -L${libdir} -lpq
Cflags: -I${includedir


It required for convenient use.
If I understand correctly it present in other distributions: https://github.com/pgmodeler/pgmodeler/issues/135

Comment 1 Pavel Raiskup 2013-06-26 08:59:11 UTC
Hi Pavel, thanks for the report.

> Description of problem:
> Please include in postgresql-libs (or devel) package pkgconfig file
> /usr/lib64/pkgconfig/libpq.pc. Base content should be similar to:

the 'libpq.pc' file compiling was enabled in upstream git some time ago:

|| commit 64f890905f3a5186bc4df980c8becfda5c39c2ea
|| Author:     Peter Eisentraut <peter_e>
|| AuthorDate: Sun Mar 31 16:58:40 2013 -0400
|| Commit:     Peter Eisentraut <peter_e>
|| CommitDate: Sun Mar 31 16:58:40 2013 -0400
||
||     Add pkg-config files for libpq and ecpg libraries

And it will distributed in the coming 9.3 release of postgresql.

> It required for convenient use.
> If I understand correctly it present in other distributions:
> https://github.com/pgmodeler/pgmodeler/issues/135

Based on that thread, I'm not really sure that some other distros have this
installed.  Not very familiar with qt4 build toolset but there must exist some
way how to specify LDFLAGS/CFLAGS/... to tell compiler/linker where to look for
libraries.  Probably worth to ask some qt guys.

----------------

I don't think that this is worth to backport.  But I'm not closing this as we
should not forget to package libpq.pc once distributed in new postgresql
release (will close once new release becomes Rawhide including requested file).

Pavel

Comment 2 Pavel Alexeev 2013-07-01 19:25:10 UTC
Hello, Pavel.

pgmodeler (which is on review and depends on it) depends on it and I'll be very thankful if you consider possible backport it for Fedora 18 and 19 too.

Off course it may be hacked also, but I think what have package config file is good idea in any case if even upstream authors add it.

Comment 3 Pavel Raiskup 2013-07-01 20:34:24 UTC
Pavel, I just don't want make a respin for such change (and press people — who
want to be up2date doing the 'yum update -y' regularly — to install new
postgresql packages).  (I updated the dependant bug 977116 with possible
solution).

Comment 4 Pavel Alexeev 2013-07-04 16:33:42 UTC
Pavel thank you for the help attempt.
Sure I'll be able hack it to build without pckgconfig, but in most cases it is not good choose. But you point also have sence. Please consider put that file together with another update in stable fedora branch if happened.
And I've break dependency in issues.

Comment 5 Pavel Raiskup 2013-08-12 06:21:44 UTC
I looked at this once more and I see now that the libpq.pc is not able to
help you.  This file is related to /usr/lib/libpq.so.*, not to contrib
libraries in /usr/lib/pgsql/*.  The real libpq.pc from upstream will look
similar to:

  Name: libpq
  Description: PostgreSQL libpq library
  Url: http://www.postgresql.org/
  Version: 9.4devel
  Requires: 
  Requires.private: 
  Cflags: -I/usr/include
  Libs: -L/usr/lib64 -lpq
  Libs.private:  -lssl -lcrypto -lkrb5 -lcom_err -lgssapi_krb5 -lcrypt ..

If you want to use contrib libraries, you seem to be supposed to set paths by
hand.  Anybody, please reopen this bug if you see that I may help to this
usecase somehow.

Pavel


Note You need to log in before you can comment on or make changes to this bug.