Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 673606 - net-libs/gnome-online-accounts-3.26.2 - goaowncloudprovider.c:246:26: error: called object is not a function or function pointer
Summary: net-libs/gnome-online-accounts-3.26.2 - goaowncloudprovider.c:246:26: error: ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
: 674022 675464 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-12-23 06:28 UTC by Keith Harrison
Modified: 2019-01-15 12:37 UTC (History)
5 users (show)

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


Attachments
build.log (build.log,417.79 KB, text/plain)
2018-12-23 06:28 UTC, Keith Harrison
Details
emerge --info (emerge.info,6.79 KB, text/plain)
2018-12-23 06:29 UTC, Keith Harrison
Details
patch corrects function cast (gnome-online-accounts-3.26.2_goaowncloud.patch,691 bytes, patch)
2018-12-26 08:24 UTC, Ulf Dambacher
Details | Diff
0001-Build-against-GLib-2572.patch (0001-Build-against-GLib-2572.patch,13.58 KB, patch)
2018-12-29 17:31 UTC, PhobosK
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Keith Harrison 2018-12-23 06:28:08 UTC
Created attachment 558392 [details]
build.log

gnome-online-accounts-3.26.2 does not build, not sure exactly what caused this



In file included from /usr/include/glib-2.0/glib/glist.h:32:0,
                 from /usr/include/glib-2.0/glib/ghash.h:33,
                 from /usr/include/glib-2.0/glib.h:50,
                 from /usr/include/glib-2.0/glib/gi18n-lib.h:21,
                 from goaowncloudprovider.c:23:
goaowncloudprovider.c: In function ‘build_object’:
goaowncloudprovider.c:246:26: error: called object is not a function or function pointer
   g_clear_pointer (&uri, (GDestroyNotify *) soup_uri_free);
/usr/include/glib-2.0/glib/gmem.h:121:8: note: in definition of macro ‘g_clear_pointer’
       (destroy) (_ptr);                                                        \
        ^~~~~~~
goaowncloudprovider.c: In function ‘normalize_uri’:
goaowncloudprovider.c:449:26: error: called object is not a function or function pointer
   g_clear_pointer (&uri, (GDestroyNotify *) soup_uri_free);
Comment 1 Keith Harrison 2018-12-23 06:29:24 UTC
Created attachment 558394 [details]
emerge --info
Comment 2 Keith Harrison 2018-12-23 06:30:51 UTC
# emerge -1pv gnome-online-accounts

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

Calculating dependencies... done!
[ebuild   R    ] net-libs/gnome-online-accounts-3.26.2:0/1::gentoo  USE="gnome introspection vala* -debug -kerberos" 0 KiB

Total: 1 package (1 reinstall), Size of downloads: 0 KiB
Comment 3 Denis Descheneaux 2018-12-25 04:53:54 UTC
Have the very same issue
Comment 4 Ulf Dambacher 2018-12-26 08:22:55 UTC
had the same problem:

in gmem.h this is defined:
void g_clear_pointer  (gpointer*pp, GDestroyNotify destroy);

and in gtypes.h this is defined:
typedef void (*GDestroyNotify) (gpointer       data);

so GDestroyNotify is already a function pointer.

therefore the pointer reference is wrong here:
g_clear_pointer (&uri, (GDestroyNotify *) soup_uri_free)
                                       ^

