On Thu, May 17, 2018 at 02:51:10PM +0200, Gerd Hoffmann wrote:
> > > +ifeq ($(CONFIG_X11),y)
> > > +sdl.mo-objs += x_keymap.o
> > > +gtk.mo-objs += x_keymap.o
> > Would this cause symbol clash if both sdl & gtk modules are loaded
> > at the same time, or have we used linker scripts to limit what symbols
> > each module exposes ?
> Related: can modules depend on modules, so we could make x_keymap a
> module of its own and have both gtk and sdl depend on it?
> That would also be useful when trying to modularize spice.
Yes, you could create a xkeymap.so, and link to that from both
sdl.so and gtk.so, so you'll only get one copy of xkeymap.so if
both are loaded.
I don't think it is worth it for this particular case though, since
we'll be deleting the SDL1 code when 2.14 dev cycle opens, leaving
GTK as the only user of it. SDL2 already has abstracted keycodes.
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|