Bug 444428 - Review Request: ocaml-cmigrep - Search OCaml compiled interface (cmi) files
Review Request: ocaml-cmigrep - Search OCaml compiled interface (cmi) files
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: Package Review (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jason Tibbitts
Fedora Extras Quality Assurance
http://homepage.mac.com/letaris/
:
Depends On: 450551
Blocks:
  Show dependency treegraph
 
Reported: 2008-04-28 07:31 EDT by Richard W.M. Jones
Modified: 2008-08-26 06:59 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-08-26 06:59:58 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
tibbs: fedora‑review+
kevin: fedora‑cvs+


Attachments (Terms of Use)

  None (edit)
Description Richard W.M. Jones 2008-04-28 07:31:56 EDT
Spec URL: http://www.annexia.org/tmp/ocaml/ocaml-cmigrep.spec
SRPM URL: http://www.annexia.org/tmp/ocaml/ocaml-cmigrep-1.5-1.fc9.src.rpm
Description: Search OCaml compiled interface (cmi) files

Quite a complex build process to end up with just a single executable!
However it's a very useful executable, allowing you to grep inside
OCaml *.cmi files.  I didn't yet package up the emacs extension.

rpmlint:
  ocaml-cmigrep.src:58: E: configure-without-libdir-spec
  (OK because it's not autoconf-generated configure)

files:
  /usr/bin/cmigrep
  /usr/share/doc/ocaml-cmigrep-1.5
  /usr/share/doc/ocaml-cmigrep-1.5/GPL
  /usr/share/doc/ocaml-cmigrep-1.5/README
  /usr/share/doc/ocaml-cmigrep-1.5/cmigrep.el

Requires & provides are pretty ordinary because this is just
a single binary.
requires:
  rpmlib(PayloadFilesHavePrefix) <= 4.0-1
  rpmlib(CompressedFileNames) <= 3.0.4-1
  libc.so.6  
  libc.so.6(GLIBC_2.0)  
  libc.so.6(GLIBC_2.1)  
  libc.so.6(GLIBC_2.1.2)  
  libc.so.6(GLIBC_2.2)  
  libc.so.6(GLIBC_2.3)  
  libc.so.6(GLIBC_2.3.4)  
  libc.so.6(GLIBC_2.4)  
  libdl.so.2  
  libdl.so.2(GLIBC_2.0)  
  libdl.so.2(GLIBC_2.1)  
  libm.so.6  
  libm.so.6(GLIBC_2.0)  
  libpcre.so.0  
provides:
  ocaml-cmigrep = 1.5-1.fc9
Comment 1 Richard W.M. Jones 2008-04-28 07:33:47 EDT
Some example usages:

$ cmigrep -c SO_ Unix
SO_DEBUG (* socket_bool_option *)
SO_BROADCAST (* socket_bool_option *)
SO_REUSEADDR (* socket_bool_option *)
SO_KEEPALIVE (* socket_bool_option *)
SO_DONTROUTE (* socket_bool_option *)
SO_OOBINLINE (* socket_bool_option *)
SO_ACCEPTCONN (* socket_bool_option *)
SO_SNDBUF (* socket_int_option *)
SO_RCVBUF (* socket_int_option *)
SO_ERROR (* socket_int_option *)
SO_TYPE (* socket_int_option *)
SO_RCVLOWAT (* socket_int_option *)
SO_SNDLOWAT (* socket_int_option *)
SO_LINGER (* socket_optint_option *)
SO_RCVTIMEO (* socket_float_option *)
SO_SNDTIMEO (* socket_float_option *)

$ cmigrep -a '.*map.*' List
val map : ('a -> 'b) -> 'a list -> 'b list
val rev_map : ('a -> 'b) -> 'a list -> 'b list
val map2 : ('a -> 'b -> 'c) -> 'a list -> 'b list -> 'c list
val rev_map2 : ('a -> 'b -> 'c) -> 'a list -> 'b list -> 'c list
Comment 2 Richard W.M. Jones 2008-04-28 07:54:13 EDT
Koji build:
http://koji.fedoraproject.org/koji/taskinfo?taskID=585565

Breaks on ppc64 at the moment because we need to add the ppc64
build patch.
Comment 3 Jason Tibbitts 2008-05-10 22:16:08 EDT
This does not seem to be buildable yet outside of koji; ocaml 3.10.2 doesn't
seem to exist anywhere.
Comment 4 Richard W.M. Jones 2008-05-12 06:53:58 EDT
Yes, let's wait for Rawhide on this one.
Comment 5 Jason Tibbitts 2008-06-04 21:16:48 EDT
Well, I can build it now, but this rpmlint complaint confuses me:
  ocaml-cmigrep.x86_64: W: executable-stack /usr/bin/cmigrep
I don't recall seeing this with ocaml executables in the past.  It might be new
with recent versions of rpmlint, but I'm not sure.
Comment 6 Richard W.M. Jones 2008-06-09 11:26:26 EDT
Bug filed: bug 450551
Comment 7 Richard W.M. Jones 2008-06-09 14:39:27 EDT
I've verified that this warning can be removed.  However you need to
rebuild ocaml (3.10.2-4), ocaml-findlib and ocaml-pcre, then cmigrep,
because any object file which wasn't built with the non-executable-stack
patch 'infects' the resulting binary.  Given that, it's probably worth just
ignoring the warning for now.

$ rpmlint /home/rjones/rpmbuild/SRPMS/ocaml-cmigrep-1.5-2.fc10.src.rpm 
/home/rjones/rpmbuild/RPMS/x86_64/ocaml-cmigrep-1.5-2.fc10.x86_64.rpm
ocaml-cmigrep.src:66: W: configure-without-libdir-spec
2 packages and 0 specfiles checked; 0 errors, 1 warnings.

Here's a new package which also fixes the ppc64 build problem.

Spec URL: http://www.annexia.org/tmp/ocaml/ocaml-cmigrep.spec
SRPM URL: http://www.annexia.org/tmp/ocaml/ocaml-cmigrep-1.5-2.fc10.src.rpm
Description: Search OCaml compiled interface (cmi) files

* Mon Jun  9 2008 Richard W.M. Jones <rjones@redhat.com> - 1.5-2
- Include ppc64 compiler patch.
- Include MAP_32BITS compiler patch.
- Include no-executable-stack compiler patch.
- Rebuild for OCaml 3.10.2-4
  (https://bugzilla.redhat.com/show_bug.cgi?id=444428#c5)

Comment 8 Jason Tibbitts 2008-06-18 18:59:02 EDT
I guess selinux will probably become annoyed by the executable stack, but as
long as the package isn't broken in general I don't see a need to wait until
everything rebuilds.  That hasn't happened so far, so I won't wait any longer.

I don't think it's particularly pretty to have to include the entire compiler
source, but I've had to do the same thing and I don't see an alternative other
than waiting for the one you mention in the spec to happen.

Besides, there really isn't much to this package, just a lot of build time for
one file.

You should probably include the COPYING file as %doc as well.  That's really the
only nit I see to pick.

* source files match upstream:
  e420d4ad1ebf062bb4d02028fadccd11a6c5cf7ddde159ebb607f2fefa4ea989  
   cmigrep-1.5.tar.bz2
  3755a32da1a7490d47fff7838c12c754d3fcfe69d7c9ff2358704259dc477c58  
   ocaml-3.10.2.tar.bz2
* package meets naming and versioning guidelines.
* specfile is properly named, is cleanly written and uses macros consistently.
* summary is OK.
* description is OK.
* dist tag is present.
* build root is OK.
* license field matches the actual license.
* license is open source-compatible.
* license text included in package.
* latest version is being packaged.
* BuildRequires are proper.
* %clean is present.
* package builds in mock (rawhide, x86_64).
* package installs properly.
* rpmlint has acceptable complaints.
* final provides and requires are sane:
   ocaml-cmigrep = 1.5-2.fc10
  =
   libpcre.so.0()(64bit)

* no shared libraries are added to the regular linker search paths.
* owns the directories it creates.
* doesn't own any directories it shouldn't.
* no duplicates in %files.
* file permissions are appropriate.
* no scriptlets present.
* code, not content.
* documentation is small, so no -doc subpackage is necessary.
* %docs are not necessary for the proper functioning of the package.

APPROVED
Comment 9 Jason Tibbitts 2008-08-20 16:57:40 EDT
Since I note that you're around currently, I thought I'd ask what was happening with this package since it's been a couple of months.
Comment 10 Richard W.M. Jones 2008-08-21 08:20:58 EDT
What happened is I stupidly forgot about it.  Thanks (yet again!) for your
work.  I'll file a CVS request now, although I don't expect anything to
happen for quite a while because of the continuing Fedora infrastructure
problems ...
Comment 11 Richard W.M. Jones 2008-08-21 08:28:03 EDT
New Package CVS Request
=======================
Package Name: ocaml-cmigrep
Short Description: Search OCaml compiled interface (cmi) files
Owners: rjones
Branches: F-9
InitialCC: rjones
Comment 12 Kevin Fenzi 2008-08-25 15:56:40 EDT
cvs done.

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