public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Alan McKinnon <alan.mckinnon@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] flags: v4l and v4l2
Date: Thu, 4 Nov 2010 21:11:53 +0200	[thread overview]
Message-ID: <201011042111.53864.alan.mckinnon@gmail.com> (raw)
In-Reply-To: <loom.20101104T182920-544@post.gmane.org>

Apparently, though unproven, at 19:34 on Thursday 04 November 2010, James did 
opine thusly:

> Hello,
> 
> 
> My google is not sufficient to flesh out the difference
> (other than the obvious)  of these 2 flags.
> 
> Where would I read about the deep, detailed difference
> in flags that appear similar in purpose?

$ grep v4l /var/portage/profiles/use.*
/var/portage/profiles/use.desc:v4l - Enables video4linux support
/var/portage/profiles/use.desc:v4l2 - Enable video4linux2 support

To grok that, you need to know a little about the video4linux project. It's 
safe to assume as step 1 that v4l builds support for video4linux (which is 
deprecated, moribund, obsolete or discarded depending on your point of view);
and v4l2 is support for the currently supported video4linux2 project.

Considering your line of work, you likely work with this and already know it.

I suppose there are tools that display info about flags (euse is good for the 
quick one-line description), but if I want to know what is actually being 
*done* with a USE flag, I look in the ebuild. Nothing quite like reading the 
code, eh?

"equery depends" shows info but it really just greps the portage tree or 
/var/lib/something with default settings (search installed packages only).
Reading the ebuild shows you the context too which often contains very 
valuable info. "equery hasuse" quickly shows installed packages that use a 
specified flag.

The ffmpeg ebuild shows that ffmpeg supports both projects, you just say which 
you want. The ebuild for sane-backends reveals:

RDEPEND="v4l? ( media-libs/libv4l )"

which I'm certain is a current project using v4l2. Oops, initial assumption 
about flags above is probably wrong. Oh well, it's code, this happens. A lot.

> How would/should I know when flags are deprecated, or
> on the fast track to becoming deprecated?

$PORTDIR/package.mask has info about why things are masked
$PORTDIR/use*desc contains the one-line description of flags
$PORTDIR/profiles/ChangeLog has useful info about all sorts of stuff.
Anything in $PORTDIR with "use" in it's name is worth a look

> It there systematic (methologies/syntax) to
> discover such nuggets of knowledge?

Not that I ever found. It's more a case of familiarity with where things are 
found and a deep knowledge of grep :-)

And ChangeLogs are always the best source of info. That's true for almost all 
projects out there.


-- 
alan dot mckinnon at gmail dot com



  reply	other threads:[~2010-11-04 19:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-04 17:34 [gentoo-user] flags: v4l and v4l2 James
2010-11-04 19:11 ` Alan McKinnon [this message]
2010-11-04 19:13 ` Paul Hartman
2010-11-05  1:02   ` [gentoo-user] " James
2010-11-05  2:52     ` Brennan Shacklett
2010-11-05 12:59       ` James
2010-11-05  7:39     ` Alan McKinnon
2010-11-05 13:10       ` James

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201011042111.53864.alan.mckinnon@gmail.com \
    --to=alan.mckinnon@gmail.com \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox