Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 587676 - net-mail/notmuch - rename USE=debug to USE=valgrind
Summary: net-mail/notmuch - rename USE=debug to USE=valgrind
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Amadeusz Żołnowski (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-07-01 09:38 UTC by Jeroen Roovers (RETIRED)
Modified: 2017-05-18 21:07 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jeroen Roovers (RETIRED) gentoo-dev 2016-07-01 09:38:30 UTC
For architectures that do not support dev-util/valgrind we have a USE flag "valgrind" masked on those architectures. net-mail/notmuch uses USE=debug for its dev-util/valgrind dependency (in RDEPEND, even - is that even needed?) which doesn't play as well with the current profiles as USE=valgrind would. Please consider changing the USE flag.
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2016-07-01 10:47:53 UTC
Also, this is just silly:

    if use debug; then
        append-cflags -g
        append-cxxflags -g
    fi
Comment 2 Amadeusz Żołnowski (RETIRED) gentoo-dev 2016-07-01 15:53:29 UTC
(In reply to Jeroen Roovers from comment #0)
> For architectures that do not support dev-util/valgrind we have a USE flag
> "valgrind" masked on those architectures.

OK, I'll consider changing it.

> (in RDEPEND, even - is that even needed?)

No, it's only for build-time for test suites. Thanks for point that out!
Comment 3 Amadeusz Żołnowski (RETIRED) gentoo-dev 2016-07-01 15:53:42 UTC
(In reply to Jeroen Roovers from comment #1)
> Also, this is just silly:
> 
>     if use debug; then
>         append-cflags -g
>         append-cxxflags -g
>     fi

What's the problem with this?
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2016-07-02 08:33:34 UTC
(In reply to Amadeusz Żołnowski from comment #3)
> (In reply to Jeroen Roovers from comment #1)
> > Also, this is just silly:
> > 
> >     if use debug; then
> >         append-cflags -g
> >         append-cxxflags -g
> >     fi
> 
> What's the problem with this?

You override CFLAGS/CXXFLAGS. Users can set those by themselves just fine and adding that based on USE=debug is just wrong.
Comment 5 Amadeusz Żołnowski (RETIRED) gentoo-dev 2016-07-02 09:18:34 UTC
(In reply to Jeroen Roovers from comment #4)
> (In reply to Amadeusz Żołnowski from comment #3)
> > (In reply to Jeroen Roovers from comment #1)
> > > Also, this is just silly:
> > > 
> > >     if use debug; then
> > >         append-cflags -g
> > >         append-cxxflags -g
> > >     fi
> > 
> > What's the problem with this?
> 
> You override CFLAGS/CXXFLAGS. Users can set those by themselves just fine
> and adding that based on USE=debug is just wrong.

It appends flags, not overrides. -g is required for tests.
Comment 6 Jeroen Roovers (RETIRED) gentoo-dev 2016-07-02 10:11:21 UTC
(In reply to Amadeusz Żołnowski from comment #5)
> It appends flags, not overrides.

Same difference.

Maybe this will help you understand the use of USE=debug:

debug - Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces

That description has been in place for a loooong time. 

> -g is required for tests.

Then instead of with USE=debug set that with USE=test which triggers the related sys-devel/gdb dependency as well.
Comment 7 Amadeusz Żołnowski (RETIRED) gentoo-dev 2016-07-02 11:13:22 UTC
(In reply to Jeroen Roovers from comment #6)
> Maybe this will help you understand the use of USE=debug:
> 
> debug - Enable extra debug codepaths, like asserts and extra output. If you
> want to get meaningful backtraces see
> https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces

It helped, indeed. Thanks.


> > -g is required for tests.
> 
> Then instead of with USE=debug set that with USE=test which triggers the
> related sys-devel/gdb dependency as well.

I have moved dependency under test and removed debug flag.

Wrt valgrind, do you suggest to have a special flag 'valgrind' required only for test which will just pull in dev-util/valgrind? That doesn't seem to be a good idea and... notmuch doesn't have any other keywords than x86 and amd64. I could add that flag when notmuch will be available for other arch.
Comment 8 Jeroen Roovers (RETIRED) gentoo-dev 2016-07-02 11:31:39 UTC
(In reply to Amadeusz Żołnowski from comment #7)
> Wrt valgrind, do you suggest to have a special flag 'valgrind' required only
> for test which will just pull in dev-util/valgrind? That doesn't seem to be
> a good idea and...

That's not a special USE flag - USE=valgrind is used all over the place to do just that.

> notmuch doesn't have any other keywords than x86 and
> amd64. I could add that flag when notmuch will be available for other arch.

See the blocked bug. We need it now.
Comment 9 Amadeusz Żołnowski (RETIRED) gentoo-dev 2016-07-02 16:13:52 UTC
I have fixed this in notmuch-0.22-r2.ebuild. If it's necessary I'll apply changes to stable ebuilds later.
Comment 10 Amadeusz Żołnowski (RETIRED) gentoo-dev 2017-05-18 21:07:12 UTC
I have removed older ebuilds having USE=debug instead of USE=valgrind