[PATCH weston] config-parser: Export weston_config_next_section

Bryce Harrington bryce at osg.samsung.com
Tue Feb 21 20:52:46 UTC 2017


On Tue, Feb 21, 2017 at 02:35:14PM +0200, Pekka Paalanen wrote:
> On Tue, 21 Feb 2017 11:58:20 +0000
> Emmanuel Gil Peyrot <emmanuel.peyrot at collabora.com> wrote:
> 
> > This symbol wasn’t exported from the weston binary, most likely due to
> > an oversight in 6e2c12496bbef3cc913cfe9d5f0aeb4d8b23b368, and because
> > internal modules can link against libshared.la directly it hasn’t been
> > found ever since.
> > 
> > This commit makes it possible for external modules to iterate over the
> > configuration file.
> > 
> > Signed-off-by: Emmanuel Gil Peyrot <emmanuel.peyrot at collabora.com>
> > ---
> >  shared/config-parser.c | 1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/shared/config-parser.c b/shared/config-parser.c
> > index e2b5fa25..2a595b1f 100644
> > --- a/shared/config-parser.c
> > +++ b/shared/config-parser.c
> > @@ -490,6 +490,7 @@ weston_config_get_full_path(struct weston_config *config)
> >  	return config == NULL ? NULL : config->path;
> >  }
> >  
> > +WL_EXPORT
> >  int
> >  weston_config_next_section(struct weston_config *config,
> >  			   struct weston_config_section **section,
> 
> Reviewed-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
> 
> Bryce, this is a low-risk patch which we cannot land in a stable branch
> after the release because it adds ABI to libweston and that AFAIU would
> require a minor-version bump, but the stable branch only does
> patch-version bumps. OTOH, it is not a release critical bug fix IMHO.
> You should decide if this goes in for Weston 2.0 or waits for a whole
> cycle before being released. I am fine either way, really, but I am
> also in a slightly awkward position to make the call (conflict of
> interests).
> 
> I know Emmanuel has a use case for this function in an out-of-tree
> weston plugin.

I see nothing that concerns me with the patch, and avoiding the
annoyance of an ABI bump seems reasonable enough.  Since we're already
including some other last minute patches and ought to run an RC2 anyway,
I see no reason not to toss this one in as well.

Acked-by: Bryce Harrington <bryce at osg.samsung.com>

> The whole libweston thing is a little sad: libshared.la gets built into
> libweston. config-parser.c exports functions, presumably because they
> were necessary to export from weston the executable for plugins to use.
> But because of that, libweston also now exports a bunch of functions it
> shouldn't really. I filed:
> https://phabricator.freedesktop.org/T7713

Kind of makes me idly wonder if an external dependency for config/option
parsing wouldn't be worth considering.

Bryce


More information about the wayland-devel mailing list