Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 486306 - app-shells/bash-completion-2.1 - invalid version in /usr/share/pkgconfig/bash-completion.pc
Summary: app-shells/bash-completion-2.1 - invalid version in /usr/share/pkgconfig/bash...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Shell Tools project
URL:
Whiteboard:
Keywords:
: 502514 (view as bug list)
Depends on:
Blocks: 511934 517718
  Show dependency tree
 
Reported: 2013-09-28 11:56 UTC by Andreis Vinogradovs ( slepnoga )
Modified: 2014-09-06 07:38 UTC (History)
8 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
bash-completion-2.1.ebuild (bash-completion-2.1.ebuild,3.32 KB, text/plain)
2014-04-27 16:10 UTC, Ed Catmur
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andreis Vinogradovs ( slepnoga ) 2013-09-28 11:56:30 UTC
app-shells/bash-completion-2.1 install .pc file with invalid version definition.

slep@nout ~/slep/portage/app-emulation/libguestfs $ grep Version /usr/share/pkgconfig/bash-completion.pc
Version: 1.3

This bug block install bash-completion file in new app-emulation/libguestfs, i.e
dnl Bash completion.
PKG_CHECK_MODULES([BASH_COMPLETION], [bash-completion >= 2.0], [
    bash_completion=yes
    AC_MSG_CHECKING([for bash-completions directory])
    BASH_COMPLETIONS_DIR="`pkg-config --variable=completionsdir bash-completion`"
    AC_MSG_RESULT([$BASH_COMPLETIONS_DIR])
    AC_SUBST([BASH_COMPLETIONS_DIR])
],[
    bash_completion=no
    AC_MSG_WARN([bash-completion not installed])
])
AM_CONDITIONAL([HAVE_BASH_COMPLETION],[test "x$bash_completion" = "xyes"])

not work properly.
Comment 1 Ulf Dambacher 2013-11-29 08:07:51 UTC
I got struck by this, too:

The ebuild does not compile from the original package but just copies files.

therefore the file /usr/share/pkgconfig/bash-completion.pc will not be generated
be copied out of the portage FILES directory.

And with /usr/portage/app-shells/bash-completion/files/bash-competion.pc version 1.3 file is supplied!
Comment 2 Pim Vullers 2013-12-18 09:51:58 UTC
This also blocks installing app-admin/packagekit-base-0.8.15 since it detects the wrong version.
Comment 3 Serge 2014-02-26 07:30:51 UTC
confirm this too. any workaround?
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2014-03-16 02:25:05 UTC
*** Bug 502514 has been marked as a duplicate of this bug. ***
Comment 5 Ed Catmur 2014-04-27 16:10:42 UTC
Created attachment 375864 [details]
bash-completion-2.1.ebuild

Use the .pc file shipped by the package.

Because it's generated from a .in, we need to run configure.  In turn, this means that we can't delete completions/Makefile.* in src_prepare, so delete them at src_install instead.

Upstream .pc specifies /usr/share/bash-completion/completions as directory for completions, instead of /usr/share/bash-completion which is where we install them to and where eselect-bashcomp looks for them.  Rather than do surgery on the .pc file (ugh) or changing our installation directory (which would require change to eselect-bashcomp and break everyone's symlinks, so would require a migration and/or news item), install an env.d to point eselect-bashcomp to the upstream location.  At some point a maintainer should probably clean this up (anyone?).

This will want a revision bump.
Comment 6 Greg Turner 2014-05-06 11:29:50 UTC
Ed's ebuild W4M, thanks!
Comment 7 Gilles Dartiguelongue (RETIRED) gentoo-dev 2014-07-01 07:17:57 UTC
The wrong version in .pc makes packagekit-base fail to build with:

[...]
checking for BASH_COMPLETION... no
configure: error: Package requirements (bash-completion >= 2.0) were not met:

Requested 'bash-completion >= 2.0' but version of bash-completion is 1.3
You may find new versions of bash-completion at http://bash-completion.alioth.debian.org/
[...]
Comment 8 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2014-09-06 07:38:28 UTC
+*bash-completion-2.1-r2 (06 Sep 2014)
+
+  06 Sep 2014; Michał Górny <mgorny@gentoo.org> +bash-completion-2.1-r2.ebuild,
+  -bash-completion-2.1-r1.ebuild:
+  Set correct version in pkg-config file, bug #486306.

Solved it a bit different -- just added one more substitution in the Gentoo .pc file. -r90 switches to upstream file.