Bug 1623764 - Review Request: libpq - PostgreSQL client library
Summary: Review Request: libpq - PostgreSQL client library
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Petr Kubat
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1618698
TreeView+ depends on / blocked
 
Reported: 2018-08-30 07:20 UTC by Pavel Raiskup
Modified: 2018-09-06 10:26 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2018-09-06 10:26:55 UTC
Type: ---
Embargoed:
pkubat: fedora-review+


Attachments (Terms of Use)

Description Pavel Raiskup 2018-08-30 07:20:38 UTC
Spec URL: https://copr-dist-git.fedorainfracloud.org/cgit/praiskup/libpq/libpq.git/plain/libpq.spec
SRPM URL: https://copr-be.cloud.fedoraproject.org/results/praiskup/libpq/fedora-rawhide-x86_64/00792493-libpq/libpq-10.5-1.fc30.src.rpm
Description:
The libpq package provides the essential shared library for any PostgreSQL
client program or interface.  You will need to install this package to use any
other PostgreSQL package or any clients that need to connect to a PostgreSQL
server.

Fedora Account System Username: praiskup

Comment 1 Petr Kubat 2018-09-04 07:23:21 UTC
libpq obsoletes itself right now as it provides postgresql-libs = 10.5 and obsoletes postresql-libs < 10.6. Are you planning to make the necessary changes to postgresql only after 10.6 releases? This would be fixed then.

There is also an issue with directory ownership but I guess that is expected at this point in time. Just something to keep in mind for the changes needed in postgresql.

Package Review
==============