Patch follows.
compiles and installs for me. could'nt test it as I do not uses owncloud
Comment 5 Ulf Dambacher 2018-12-26 08:24:28 UTC
Created attachment 558486 [details, diff]
patch corrects function cast
Comment 6 jeremy mills 2018-12-26 12:11:53 UTC
(In reply to Ulf Dambacher from comment #5)
> Created attachment 558486 [details, diff] [details, diff]
> patch corrects function cast

moved to my local overlay and tried it out. Patch works here. Thank you. I also cant verify if cloud functions (owncloud) works because i dont use any cloud services but it does build which was my main concern. Does it matter where the patch line goes in the build as long as its in src_prepare and before gnome2_src_prepare? There was already a line there for vala and vala_src_prepare. I just placed it above them and it built the first time but wasn't sure if that was the proper way or even if it mattered.
Comment 7 Ulf Dambacher 2018-12-27 08:20:09 UTC
> Does it matter
> where the patch line goes in the build as long as its in src_prepare and
> before gnome2_src_prepare? 

I put my epatch line last, just because I think class initialization methods should run first.
But I think it wouldn't matter where.

they don't write anything about that:
https://devmanual.gentoo.org/eclass-reference/gnome2.eclass/index.html
https://devmanual.gentoo.org/ebuild-writing/functions/src_prepare/index.html

but for EAPI=6 there is a default implementation for src-prepare so you can just add an ebuild-variable

PATCHES=( "${FILESDIR}/gnome-online-accounts-3.26.2-goaowncloud.patch" )

and then it will be applied first.
Comment 8 Drew W 2018-12-29 06:17:38 UTC
This error persists in gnome-online-accounts-3.28.0 using GCC 8.2.0-r6. The patch is valid for that version as well.
Comment 9 dolphinling 2018-12-29 16:08:51 UTC
This is only a problem with dev-libs/glib >= 2.57.2

Upstream fixed it in net-libs/gnome-online-accounts-3.30.0

See https://gitlab.gnome.org/GNOME/gnome-online-accounts/merge_requests/8
https://gitlab.gnome.org/GNOME/glib/issues/1425
Comment 10 PhobosK 2018-12-29 17:31:20 UTC
Created attachment 558866 [details, diff]
0001-Build-against-GLib-2572.patch

This is the actual upstream fix as a patch.

I tried it as user patch and it works OK
Comment 11 Mart Raudsepp gentoo-dev 2018-12-29 19:11:46 UTC
*** Bug 674022 has been marked as a duplicate of this bug. ***
Comment 12 Larry the Git Cow gentoo-dev 2018-12-29 20:03:36 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=10e8fa6ffe85fa59526797bc69bd3518ccb990ad

commit 10e8fa6ffe85fa59526797bc69bd3518ccb990ad
Author:     Mart Raudsepp <leio@gentoo.org>
AuthorDate: 2018-12-29 19:39:03 +0000
Commit:     Mart Raudsepp <leio@gentoo.org>
CommitDate: 2018-12-29 20:03:14 +0000

    net-libs/gnome-online-accounts-3.28.0: fix build against glib-2.58
    
    Also remove note about gnome-common need for eautoreconf - not the case
    since 3.28 anymore.
    
    Closes: https://bugs.gentoo.org/673606
    Signed-off-by: Mart Raudsepp <leio@gentoo.org>
    Package-Manager: Portage-2.3.52, Repoman-2.3.11

 .../files/3.28.0-glib-2.58-compat.patch            | 327 +++++++++++++++++++++
 .../files/glib-2.58-compat2.patch                  |  31 ++
 .../gnome-online-accounts-3.28.0.ebuild            |   6 +-
 3 files changed, 363 insertions(+), 1 deletion(-)

Additionally, it has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=50dcee64165b3b6df19ab6146172b1179bba5fb5

commit 50dcee64165b3b6df19ab6146172b1179bba5fb5
Author:     Mart Raudsepp <leio@gentoo.org>
AuthorDate: 2018-12-29 19:59:27 +0000
Commit:     Mart Raudsepp <leio@gentoo.org>
CommitDate: 2018-12-29 20:03:14 +0000

    net-libs/gnome-online-accounts-3.24.5: fix build against glib-2.58
    
    Backported patch (needed tiny adjustments in the first commit of 2)
    to make sure we won't hit issues for stable tree, should we need to
    stabilize glib-2.58 earlier than GOA-3.28+.
    
    Bug: https://bugs.gentoo.org/673606
    Signed-off-by: Mart Raudsepp <leio@gentoo.org>
    Package-Manager: Portage-2.3.52, Repoman-2.3.11

 .../files/3.24.5-glib-2.58-compat.patch            | 328 +++++++++++++++++++++
 .../gnome-online-accounts-3.24.5.ebuild            |   5 +
 2 files changed, 333 insertions(+)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=01b8544bf09c9f0e2f02c1683b464ab8480d6a72

commit 01b8544bf09c9f0e2f02c1683b464ab8480d6a72
Author:     Mart Raudsepp <leio@gentoo.org>
AuthorDate: 2018-12-29 19:43:58 +0000
Commit:     Mart Raudsepp <leio@gentoo.org>
CommitDate: 2018-12-29 20:03:14 +0000

    net-libs/gnome-online-accounts: remove 3.26
    
    Newly added 3.28 has tiny changes compared to 3.26, so could really
    be considered a 3.26.2 bugfix release almost. More importantly, 3.26
    would need patches for glib-2.58 compat, and as the surrounding code
    is different a bit, not bothering with adapting the patch nor trying
    if the 3.24 patch backport applies.
    
    Bug: https://bugs.gentoo.org/673606
    Signed-off-by: Mart Raudsepp <leio@gentoo.org>
    Package-Manager: Portage-2.3.52, Repoman-2.3.11

 net-libs/gnome-online-accounts/Manifest            |  1 -
 .../gnome-online-accounts-3.26.2.ebuild            | 94 ----------------------
 2 files changed, 95 deletions(-)
Comment 13 Juergen Rose 2018-12-29 21:31:35 UTC
(In reply to Larry the Git Cow from comment #12)
> The bug has been closed via the following commit(s):
> 
> https://gitweb.gentoo.org/repo/gentoo.git/commit/
> ?id=10e8fa6ffe85fa59526797bc69bd3518ccb990ad
> 
> commit 10e8fa6ffe85fa59526797bc69bd3518ccb990ad
> Author:     Mart Raudsepp <leio@gentoo.org>
> AuthorDate: 2018-12-29 19:39:03 +0000
> Commit:     Mart Raudsepp <leio@gentoo.org>
> CommitDate: 2018-12-29 20:03:14 +0000
> 
>     net-libs/gnome-online-accounts-3.28.0: fix build against glib-2.58
>     
>     Also remove note about gnome-common need for eautoreconf - not the case
>     since 3.28 anymore.
>     
>     Closes: https://bugs.gentoo.org/673606
>     Signed-off-by: Mart Raudsepp <leio@gentoo.org>
>     Package-Manager: Portage-2.3.52, Repoman-2.3.11
> 
>  .../files/3.28.0-glib-2.58-compat.patch            | 327
> +++++++++++++++++++++
>  .../files/glib-2.58-compat2.patch                  |  31 ++
>  .../gnome-online-accounts-3.28.0.ebuild            |   6 +-
>  3 files changed, 363 insertions(+), 1 deletion(-)
> 
> Additionally, it has been referenced in the following commit(s):
> 
> https://gitweb.gentoo.org/repo/gentoo.git/commit/
> ?id=50dcee64165b3b6df19ab6146172b1179bba5fb5
> 
> commit 50dcee64165b3b6df19ab6146172b1179bba5fb5
> Author:     Mart Raudsepp <leio@gentoo.org>
> AuthorDate: 2018-12-29 19:59:27 +0000
> Commit:     Mart Raudsepp <leio@gentoo.org>
> CommitDate: 2018-12-29 20:03:14 +0000
> 
>     net-libs/gnome-online-accounts-3.24.5: fix build against glib-2.58
>     
>     Backported patch (needed tiny adjustments in the first commit of 2)
>     to make sure we won't hit issues for stable tree, should we need to
>     stabilize glib-2.58 earlier than GOA-3.28+.
>     
>     Bug: https://bugs.gentoo.org/673606
>     Signed-off-by: Mart Raudsepp <leio@gentoo.org>
>     Package-Manager: Portage-2.3.52, Repoman-2.3.11
> 
>  .../files/3.24.5-glib-2.58-compat.patch            | 328
> +++++++++++++++++++++
>  .../gnome-online-accounts-3.24.5.ebuild            |   5 +
>  2 files changed, 333 insertions(+)
> 
> https://gitweb.gentoo.org/repo/gentoo.git/commit/
> ?id=01b8544bf09c9f0e2f02c1683b464ab8480d6a72
> 
> commit 01b8544bf09c9f0e2f02c1683b464ab8480d6a72
> Author:     Mart Raudsepp <leio@gentoo.org>
> AuthorDate: 2018-12-29 19:43:58 +0000
> Commit:     Mart Raudsepp <leio@gentoo.org>
> CommitDate: 2018-12-29 20:03:14 +0000
> 
>     net-libs/gnome-online-accounts: remove 3.26
>     
>     Newly added 3.28 has tiny changes compared to 3.26, so could really
>     be considered a 3.26.2 bugfix release almost. More importantly, 3.26
>     would need patches for glib-2.58 compat, and as the surrounding code
>     is different a bit, not bothering with adapting the patch nor trying
>     if the 3.24 patch backport applies.
>     
>     Bug: https://bugs.gentoo.org/673606
>     Signed-off-by: Mart Raudsepp <leio@gentoo.org>
>     Package-Manager: Portage-2.3.52, Repoman-2.3.11
> 
>  net-libs/gnome-online-accounts/Manifest            |  1 -
>  .../gnome-online-accounts-3.26.2.ebuild            | 94
> ----------------------
>  2 files changed, 95 deletions(-)

The patches worked for me.
Comment 14 Mart Raudsepp gentoo-dev 2019-01-15 12:37:05 UTC
*** Bug 675464 has been marked as a duplicate of this bug. ***