[Bug 868578] Review Request: re2 - C++ fast alternative to backtracking RE engines

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Product: Fedora
https://bugzilla.redhat.com/show_bug.cgi?id=868578

Mathieu Bridon <bochecha@xxxxxxxxxxxxxxxxx> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|nobody@xxxxxxxxxxxxxxxxx    |bochecha@xxxxxxxxxxxxxxxxx

--- Comment #8 from Mathieu Bridon <bochecha@xxxxxxxxxxxxxxxxx> ---
A couple of (non-blocker) comments first. 

* What is this empty comment line at the top of the spec file? Did you want to
add something but forgot?

* Try to remove trailing spaces. There's one on the Group: line.

* The file re2/testing/unicode_test.py has a wrong shebang
(#!/usr/bin/python2.4), however it doesn't seem to be used anywhere (not even
during unit tests) and isn't installed, so that can probably be ignored.

* Why do you both export the CXXFLAGS/LDFLAGS and then pass them again on the
make command line? Exporting doesn't seem to do anything, they need to be
passed to the command, so you could just do:
-----
CXXFLAGS="${CXXFLAGS:-%optflags}"
LDFLAGS="${LDFLAGS:-%__global_ldflags}"
make %{?_smp_mflags} CXXFLAGS="$CXXFLAGS" LDFLAGS="$LDFLAGS"
includedir=%{_includedir} libdir=%{_libdir}
-----

* The devel package requires the main package, as such it doesn't need to
include the README and LICENSE files. Consider removing them.

* The %description for the main package is still **very** long. How about
something like this instead:
-----
RE2 is a C++ library providing a fast, safe, thread-friendly alternative to
backtracking regular expression engines like those used in PCRE, Perl, and
Python.

Backtracking engines are typically full of features and convenient
syntactic sugar but can be forced into taking exponential amounts of
time on even small inputs.

In contrast, RE2 uses automata theory to guarantee that regular expression
searches run in time linear in the size of the input, at the expense of some
missing features (e.g back references and generalized assertions).
-----

* The %description of the devel subpackage talks about "development helper
tools", but there aren't any. Consider removing the misleading statement.

Now for the actual review...


Summary of issues
=================

[!]: Requires correct, justified where necessary.
    => Drop the "Requires: pkgconfig" from the devel subpackage, it doesn't
       provide any pkgconfig file.