Legend:
[x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated
[ ] = Manual review needed



===== MUST items =====

C/C++:
[x]: Package does not contain kernel modules.
[x]: Package contains no static executables.
[x]: If your application is a C or C++ application you must list a
     BuildRequires against gcc, gcc-c++ or clang.
[x]: Header files in -devel subpackage, if present.
[x]: ldconfig not called in %post and %postun for Fedora 28 and later.
[x]: Package does not contain any libtool archives (.la)
[x]: Rpath absent or only used for internal libs.
[x]: Development (unversioned) .so files in -devel subpackage, if present.

Generic:
[x]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
     Guidelines.
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "GPL", "PostgreSQL", "GPL (v3 or later)", "Unknown or
     generated", "MIT/X11 (BSD like)", "BSD (unspecified)", "*No copyright*
     Public domain", "ISC", "BSD (3 clause)", "BSD (2 clause)", "FSF All
     Permissive". 6658 files have unknown license. Detailed output of
     licensecheck in /home/pkubat/Workdir/tmp/review/review-
     libpq/licensecheck.txt
[x]: License file installed when any subpackage combination is installed.
[!]: Package does not own files or directories owned by other packages.
     Note: Dirs in package are owned also by: /usr/include/libpq
     (postgresql-devel), /usr/share/pgsql(postgresql-server),
     /usr/include/pgsql(postgresql-devel),
     /usr/include/pgsql/internal/libpq(postgresql-devel),
     /usr/include/pgsql/internal(postgresql-devel)
[x]: %build honors applicable compiler flags or justifies otherwise.
[x]: Package contains no bundled libraries without FPC exception.
[x]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[-]: Package contains desktop file if it is a GUI application.
[x]: Development files must be in a -devel package
[x]: Package uses nothing in %doc for runtime.
[x]: The spec file handles locales properly.
[x]: Package consistently uses macros (instead of hard-coded directory
     names).
[x]: Package is named according to the Package Naming Guidelines.
[!]: Package does not generate any conflict.
     Note: Expected failure as it conflicts with postgresql for now.
[x]: Package obeys FHS, except libexecdir and /usr/target.
[x]: If the package is a rename of another package, proper Obsoletes and
     Provides are present.
[x]: Requires correct, justified where necessary.
[x]: Spec file is legible and written in American English.
[-]: Package contains systemd file(s) if in need.
[x]: Useful -debuginfo package or justification otherwise.
[x]: Package is not known to require an ExcludeArch tag.
[x]: Package complies to the Packaging Guidelines
[x]: Package successfully compiles and builds into binary rpms on at least
     one supported primary architecture.
[x]: Package installs properly.
[x]: Rpmlint is run on all rpms the build produces.
     Note: There are rpmlint messages (see attachment).
[x]: If (and only if) the source package includes the text of the
     license(s) in its own file, then that file, containing the text of the
     license(s) for the package is included in %license.
[x]: Package requires other packages for directories it uses.
[x]: Package must own all directories that it creates.
[x]: Package uses either %{buildroot} or $RPM_BUILD_ROOT
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
[x]: Macros in Summary, %description expandable at SRPM build time.
[x]: Dist tag is present.
[x]: Package does not contain duplicates in %files.
[x]: Permissions on files are set properly.
[x]: Package must not depend on deprecated() packages.
[x]: Package use %makeinstall only when make install DESTDIR=... doesn't
     work.
[x]: Package is named using only allowed ASCII characters.
[x]: Package does not use a name that already exists.
[x]: Package is not relocatable.
[x]: Sources used to build the package match the upstream source, as
     provided in the spec URL.
[x]: Spec file name must match the spec package %{name}, in the format
     %{name}.spec.
[x]: File names are valid UTF-8.
[x]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 0 bytes in 0 files.
[x]: Packages must not store files under /srv, /opt or /usr/local

===== SHOULD items =====

Generic:
[-]: Uses parallel make %{?_smp_mflags} macro.
[-]: If the source package does not include license text(s) as a separate
     file from upstream, the packager SHOULD query upstream to include it.
[x]: Final provides and requires are sane (see attachments).
[x]: Fully versioned dependency in subpackages if applicable.
     Note: No Requires: %{name}%{?_isa} = %{version}-%{release} in libpq-
     debuginfo
[x]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[x]: Patches link to upstream bugs/comments/lists or are otherwise
     justified.
[-]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[-]: Package should compile and build into binary rpms on all supported
     architectures.
[!]: %check is present and all tests pass.
[-]: Packages should try to preserve timestamps of original installed
     files.
[x]: Reviewer should test that the package builds in mock.
[x]: Buildroot is not present
[x]: Package has no %clean section with rm -rf %{buildroot} (or
     $RPM_BUILD_ROOT)
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: The placement of pkgconfig(.pc) files are correct.
[x]: Sources can be downloaded from URI in Source: tag
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define unless justified.

===== EXTRA items =====

Generic:
[x]: Rpmlint is run on debuginfo package(s).
     Note: No rpmlint messages.
[x]: Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).
[x]: Large data in /usr/share should live in a noarch subpackage if package
     is arched.
[x]: Spec file according to URL is the same as in SRPM.


Rpmlint
-------
Checking: libpq-10.5-1.fc26.x86_64.rpm
          libpq-devel-10.5-1.fc26.x86_64.rpm
          libpq-debuginfo-10.5-1.fc26.x86_64.rpm
          libpq-10.5-1.fc26.src.rpm
libpq.x86_64: W: self-obsoletion postgresql-libs < 10.6 obsoletes postgresql-libs = 10.5-1.fc26
libpq-devel.x86_64: W: self-obsoletion postgresql-devel < 10.6 obsoletes postgresql-devel = 10.5-1.fc26
libpq-devel.x86_64: W: no-documentation
libpq-devel.x86_64: W: no-manual-page-for-binary pg_config
4 packages and 0 specfiles checked; 0 errors, 4 warnings.




Rpmlint (debuginfo)
-------------------
Checking: libpq-debuginfo-10.5-1.fc26.x86_64.rpm
1 packages and 0 specfiles checked; 0 errors, 0 warnings.





