Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 278464 - x11-libs/libwnck 2.26.1: unconditional dependency on startup-notification
Summary: x11-libs/libwnck 2.26.1: unconditional dependency on startup-notification
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: AMD64 Linux
: High enhancement (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords: Inclusion
Depends on:
Blocks: gnome2.26
  Show dependency tree
 
Reported: 2009-07-20 13:20 UTC by Darren Smith
Modified: 2009-08-11 23:48 UTC (History)
1 user (show)

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


Attachments
ldd libwnck output (ldd.out,566 bytes, text/plain)
2009-07-21 12:20 UTC, Darren Smith
Details
ebuild (libwnck-2.26.2.ebuild,989 bytes, text/plain)
2009-07-28 03:39 UTC, Darren Smith
Details
patch (libwnck-2.26.2-configure.patch,1.56 KB, text/plain)
2009-07-28 03:40 UTC, Darren Smith
Details
ebuild (libwnck-2.26.2-r1.ebuild,984 bytes, text/plain)
2009-07-28 12:17 UTC, Darren Smith
Details
patch (libwnck-2.26.2-configure.patch,1.48 KB, patch)
2009-08-03 22:13 UTC, Darren Smith
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Darren Smith 2009-07-20 13:20:52 UTC
libwnck 2.26.1+ unconditionally depends on startup-notification. I have changed my local ebuild to this:

	startup-notification? ( >=x11-libs/startup-notification-0.4 )

This prevents the following packages from being installed during a world update:

[nomerge      ] xfce-base/xfce4-4.6.1  USE="alsa cups xscreensaver -minimal -oss"  [0]
[nomerge      ]  xfce-base/xfce4-session-4.6.1  USE="-debug -gnome"  [0]
[nomerge      ]   x11-libs/libwnck-2.26.2 [2.26.1] USE="-doc (-debug%)"  [?=>0]
[ebuild  N    ]    x11-libs/startup-notification-0.10  0 kB [0]

-- and --

[nomerge      ] x11-libs/startup-notification-0.10  [0]
[ebuild  N    ]  x11-libs/xcb-util-0.3.3  USE="-debug -test" 0 kB [0]
[ebuild  N    ]   x11-libs/libxcb-1.1.90.1  USE="-debug -doc (-selinux)" 0 kB [0]
[ebuild  N    ]    x11-proto/xcb-proto-1.2  0 kB [0]

I made this change starting with 2.26.1 and encountered no build/run problems. I have encountered no build problems with 2.26.2 and will begin running it later today. If I find any problems I will add that information to this report.

Please consider making this change to the ebuild. Thank you!
Comment 1 Rémi Cardona (RETIRED) gentoo-dev 2009-07-21 08:01:03 UTC
So you're relying on automagic deps within libwnck? If so, that needs to be changed before we can consider adding a new USE flag.

Thanks
Comment 2 Darren Smith 2009-07-21 11:35:29 UTC
(In reply to comment #1)
> So you're relying on automagic deps within libwnck? If so, that needs to be
> changed before we can consider adding a new USE flag.

I don't understand this comment. I don't have the startup-notification package installed if that's what you're asking.

# emerge -pv startup-notification

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild  N    ] x11-proto/xcb-proto-1.2  0 kB
[ebuild  N    ] x11-libs/libxcb-1.1.90.1  USE="-debug -doc (-selinux)" 0 kB
[ebuild  N    ] x11-libs/xcb-util-0.3.3  USE="-debug -test" 0 kB
[ebuild  N    ] x11-libs/startup-notification-0.10  0 kB
Comment 3 Darren Smith 2009-07-21 12:20:14 UTC
Created attachment 198698 [details]
ldd libwnck output

Further verification that libwnck doesn't depend on startup-notification. Command was 'ldd /usr/lib64/libwnck-1.so.22.3.20 | awk '{print $1}' | sort'.
Comment 4 Pacho Ramos gentoo-dev 2009-07-27 12:34:25 UTC
I think that Remi refers to automagic deps, please read:
http://www.gentoo.org/proj/en/qa/automagic.xml
Comment 5 Darren Smith 2009-07-27 22:25:34 UTC
(In reply to comment #4)
> I think that Remi refers to automagic deps, please read:
> http://www.gentoo.org/proj/en/qa/automagic.xml

Thanks for the link Pacho. I kind of assumed that's what Remi meant. The ldd output shows that the startup-notification library is not linked against libwnck in any way. Also, it's not installed on my system so it'd be hard for it to be used. I think adding this flag to libwnck is a safe thing to do. It's already part of a number of the xfce packages as well as firefox/xulrunner. Thanks!
Comment 6 Rémi Cardona (RETIRED) gentoo-dev 2009-07-27 23:16:35 UTC
Darren, the problem isn't whether libwnck can work with or without startup-notification. The real issue is whether we (as ebuild writers) can _force_ it either on or off depending on a USE flag.

Relying on ./configure to figure out if the support can be enabled or not is a major QA offense.

So the question I asked back in comment #1 still stands : is there a knob (ie, --enable/disable-startup-notification) we can tweak to force the support on or off? If there isn't one, then configure.ac needs to be patched to create one.

Thanks
Comment 7 Darren Smith 2009-07-28 03:39:20 UTC
Created attachment 199401 [details]
ebuild
Comment 8 Darren Smith 2009-07-28 03:40:10 UTC
Created attachment 199402 [details]
patch
Comment 9 Darren Smith 2009-07-28 03:42:09 UTC
(In reply to comment #6)
> So the question I asked back in comment #1 still stands : is there a knob (ie,
> --enable/disable-startup-notification) we can tweak to force the support on or
> off? If there isn't one, then configure.ac needs to be patched to create one.

Thanks for explaining. That makes sense. I've attached an updated ebuild and configure patch. The released configure script did not have a way to enable/disable startup-notification.
Comment 10 Romain Perier (RETIRED) gentoo-dev 2009-07-28 05:55:41 UTC
- configure patch seems to be correct.

- Be warn about the ebuild because you just invoke eautoconf, in case where there are no other AC_ARG_ENABLE() macro into the configure.in the eautoconf could fail,
 because aclocal needs to be invoked before (otherwises m4 definiton of AC_ARG_ENABLE is unknow). But if there is another call of this macro into the configure script don't considere this sentence :)
Comment 11 Romain Perier (RETIRED) gentoo-dev 2009-07-28 06:04:50 UTC
Btw you can use pkg_setup() directly to set econf argument like this:

pkg_setup() {
 G2CONF= "$(use_enable startup-notification)"
}

and then drop src_configure() :)
Comment 12 Darren Smith 2009-07-28 12:17:38 UTC
Created attachment 199429 [details]
ebuild
Comment 13 Darren Smith 2009-07-28 12:24:39 UTC
(In reply to comment #10)
> - Be warn about the ebuild because you just invoke eautoconf, in case where
> there are no other AC_ARG_ENABLE() macro into the configure.in the eautoconf
> could fail,
>  because aclocal needs to be invoked before (otherwises m4 definiton of
> AC_ARG_ENABLE is unknow). But if there is another call of this macro into the
> configure script don't considere this sentence :)

Great information. AC_ARG_ENABLE is called before this call in configure.in for "enable_deprecations" so I guess it's ok? If I call eautoreconf instead of eautoconf the configure fails. It also fails if I call eaclocal before eautoconf. I've incorporated your pkg_setup change. Thanks!
Comment 14 Romain Perier (RETIRED) gentoo-dev 2009-07-28 15:50:58 UTC
for each ~arch in KEYWORDS did you test it ?
otherwises just put into KEYWORDS arch you tested (~arch of course)

hey except these items it's fine :)
Comment 15 Rémi Cardona (RETIRED) gentoo-dev 2009-07-28 16:01:28 UTC
(In reply to comment #14)
> for each ~arch in KEYWORDS did you test it ?
> otherwises just put into KEYWORDS arch you tested (~arch of course)

It's not a new package, it's just a patch. The current list of arches is fine.
Comment 16 Romain Perier (RETIRED) gentoo-dev 2009-07-29 06:04:31 UTC
(In reply to comment #15)
> (In reply to comment #14)
> > for each ~arch in KEYWORDS did you test it ?
> > otherwises just put into KEYWORDS arch you tested (~arch of course)
> 
> It's not a new package, it's just a patch. The current list of arches is fine.
> 

indeed ^^
Comment 17 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-08-02 10:57:53 UTC
could you provide patch as unified diff ? (diff -Nu)
Comment 18 Darren Smith 2009-08-03 22:13:27 UTC
Created attachment 200062 [details, diff]
patch

unified diff as requested
Comment 19 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-08-03 23:08:01 UTC
looks fine even thoug the $PKGCONFIG ... --atleast ... could be factored.
Comment 20 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-08-08 22:02:52 UTC
Applied in 2.26.2-r1.

Notable changes wrt. proposed ebuild:
 * AT_M4DIR, otherwise eautoreconf (which is the only operation with eautomake
that is really allowed for ebuilds) would not work. That's because upstream
package is broken wrt handling extra macros, but it's been fixed in master.
 * G2CONF should not be overwritten in pkg_setup, always consider it's been
 modified by eclass already.
 * make use of eclass' already defined functions if they exist, you don't want
 to miss anything that's done there.
 * intltoolize --force ... is mandatory when eautoreconfing an intltoolized
 package, it might fail on various setups otherwise.
Comment 21 Darren Smith 2009-08-10 11:18:42 UTC
(In reply to comment #20)
> Applied in 2.26.2-r1.

Thanks for that information Gilles.

Did you know that libwnck is a requirement for xfce? With your changes, gnome-common is now a requirement for libwnck. Can that be changed to be conditional on the gnome USE flag?
Comment 22 Gilles Dartiguelongue (RETIRED) gentoo-dev 2009-08-10 11:50:10 UTC
(In reply to comment #21)
> Did you know that libwnck is a requirement for xfce? With your changes,
> gnome-common is now a requirement for libwnck. Can that be changed to be
> conditional on the gnome USE flag?
> 

no, that can't be removed since it won't eautoreconf otherwise, see the ChangeLog for the reference to the bug. And it's only macros, nothing to be afraid of.
Comment 23 Mart Raudsepp gentoo-dev 2009-08-11 23:48:18 UTC
As further clarification, gnome-common can be unmerged after libwnck building is done, it's a build-time dependency only.
Also, I consider the real problem to be that startup-notification-0.10 unconditionally depends on pure xcb stuff, while we really aren't ready for globally enabled XCB by default yet. I'll follow-up on that elsewhere later.

startup-notification is a good and quite small thing, so you could install startup-notification-0.9 (which doesn't force libxcb in) by locally package.masking =x11-libs/startup-notification-0.10 - exact version because later revisions will hopefully be fixed to not require xcb unconditionally.