[!]: Rpmlint is run on all rpms the build produces.
    => There are a few "undefined-non-weak-symbol" warnings, which should be
       fixed. (try "ldd -d -r /usr/lib64/libre2.so.0.0.0" for more details)
       Adding "-pthread" to the CXXFLAGS seems to be enough. However, if this
       flags really is necessary, I would strongly suggest you submit a patch
       upstream so that it gets added to the RE2_CXXFLAGS in the Makefile (as
       these seem to be the minimum flags which shouldn't be overwritten)
    => The rest of the warnings can be safely ignored.

[!]: Packages should try to preserve timestamps of original installed files.
    => Try passing the INSTALL="install -p" variable to the make install
command.

Details
=======

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


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

C/C++:
[x]: Header files in -devel subpackage, if present.
[x]: ldconfig called in %post and %postun if required.
[x]: Package does not contain any libtool archives (.la)
[x]: Package does not contain kernel modules.
[x]: Package contains no static executables.
[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]: Package successfully compiles and builds into binary rpms on at least one
     supported primary architecture.
[x]: %build honors applicable compiler flags or justifies otherwise.
[x]: All build dependencies are listed in BuildRequires, except for any that
     are listed in the exceptions section of Packaging Guidelines.
[x]: Package contains no bundled libraries.
[x]: Changelog in prescribed format.
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
     Note: rm -rf %{buildroot} present but not required
    => Submitter indicated their intention to maintain EL 5 packages, for
       which this is necessary.

[x]: Sources contain only permissible code or content.
[-]: Each %files section contains %defattr if rpm < 4.4
[-]: Macros in Summary, %description expandable at SRPM build time.
[-]: Package contains desktop file if it is a GUI application.
[x]: Development files must be in a -devel package
[-]: Package requires other packages for directories it uses.
[x]: Package uses nothing in %doc for runtime.
[x]: Package is not known to require ExcludeArch.
[x]: Package does not contain duplicates in %files.
[x]: Permissions on files are set properly.
[x]: Fully versioned dependency in subpackages, if present.
[!]: Package complies to the Packaging Guidelines
    => See outstanding issues.

[x]: Spec file lacks Packager, Vendor, PreReq tags.
[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 %doc.
[x]: License field in the package spec file matches the actual license.
[x]: License file installed when any subpackage combination is installed.
[x]: Package consistently uses macro (instead of hard-coded directory
     names).
[x]: Package is named using only allowed ASCII characters.
[x]: Package is named according to the Package Naming Guidelines.
[x]: Package does not generate any conflict.
[x]: Package do not use a name that already exist
[x]: Package obeys FHS, except libexecdir and /usr/target.
[-]: If the package is a rename of another package, proper Obsoletes and
     Provides are present.
[x]: Package must own all directories that it creates.
[x]: Package does not own files or directories owned by other packages.
[x]: Package installs properly.
[x]: Package is not relocatable.
[!]: Requires correct, justified where necessary.
    => Drop the "Requires: pkgconfig" from the devel subpackage, it doesn't
       provide any pkgconfig file.

[!]: Rpmlint is run on all rpms the build produces.
    => There are a few "undefined-non-weak-symbol" warnings, which should be
       fixed. (try "ldd -d -r /usr/lib64/libre2.so.0.0.0" for more details)
       Adding "-pthread" to the CXXFLAGS seems to be enough. However, if this
       flags really is necessary, I would strongly suggest you submit a patch
       upstream so that it gets added to the RE2_CXXFLAGS in the Makefile (as
       these seem to be the minimum flags which shouldn't be overwritten)
    => The rest of the warnings can be safely ignored.

[x]: Sources used to build the package match the upstream source, as provided
     in the spec URL.
[x]: Spec file is legible and written in American English.
[x]: Spec file name must match the spec package %{name}, in the format
     %{name}.spec.
[-]: Package contains systemd file(s) if in need.
[x]: File names are valid UTF-8.
[x]: Useful -debuginfo package or justification otherwise.
[-]: Large documentation must go in a -doc subpackage.
     Note: Documentation size is 20480 bytes in 6 files.
[x]: Packages must not store files under /srv, /opt or /usr/local


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

Generic:
[x]: Reviewer should test that the package builds in mock.
[x]: Buildroot is not present
     Note: Buildroot: present but not needed
    => Submitter indicated their intention to maintain EL 5 packages, for
       which this is necessary.

[x]: Package has no %clean section with rm -rf %{buildroot} (or
     $RPM_BUILD_ROOT)
     Note: %clean present but not required
    => Submitter indicated their intention to maintain EL 5 packages, for
       which this is necessary.

[-]: 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]: Dist tag is present.
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Final provides and requires are sane (rpm -q --provides and rpm -q
     --requires).
[?]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[-]: The placement of pkgconfig(.pc) files are correct.
[x]: Scriptlets must be sane, if used.
[x]: SourceX tarball generation or download is documented.
[x]: SourceX / PatchY prefixed with %{name}.
[x]: SourceX is a working URL.
[-]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[x]: Package should compile and build into binary rpms on all supported
     architectures.
[x]: %check is present and all tests pass.
[!]: Packages should try to preserve timestamps of original installed files.
    => Try passing the INSTALL="install -p" variable to the make install
command.

[x]: Spec use %global instead of %define.


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

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

Rpmlint
-------
Checking: re2-20130115-1.fc19.src.rpm
          re2-debuginfo-20130115-1.fc19.x86_64.rpm
          re2-20130115-1.fc19.x86_64.rpm
          re2-devel-20130115-1.fc19.x86_64.rpm
re2.src: W: spelling-error %description -l en_US automata -> automate,
automaton, automatic
re2.src: W: spelling-error %description -l en_US multi -> mulch, mufti
re2.src: W: spelling-error %description -l en_US backreferences -> back
references, back-references, references
re2.src: W: spelling-error %description -l en_US irregexp -> regexp, expire
re2.x86_64: W: spelling-error %description -l en_US automata -> automate,
automaton, automatic
re2.x86_64: W: spelling-error %description -l en_US multi -> mulch, mufti
re2.x86_64: W: spelling-error %description -l en_US backreferences -> back
references, back-references, references
re2.x86_64: W: spelling-error %description -l en_US irregexp -> regexp, expire
4 packages and 0 specfiles checked; 0 errors, 8 warnings.

Rpmlint (installed packages)
----------------------------
# rpmlint re2-debuginfo re2 re2-devel
re2.x86_64: W: spelling-error %description -l en_US automata -> automate,
automaton, automatic
re2.x86_64: W: spelling-error %description -l en_US multi -> mulch, mufti
re2.x86_64: W: spelling-error %description -l en_US backreferences -> back
references, back-references, references
re2.x86_64: W: spelling-error %description -l en_US irregexp -> regexp, expire
re2.x86_64: W: undefined-non-weak-symbol /usr/lib64/libre2.so.0.0.0
pthread_rwlock_rdlock
re2.x86_64: W: undefined-non-weak-symbol /usr/lib64/libre2.so.0.0.0
pthread_rwlock_wrlock
re2.x86_64: W: undefined-non-weak-symbol /usr/lib64/libre2.so.0.0.0
pthread_rwlock_destroy
re2.x86_64: W: undefined-non-weak-symbol /usr/lib64/libre2.so.0.0.0
pthread_rwlock_init
re2.x86_64: W: undefined-non-weak-symbol /usr/lib64/libre2.so.0.0.0
pthread_rwlock_unlock
3 packages and 0 specfiles checked; 0 errors, 9 warnings.
# echo 'rpmlint-done:'

Requires
--------
re2-debuginfo-20130115-1.fc19.x86_64.rpm (rpmlib, GLIBC filtered):

re2-20130115-1.fc19.x86_64.rpm (rpmlib, GLIBC filtered):
    /sbin/ldconfig
    libc.so.6()(64bit)
    libgcc_s.so.1()(64bit)
    libgcc_s.so.1(GCC_3.0)(64bit)
    libm.so.6()(64bit)
    libstdc++.so.6()(64bit)
    libstdc++.so.6(CXXABI_1.3)(64bit)
    rtld(GNU_HASH)

re2-devel-20130115-1.fc19.x86_64.rpm (rpmlib, GLIBC filtered):
    libre2.so.0()(64bit)
    pkgconfig
    re2(x86-64) = 20130115-1.fc19


Provides
--------
re2-debuginfo-20130115-1.fc19.x86_64.rpm:
    re2-debuginfo = 20130115-1.fc19
    re2-debuginfo(x86-64) = 20130115-1.fc19

re2-20130115-1.fc19.x86_64.rpm:
    libre2.so.0()(64bit)
    re2 = 20130115-1.fc19
    re2(x86-64) = 20130115-1.fc19

re2-devel-20130115-1.fc19.x86_64.rpm:
    re2-devel = 20130115-1.fc19
    re2-devel(x86-64) = 20130115-1.fc19

MD5-sum check
-------------
http://re2.googlecode.com/files/re2-20130115.tgz :
  CHECKSUM(SHA256) this package     :
a95d83ed8203817587f7cc368b6f7199d8a4b1558372c306b07201058b92e1fe
  CHECKSUM(SHA256) upstream package :
a95d83ed8203817587f7cc368b6f7199d8a4b1558372c306b07201058b92e1fe

-- 
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=gH2j6JGtsV&a=cc_unsubscribe
_______________________________________________
package-review mailing list
package-review@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/package-review



[Index of Archives]     [Fedora Legacy]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]     [Fedora Tools]