Rpmlint (installed packages)
----------------------------
sh: /usr/bin/python: No such file or directory
libpq.x86_64: W: invalid-url URL: http://www.postgresql.org/ <urlopen error [Errno -2] Name or service not known>
libpq.x86_64: W: self-obsoletion postgresql-libs < 10.6 obsoletes postgresql-libs = 10.5-1.fc26
libpq.x86_64: E: library-without-ldconfig-postin /usr/lib64/libpq.so.5.10
libpq.x86_64: E: library-without-ldconfig-postun /usr/lib64/libpq.so.5.10
libpq-devel.x86_64: W: invalid-url URL: http://www.postgresql.org/ <urlopen error [Errno -2] Name or service not known>
libpq-devel.x86_64: W: self-obsoletion postgresql-devel < 10.6 obsoletes postgresql-devel = 10.5-1.fc26
libpq-devel.x86_64: W: only-non-binary-in-usr-lib
libpq-devel.x86_64: W: no-documentation
libpq-devel.x86_64: W: no-manual-page-for-binary pg_config
libpq-debuginfo.x86_64: W: invalid-url URL: http://www.postgresql.org/ <urlopen error [Errno -2] Name or service not known>
3 packages and 0 specfiles checked; 2 errors, 8 warnings.



Requires
--------
libpq (rpmlib, GLIBC filtered):
    libc.so.6()(64bit)
    libcrypto.so.1.1()(64bit)
    libcrypto.so.1.1(OPENSSL_1_1_0)(64bit)
    libgssapi_krb5.so.2()(64bit)
    libgssapi_krb5.so.2(gssapi_krb5_2_MIT)(64bit)
    libldap_r-2.4.so.2()(64bit)
    libpthread.so.0()(64bit)
    libssl.so.1.1()(64bit)
    libssl.so.1.1(OPENSSL_1_1_0)(64bit)
    rtld(GNU_HASH)

libpq-devel (rpmlib, GLIBC filtered):
    /usr/bin/pkg-config
    libc.so.6()(64bit)
    libpq(x86-64)
    libpq.so.5()(64bit)
    libpthread.so.0()(64bit)
    rtld(GNU_HASH)

libpq-debuginfo (rpmlib, GLIBC filtered):



Provides
--------
libpq:
    libpq
    libpq(x86-64)
    libpq.so.5()(64bit)
    libpq.so.5(RHPG_10)(64bit)
    libpq.so.5(RHPG_9.6)(64bit)
    postgresql-libs

libpq-devel:
    libpq-devel
    libpq-devel(x86-64)
    pkgconfig(libpq)
    postgresql-devel

libpq-debuginfo:
    libpq-debuginfo
    libpq-debuginfo(x86-64)



Source checksums
----------------
https://ftp.postgresql.org/pub/source/v10.5/postgresql-10.5.tar.bz2 :
  CHECKSUM(SHA256) this package     : 6c8e616c91a45142b85c0aeb1f29ebba4a361309e86469e0fb4617b6a73c4011
  CHECKSUM(SHA256) upstream package : 6c8e616c91a45142b85c0aeb1f29ebba4a361309e86469e0fb4617b6a73c4011
https://ftp.postgresql.org/pub/source/v10.5/postgresql-10.5.tar.bz2.sha256 :
  CHECKSUM(SHA256) this package     : f3f4636d988fee270da174c15e266d19280705363cb09aa11726410f66314e75
  CHECKSUM(SHA256) upstream package : f3f4636d988fee270da174c15e266d19280705363cb09aa11726410f66314e75


Generated by fedora-review 0.6.4 (f322a32) last change: 2018-07-21
Command line :/usr/bin/fedora-review -n libpq
Buildroot used: fedora-26-x86_64
Active plugins: Generic, Shell-api, C/C++
Disabled plugins: Java, Python, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP
Disabled flags: EXARCH, BATCH, DISTTAG, EPEL5, EPEL7, EPEL6

Comment 2 Pavel Raiskup 2018-09-04 08:00:53 UTC
Spec URL: https://copr-dist-git.fedorainfracloud.org/cgit/praiskup/libpq/libpq.git/plain/libpq.spec?id=c505e10b2b79b0efc30f73ee2608e3497517f08e
SRPM URL: https://copr-be.cloud.fedoraproject.org/results/praiskup/libpq/fedora-rawhide-x86_64/00794229-libpq/libpq-10.5-3.fc30.src.rpm

Thanks for the your comments!

