VirtualBox

Changeset 99564 in vbox


Ignore:
Timestamp:
May 2, 2023 1:57:51 PM (19 months ago)
Author:
vboxsync
Message:

Guest Additions/VBoxClient: Initial commit for bugref:10427. Xinerama stuff untested.

Location:
trunk/src/VBox
Files:
4 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/x11/VBoxClient/Makefile.kmk

    r98416 r99564  
    3232# This is mostly because the GA build boxes can have a very old xrandr lib, so instead of linking we dlopen.
    3333VBOX_WITH_DISTRO_XRAND_XINERAMA =
     34
     35# We want to lazy load as much stuff as possible. See #10427.
     36VBOX_WITH_VBOXCLIENT_LAZY_LOAD := 1
    3437
    3538# We don't yet have a seamless mode compilation flag, so define it here unconditionally.
     
    9093VBoxClient_LIBS.solaris = \
    9194        dl
    92 VBoxClient_LIBS = \
     95ifndef VBOX_WITH_VBOXCLIENT_LAZY_LOAD
     96 VBoxClient_LIBS = \
    9397        X11 Xt Xext Xmu
     98endif
    9499ifdef VBOX_WITH_DISTRO_XRAND_XINERAMA
    95100 VBoxClient_DEFS += WITH_DISTRO_XRAND_XINERAMA
    96  VBoxClient_LIBS += Xrandr
     101 ifndef VBOX_WITH_VBOXCLIENT_LAZY_LOAD
     102  VBoxClient_LIBS += Xrandr
     103 endif
    97104endif
    98105
     
    186193endif
    187194
     195ifdef VBOX_WITH_VBOXCLIENT_LAZY_LOAD
     196 VBoxClient_DEFS    += VBOX_WITH_VBOXCLIENT_LAZY_LOAD
     197 # Dynamic import no. 1: libX11.so.6
     198 VBoxClient_SOURCES += \
     199        $(VBoxClient_0_OUTDIR)/libX11LazyLoad.asm
     200 VBoxClient_CLEAN         += $(VBoxClient_0_OUTDIR)/libX11LazyLoad.asm
     201 $$(VBoxClient_0_OUTDIR)/libX11LazyLoad.asm: $(PATH_ROOT)/src/VBox/GuestHost/libX11.def $(VBOX_DEF_2_LAZY_LOAD) | $$(dir $$@)
     202        $(call MSG_TOOL,VBoxDef2LazyLoad,VBoxClient,$(filter %.def, $^),$@)
     203        $(QUIET)$(RM) -f -- "$@"
     204        $(VBOX_DEF_2_LAZY_LOAD) --system --library libX11.so.6 --output "$@" $(filter %.def, $^)
     205
     206 # Dynamic import no. 2: libXt.so.6
     207 VBoxClient_SOURCES += \
     208        $(VBoxClient_0_OUTDIR)/libXtLazyLoad.asm
     209 VBoxClient_CLEAN         += $(VBoxClient_0_OUTDIR)/libXtLazyLoad.asm
     210 $$(VBoxClient_0_OUTDIR)/libXtLazyLoad.asm: $(PATH_ROOT)/src/VBox/GuestHost/libXt.def $(VBOX_DEF_2_LAZY_LOAD) | $$(dir $$@)
     211        $(call MSG_TOOL,VBoxDef2LazyLoad,VBoxClient,$(filter %.def, $^),$@)
     212        $(QUIET)$(RM) -f -- "$@"
     213        $(VBOX_DEF_2_LAZY_LOAD) --system --library libXt.so.6 --output "$@" $(filter %.def, $^)
     214
     215 # Dynamic import no. 3: libXmu.so.6
     216 VBoxClient_SOURCES += \
     217        $(VBoxClient_0_OUTDIR)/libXmuLazyLoad.asm
     218 VBoxClient_CLEAN         += $(VBoxClient_0_OUTDIR)/libXmuLazyLoad.asm
     219 $$(VBoxClient_0_OUTDIR)/libXmuLazyLoad.asm: $(PATH_ROOT)/src/VBox/GuestHost/libXmu.def $(VBOX_DEF_2_LAZY_LOAD) | $$(dir $$@)
     220        $(call MSG_TOOL,VBoxDef2LazyLoad,VBoxClient,$(filter %.def, $^),$@)
     221        $(QUIET)$(RM) -f -- "$@"
     222        $(VBOX_DEF_2_LAZY_LOAD) --system --library libXmu.so.6 --output "$@" $(filter %.def, $^)
     223
     224 # Dynamic import no. 4: libXrandr.so.2
     225 VBoxClient_SOURCES += \
     226        $(VBoxClient_0_OUTDIR)/libXrandrLazyLoad.asm
     227 VBoxClient_CLEAN         += $(VBoxClient_0_OUTDIR)/libXrandrLazyLoad.asm
     228 $$(VBoxClient_0_OUTDIR)/libXrandrLazyLoad.asm: $(PATH_ROOT)/src/VBox/GuestHost/libXrandr.def $(VBOX_DEF_2_LAZY_LOAD) | $$(dir $$@)
     229        $(call MSG_TOOL,VBoxDef2LazyLoad,VBoxClient,$(filter %.def, $^),$@)
     230        $(QUIET)$(RM) -f -- "$@"
     231        $(VBOX_DEF_2_LAZY_LOAD) --system --library libXrandr.so.2 --output "$@" $(filter %.def, $^)
     232endif
     233
    188234if defined(VBOX_WITH_TESTCASES) && !defined(VBOX_ONLY_ADDITIONS) && !defined(VBOX_ONLY_SDK)
    189235 if1of ($(KBUILD_TARGET), freebsd linux netbsd openbsd solaris)
  • trunk/src/VBox/GuestHost/SharedClipboard/clipboard-x11.cpp

    r99250 r99564  
    163163  return 0;
    164164}
    165 # else
     165# else /* !RT_OS_SOLARIS_10 */
    166166const char XtStrings [] = "";
    167167_WidgetClassRec* applicationShellWidgetClass;
    168168const char XtShellStrings [] = "";
    169169# endif /* RT_OS_SOLARIS_10 */
     170#else /* !TESTCASE */
     171# ifdef VBOX_WITH_VBOXCLIENT_LAZY_LOAD
     172/* Defines needed for lazy loading global data from the shared objects (.so).
     173 * See r157060. */
     174DECLASM(WidgetClass * ) LazyGetPtr_applicationShellWidgetClass(void);
     175#define applicationShellWidgetClass (*LazyGetPtr_applicationShellWidgetClass())
     176DECLASM(const char *) LazyGetPtr_XtStrings(void);
     177#define XtStrings (LazyGetPtr_XtStrings())
     178# endif
    170179#endif /* TESTCASE */
    171180
     
    10851094        pCtx->pWidget = XtVaAppCreateShell(0, "VBoxShCl",
    10861095                                           applicationShellWidgetClass,
    1087                                            pDisplay, XtNwidth, 1, XtNheight,
    1088                                            1, NULL);
     1096                                           pDisplay,
     1097                                           XtNwidth, 1, XtNheight, 1,
     1098                                           NULL);
    10891099        if (pCtx->pWidget == NULL)
    10901100        {
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette