Bug 431381 - Review Request: unicap - Library to access different kinds of (video) capture devices
Review Request: unicap - Library to access different kinds of (video) capture...
Status: CLOSED NEXTRELEASE
Product: Fedora
Classification: Fedora
Component: Package Review (Show other bugs)
rawhide
All Linux
low Severity low
: ---
: ---
Assigned To: Parag AN(पराग)
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-02-03 18:09 EST by Robert Scheck
Modified: 2008-02-18 17:40 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-02-18 17:40:12 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
panemade: fedora‑review+
kevin: fedora‑cvs+


Attachments (Terms of Use)
libdir patch (751 bytes, patch)
2008-02-08 07:04 EST, Parag AN(पराग)
no flags Details | Diff
Proposed diff (Untested and likely incomplete) (3.73 KB, patch)
2008-02-15 00:32 EST, Ralf Corsepius
no flags Details | Diff

  None (edit)
Description Robert Scheck 2008-02-03 18:09:52 EST
Spec URL: http://labs.linuxnetz.de/bugzilla/unicap.spec
SRPM URL: http://labs.linuxnetz.de/bugzilla/unicap-0.2.19-1.src.rpm
Unicap provides a uniform interface to video capture devices. It allows
applications to use any supported video capture device via a single API.
The included ucil library provides easy to use functions to render text
and graphic overlays onto video images.
Comment 1 Parag AN(पराग) 2008-02-03 23:13:58 EST
mock build is ok. 
1) missing Requires: pkgconfig in -devel, drop pkgconfig as BR from main package.

2) rpmlint gave me
unicap-devel.i386: W: dangling-relative-symlink
/usr/lib/unicap2/cpi/libvid21394.so libvid21394.so.0.0.0
The relative symbolic link points nowhere.

unicap-devel.i386: W: dangling-relative-symlink /usr/lib/unicap2/cpi/libdcam.so
libdcam.so.0.0.0
The relative symbolic link points nowhere.

unicap-devel.i386: W: dangling-relative-symlink /usr/lib/unicap2/cpi/libv4l2.so
libv4l2.so.0.0.0
The relative symbolic link points nowhere.

unicap-devel.i386: W: dangling-relative-symlink /usr/lib/unicap2/cpi/libv4l.so
libv4l.so.0.0.0
The relative symbolic link points nowhere.

unicap-devel.i386: E: only-non-binary-in-usr-lib
There are only non binary files in /usr/lib so they should be in /usr/share.

3)
Comment 2 Parag AN(पराग) 2008-02-03 23:21:48 EST
oops clicked submit button
3) can you also include APIs and examples to -devel package?
Comment 3 Robert Scheck 2008-02-04 02:39:29 EST
to 2): The relative symlinks are pointing to files of the base package or did
I misread something? And the error seems to result from the warnings. Because 
where to put the *.so files/links when not in /usr/lib?

to 3): APIs? doc/apis seems to be nearly (?) the same like the gtk-doc stuff or 
was my look to that too fast? Adding examples is no problem.
Comment 4 Parag AN(पराग) 2008-02-04 04:29:42 EST
(In reply to comment #3)
> to 2): The relative symlinks are pointing to files of the base package or did
> I misread something? And the error seems to result from the warnings. Because 
> where to put the *.so files/links when not in /usr/lib?
> 
 I installed this and looks ok.

> to 3): APIs? doc/apis seems to be nearly (?) the same like the gtk-doc stuff or 
> was my look to that too fast? Adding examples is no problem.
 yes. APIs are already there. Only examples now you need to add.

Comment 5 Parag AN(पराग) 2008-02-04 04:30:07 EST
and please take care of point 1)
Comment 7 Parag AN(पराग) 2008-02-05 01:34:17 EST
Koji build failed =>
http://koji.fedoraproject.org/koji/taskinfo?taskID=396090

SHOULD:
   1) Change defattr usage to defattr(-,root,root,-)
   2) -devel description says only "The unicap-devel package includes header
files and libraries necessary for for developing programs which use the unicap
and ucil library." which missed to mention libunicapgtk library. Please add that
to this description line.
   3) Add README.troubleshooting to %docs
   
Comment 8 Robert Scheck 2008-02-05 05:08:15 EST
I've no 64 bit system around, so I unluckily didn't find that. /usr/lib seems 
somehow to be hardcoded and not /usr/lib(64) depending on the arch. Do you think, 
it fits to do a mv /usr/lib %{_libdir}, if we're on x86_64 etc. during build or 
should I better really fix the code, inclulde as patch and send upstream?

Shoulds are luckily no must, so I don't care about 1) - sorry
2) is accepted, will be corrected for the next build of course
3) seems just useless for non-packagers when reading the file
Comment 9 Parag AN(पराग) 2008-02-05 05:49:45 EST
(In reply to comment #8)
> I've no 64 bit system around, so I unluckily didn't find that. /usr/lib seems 
> somehow to be hardcoded and not /usr/lib(64) depending on the arch. Do you think, 
> it fits to do a mv /usr/lib %{_libdir}, if we're on x86_64 etc. during build or 
> should I better really fix the code, inclulde as patch and send upstream?

 You better fix this in code and include patch in SRPM and send same to upstream
also.

> 
> Shoulds are luckily no must, so I don't care about 1) - sorry
  ok.

> 2) is accepted, will be corrected for the next build of course
  hope to see that in next SRPM update.
> 3) seems just useless for non-packagers when reading the file
   ohh. I thought it covers also "Runtime issues" which are useful to end user
and also from configure output it said
 ***  Please read the file README.troubleshooting   *** 
 ***  if you have any trouble using this software.  *** 
NOTE:-It said using this software not compiling/packaging this software.

Anyway Ok if you will not include as its not a blocker :)
Comment 10 Parag AN(पराग) 2008-02-08 03:50:53 EST
You need following patch
=================================================================================
--- unicap-0.2.19/libunicapgtk/Makefile.am      2007-08-30 11:25:42.000000000 +0530
+++ unicap-0.2.19/libunicapgtk/Makefile.am.new  2008-02-08 11:36:51.000000000 +0530
@@ -1,6 +1,6 @@
 MAINTAINERCLEANFILES = Makefile.in
 INCLUDES = -I../include -I../libucil @GTK_PACKAGE_CFLAGS@
-AM_CPPFLAGS = $(GTK_CPPFLAGS) -DSYSCONFDIR="\"$(sysconfdir)\""
-DBACKENDDIR="\"$(prefix)/lib/unicap$(pkg_version)/backends\""
-DPKG_VERSION="\"@lt_major@\""
+AM_CPPFLAGS = $(GTK_CPPFLAGS) -DSYSCONFDIR="\"$(sysconfdir)\""
-DBACKENDDIR="\"$(libdir)/unicap$(pkg_version)/backends\""
-DPKG_VERSION="\"@lt_major@\""

 if BUILD_UNICAPGTK
 UNICAPGTK_LIB=libunicapgtk.la
================================================================================

But this requires automake in %prep. Can you check this and submit new SRPM?
Comment 11 Parag AN(पराग) 2008-02-08 07:04:18 EST
Created attachment 294345 [details]
libdir patch

This patch will solve only one issue but you need to look how to solve
hardcoded library issue. In unicap-0.2.19/cpi/vid21394/Makefile.in file, I see
its hardcoded as
libdir = $(prefix)/lib/unicap$(pkg_version)/cpi
Comment 12 Parag AN(पराग) 2008-02-08 07:06:36 EST
skip comment #10 please
Comment 13 Ralf Corsepius 2008-02-08 08:05:51 EST
The correct (TM) approach would be
1. To systematically eliminate all local overrides of libdir (such as the stuff
cited in comment #11) and to replace all occurrences of $(prefix)/lib with
$(libdir) in all Makefile.ams.
2. To regenerate the Makefile.ins and create a patch from the results.
Comment 14 Robert Scheck 2008-02-08 09:34:27 EST
I'll have a look to this likely this evening, because I was at a customer
on-site the last few days where I just had a lack of time.
Comment 15 Robert Scheck 2008-02-14 17:45:47 EST
libdir = $(prefix)/lib/unicap$(pkg_version)/cpi is my main problem: 

  libdir = $(libdir)/unicap$(pkg_version)/cpi
  libdir := $(libdir)/unicap$(pkg_version)/cpi
  libdir += $(libdir)/unicap$(pkg_version)/cpi

are all three not working. Suggestions?
Comment 16 Parag AN(पराग) 2008-02-15 00:16:56 EST
(In reply to comment #15)
> libdir = $(prefix)/lib/unicap$(pkg_version)/cpi is my main problem: 
> 
>   libdir = $(libdir)/unicap$(pkg_version)/cpi
>   libdir := $(libdir)/unicap$(pkg_version)/cpi
>   libdir += $(libdir)/unicap$(pkg_version)/cpi
> 
> are all three not working. Suggestions?
Yup. I tried that. Its because when you use $(libdir) it becomes recursive
substitution in above lines.
Comment 17 Ralf Corsepius 2008-02-15 00:32:11 EST
Created attachment 294976 [details]
Proposed diff (Untested and likely incomplete)

Please read what I wrote in comment #13 and c.f. the patch in the attachment.

You need to eliminate all local redefinitions of libdir, not trying to 
redefine it.
Comment 18 Parag AN(पराग) 2008-02-15 03:15:38 EST
Ralf,
  I added aclocal and automake to %prep and applied your patch but it looks to
me some problem with autotools.
here is scratch build
http://koji.fedoraproject.org/koji/taskinfo?taskID=428980

What am I missing then?
Comment 19 Parag AN(पराग) 2008-02-15 04:28:26 EST
well, After 3 to 4 scratch build attempts I got following workaround in SPEC in
addition to Ralf's patch

1)Add BR: automake libtool
2)Add following to %prep
aclocal -I m4
autoconf
automake

Successful scratch build at
http://koji.fedoraproject.org/koji/taskinfo?taskID=429171
Comment 20 Robert Scheck 2008-02-16 10:21:54 EST
Ralf and Parag, thanks for your efforts.