(In reply to Petr Kubat from comment #1)
> libpq obsoletes itself right now as it provides postgresql-libs = 10.5 and
> obsoletes postresql-libs < 10.6. Are you planning to make the necessary
> changes to postgresql only after 10.6 releases?

The 10.6 was just development string (I wasn't sure what will be the final
Release right before implementing this chagne) -- so correct should be
'10.5-4' (at this point in time) because the latest Release shipped in
postgresql-libs is '10.5.3'.

Whether the package obsoletes itself..., I'm not sure.  I don't think it has
such effect in the end.  But I bumped the Release to '3' to make sure it's OK.

> There is also an issue with directory ownership but I guess that is expected
> at this point in time. Just something to keep in mind for the changes needed
> in postgresql.
> 
> ===== MUST items =====
> [!]: Package does not own files or directories owned by other packages.
>      Note: Dirs in package are owned also by:
>      /usr/include/libpq (postgresql-devel),
>      /usr/share/pgsql(postgresql-server),
>      /usr/include/pgsql(postgresql-devel),
>      /usr/include/pgsql/internal/libpq(postgresql-devel),
>      /usr/include/pgsql/internal(postgresql-devel)

It's not that strict in current Fedora, and directories might co-own files.
The list is pretty sane, /usr/include/libpq will be owned only by libpq (same
as '/usr/include/pgsql/internal/libpq'), /usr/share/pgsql will be co-owned
by (otherwise not coupled in any way) 'libpq-devel' and
'postgresql-server-devel' (ditto for  /usr/include/pgsql/internal).

> [!]: Package does not generate any conflict.
>      Note: Expected failure as it conflicts with postgresql for now.

Yes, 'postgresql.spec' will be updated atomically with build of libpq.spec and
libecpg.spec.

> [!]: %check is present and all tests pass.

This requires some work.  But libpq.so will be tested extensively by the
postgresql.spec builds.

Comment 4 Petr Kubat 2018-09-04 08:43:06 UTC
(In reply to Pavel Raiskup from comment #2)
> Spec URL:
> https://copr-dist-git.fedorainfracloud.org/cgit/praiskup/libpq/libpq.git/
> plain/libpq.spec?id=c505e10b2b79b0efc30f73ee2608e3497517f08e
> SRPM URL:
> https://copr-be.cloud.fedoraproject.org/results/praiskup/libpq/fedora-
> rawhide-x86_64/00794229-libpq/libpq-10.5-3.fc30.src.rpm
> 
> Thanks for the your comments!
> 
> The 10.6 was just development string (I wasn't sure what will be the final
> Release right before implementing this chagne) -- so correct should be
> '10.5-4' (at this point in time) because the latest Release shipped in
> postgresql-libs is '10.5.3'.
> 
> Whether the package obsoletes itself..., I'm not sure.  I don't think it has
> such effect in the end.  But I bumped the Release to '3' to make sure it's
> OK.

LGTM now (with the changes in comment 3).

> 
> It's not that strict in current Fedora, and directories might co-own files.
> The list is pretty sane, /usr/include/libpq will be owned only by libpq (same
> as '/usr/include/pgsql/internal/libpq'), /usr/share/pgsql will be co-owned
> by (otherwise not coupled in any way) 'libpq-devel' and
> 'postgresql-server-devel' (ditto for  /usr/include/pgsql/internal).

Makes sense. This way there should not be any issues with co-ownerships as it is only forbidden (iiuc) when a directory is owned by a required package.

> > [!]: Package does not generate any conflict.
> >      Note: Expected failure as it conflicts with postgresql for now.
> 
> Yes, 'postgresql.spec' will be updated atomically with build of libpq.spec
> and
> libecpg.spec.
> 
> > [!]: %check is present and all tests pass.
> 
> This requires some work.  But libpq.so will be tested extensively by the
> postgresql.spec builds.

I agree this should be enough for now.

Thanks for the changes! LGTM

Comment 5 Igor Raits 2018-09-04 09:22:45 UTC
(fedscm-admin):  The Pagure repository was created at https://src.fedoraproject.org/rpms/libpq


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