pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Why can't I see/use plugins in www/liferea?



On Sat, 28 Aug 2021 at 09:04, Thomas Klausner <wiz%netbsd.org@localhost> wrote:
>
> Hi!
>
> I've just enabled python3 support in libpeas by default.
> I hope this fixes the original problem, let me know!
>  Thomas


Not with python3.7, as it lacks  python-3.7-embed.pc as follows:

# See: man pkg-config
prefix=/usr/pkg
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

Name: Python
Description: Embed Python into an application
Requires:
Version: 3.7
Libs.private: -lcrypt -lintl -lpthread  -lutil -lm
Libs: -Wl,-R${libdir} -L${libdir} -lpython3.7
Cflags: -I${includedir}/python3.7

Later python versions do have the corresponding file and should work,
but I haven't tried them.

I was able to build the package by placing the above file in
work/.buildlinks/lib/pkgconfig and rebuilding in place (rm
work/.configure_done work/.build_done; rm -r
work/libpeas-1.26.0/output; make).

Chavdar

>
> On Fri, Aug 27, 2021 at 10:26:07PM +0100, Chavdar Ivanov wrote:
> > I managed to build libpeas with python3 support, entirely manually
> > fighting with ninja. My default python is still 3.7 and I have only
> > python-3.7.pc; for some reason neither python was found during the
> > config stage and the necessary include files, libraries and .pc files
> > linked under .buildlink; I added them manually; examining the meson
> > output, I found it was looking for python3.pc and python3-embed.pc ; I
> > copied python-3.7.pc to python3.pc in the pkgconfig directory and
> > created python3-embed.pc (modified python-3.8-embed.pc as there was no
> > python-3.7-embed.pc at all). After that meson found the embedded
> > python3.7 and managed to build libpython3loader.so, but the latter was
> > not linked to libpython3.7.so; I ran the ninja command with -v, caught
> > the output and added '-lpython3.7'; the resulting libpython3loader.so
> > works fine - with both gedit and liferea.
> >
> > Overall a bit of an exercise for the package maintainer - I am not
> > sure how to approach the meson/ninja stuff with respect to paching the
> > process. But there is no reason not to enable this, I guess.
> >
> > Screenshot attached.
> >
> > On Fri, 27 Aug 2021 at 16:48, Ottavio Caruso
> > <ottavio2006-usenet2012%yahoo.com@localhost> wrote:
> > >
> > > On 27/08/2021 14:35, Ottavio Caruso wrote:
> > > > On 27/08/2021 12:22, Chavdar Ivanov wrote:
> > > >> On Fri, 27 Aug 2021 at 10:49, Chavdar Ivanov <ci4ic4%gmail.com@localhost> wrote:
> > > >>>
> > > >>> Tested under NetBSD-current of today and current pkgsrc.
> > > >>>
> > > >>> liferea plugin system is enabled when --enable-introspection is given
> > > >>> on the configure command line - which is not in the current package
> > > >>> build state.
> > > >>>
> > > >>> I distcleaned the work directory and reran configure as below,
> > > >>>
> > > >>> This fails with my system make (bmake in your context) in
> > > >>> /usr/pkg/share/gobject-introspection-1.0/Makefile.introspection, which
> > > >>> apparently needs gmake. I was able to go a bit further by running the
> > > >>> configure script with /usr/pkg/gnu/bin in front of the PATH, but it
> > > >>> failed the final link stage - it reported not being able to find
> > > >>> LibXinerama.so.2, which I couldn't figure out - the configure
> > > >>> invocation was:
> > > >>>
> > > >>> ./configure --x-includes=/usr/X11R7/include
> > > >>> --x-libraries=/usr/X11R7/lib --prefix=/usr/pkg --build=x86_64--netbsd
> > > >>> --host=x86_64--netbsd --mandir=/usr/pkg/man
> > > >>> --enable-option-checking=yes --enable-introspection
> > > >>>
> > > >>> so it should have been found.
> > > >>>
> > > >>> Chavdar
> > > >>
> > > >> It turned out the reason is that devel/libpeas does not include the
> > > >> loaders:
> > > >> ....
> > > >> (liferea:11173): libpeas-WARNING **: 12:34:25.653: Failed to load
> > > >> module 'python3loader': Cannot open
> > > >> "/usr/pkg/lib/libpeas-1.0/loaders/libpython3loader.so"
> > > >> ....
> > > >>
> > > >> even if I added CONFIGURE_ARGS+=        --enable-introspection to the
> > > >> Makefile.
> > > >>
> > > >> I tried to mess with libpeas, but I can't get it to build the loaders,
> > > >> even when enabling them in the Makefile, which contains:
> > > >> ...
> > > >> # XXX: revisit at later date if something needs this
> > > >> ...
> > > >> and disables the loaders; I guess the maintainer should do just that,
> > > >> as plugins are disabled for other programs using them, i.e. gedit:
> > > >>
> > > >> ...
> > > >> (gedit:12666): libpeas-WARNING **: 12:37:09.554: Failed to load module
> > > >> 'python3loader': Cannot open
> > > >> "/usr/pkg/lib/libpeas-1.0/loaders/libpython3loader.so"
> > > >>
> > > >> (gedit:12666): libpeas-WARNING **: 12:37:09.554: Could not load plugin
> > > >> loader 'python3'
> > > >> ...
> > > >>
> > > >> A pr perhaps...
> > > >
> > > >
> > > > Well spotted agin. Maybe somebody could offer a pointer on how to fix
> > > > this in libpeas?
> > > >
> > > >
> > >
> > >
> > > Even fiddling with both Makefiles:
> > >
> > > [chroot]:~/cvs/pkgsrc/current/pkgsrc# diff -u www/liferea/Makefile.old
> > > www/liferea/Makefile
> > > --- www/liferea/Makefile.old    2021-08-27 12:53:56.596852029 +0000
> > > +++ www/liferea/Makefile        2021-08-27 13:03:51.541792457 +0000
> > > @@ -21,6 +21,8 @@
> > >
> > >   GLIB_SCHEMAS=         net.sf.liferea.gschema.xml
> > >
> > > +CONFIGURE_ARGS+= --enable-introspection=yes
> > > +
> > >   .include "../../databases/sqlite3/buildlink3.mk"
> > >   .include "../../devel/glib2/schemas.mk"
> > >   .include "../../devel/libpeas/buildlink3.mk"
> > > [chroot]:~/cvs/pkgsrc/current/pkgsrc# diff -u devel/libpeas/Makefile.old
> > > devel/libpeas/Makefile
> > > --- devel/libpeas/Makefile.old  2021-08-27 15:35:53.318037953 +0000
> > > +++ devel/libpeas/Makefile      2021-08-27 15:36:18.845863604 +0000
> > > @@ -15,7 +15,7 @@
> > >
> > >   # XXX: revisit at later date if something needs this
> > >   MESON_ARGS+=  -Dpython2=false
> > > -MESON_ARGS+=   -Dpython3=false
> > > +#MESON_ARGS+=  -Dpython3=false
> > >   MESON_ARGS+=  -Dlua51=false
> > >
> > >   PYTHON_FOR_BUILD_ONLY=        tool
> > >
> > >
> > >
> > > doesn't address the issue.
> > >
> > > --
> > > Ottavio Caruso
> > >
> >
> >
> > --
> > ----
>
>


-- 
----


Home | Main Index | Thread Index | Old Index