Spec URL: http://labs.linuxnetz.de/bugzilla/unicap.spec
SRPM URL: http://labs.linuxnetz.de/bugzilla/unicap-0.2.19-3.src.rpm
Comment 21 Parag AN(पराग) 2008-02-18 00:13:45 EST
Review:
+ package builds in mock (rawhide i386).
koji build=> http://koji.fedoraproject.org/koji/taskinfo?taskID=434209
+ rpmlint is silent for SRPM
- rpmlint is NOT silent for RPM.
unicap-devel.i386: W: dangling-relative-symlink /usr/lib/unicap2/cpi/libv4l2.so
libv4l2.so.0.0.0
unicap-devel.i386: W: dangling-relative-symlink /usr/lib/unicap2/cpi/libdcam.so
libdcam.so.0.0.0
unicap-devel.i386: W: dangling-relative-symlink /usr/lib/unicap2/cpi/libv4l.so
libv4l.so.0.0.0
unicap-devel.i386: W: dangling-relative-symlink
/usr/lib/unicap2/cpi/libvid21394.so libvid21394.so.0.0.0
unicap-devel.i386: E: only-non-binary-in-usr-lib
==> ok to accpet here.
+ source files match upstream.
0ab0a533f5c1ff3a24853d2564ffb14f  unicap-0.2.19.tar.gz
+ package meets naming and packaging guidelines.
+ specfile is properly named, is cleanly written
+ Spec file is written in American English.
+ Spec file is legible.
+ dist tag is present.
+ build root is correct.
+ license is open source-compatible.
+ License text is included in package.
+ %doc files present.
+ BuildRequires are proper.
+ Compiler flags are honoured correctly.
+ defattr usage is correct.
+ %clean is present.
+ package installed properly.
+ Macro use appears rather consistent.
+ Package contains code.
+ no static libraries.
+ libucil.pc, libunicap.pc, libunicapgtk.pc files present.
+ -devel subpackage exists.
+ no .la files.
+ translations are available.
+ Does owns the directories it creates.
+ no duplicates in %files.
+ file permissions are appropriate.
+ ldconfig scriptlets are used.
+ Package unicap-0.2.19-3.fc9 ->
  Provides: libdcam.so.0 libucil.so.2 libunicap.so.2 libunicapgtk.so.2
libv4l.so.0 libv4l2.so.0 libvid21394.so.0
  Requires: libXext.so.6 libXv.so.1 libasound.so.2 libasound.so.2(ALSA_0.9)
libasound.so.2(ALSA_0.9.0rc4) libatk-1.0.so.0 libc.so.6 libc.so.6(GLIBC_2.0)
libc.so.6(GLIBC_2.1) libc.so.6(GLIBC_2.1.3) libc.so.6(GLIBC_2.2)
libc.so.6(GLIBC_2.3.4) libc.so.6(GLIBC_2.4) libcairo.so.2 libdcam.so.0
libdl.so.2 libdl.so.2(GLIBC_2.0) libdl.so.2(GLIBC_2.1) libgcc_s.so.1
libgcc_s.so.1(GCC_3.0) libgcc_s.so.1(GCC_3.3.1) libgdk-x11-2.0.so.0
libgdk_pixbuf-2.0.so.0 libglib-2.0.so.0 libgmodule-2.0.so.0 libgobject-2.0.so.0
libgtk-x11-2.0.so.0 libm.so.6 libm.so.6(GLIBC_2.0) libogg.so.0 libpango-1.0.so.0
libpangocairo-1.0.so.0 libpangoft2-1.0.so.0 libpthread.so.0
libpthread.so.0(GLIBC_2.0) libpthread.so.0(GLIBC_2.1) libpthread.so.0(GLIBC_2.2)
libraw1394.so.8 librt.so.1 libtheora.so.0 libtheora.so.0(libtheora.so.1.0)
libucil.so.2 libunicap.so.2 libunicapgtk.so.2 libv4l.so.0 libv4l2.so.0
libvid21394.so.0 libvorbis.so.0 libvorbisenc.so.2 rtld(GNU_HASH)
+ Package unicap-devel-0.2.19-3.fc9 ->
  Requires: libdcam.so.0 libucil.so.2 libunicap.so.2 libunicapgtk.so.2
libv4l.so.0 libv4l2.so.0 libvid21394.so.0
+ Not a GUI app.

APPROVED.
Comment 22 Robert Scheck 2008-02-18 02:11:13 EST
New Package CVS Request
=======================
Package Name: unicap
Short Description: Library to access different kinds of (video) capture devices
Owners: robert
Branches: F-7 F-8 EL-4 EL-5
InitialCC: 
Cvsextras Commits: no
Comment 23 Kevin Fenzi 2008-02-18 12:33:06 EST
cvs done.
Comment 24 Robert Scheck 2008-02-18 17:40:12 EST
38378 (unicap): Build on target fedora-5-epel succeeded.

Package: unicap-0.2.19-3.fc7 Tag: dist-fc7-updates-candidate Status: complete
Package: unicap-0.2.19-3.fc8 Tag: dist-f8-updates-candidate Status: complete
Package: unicap-0.2.19-3.fc9 Tag: dist-f9 Status: complete

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