VirtualBox

Changeset 11725 in vbox for trunk/src/VBox/Frontends/VBoxBFE


Ignore:
Timestamp:
Aug 27, 2008 10:21:47 PM (16 years ago)
Author:
vboxsync
Message:

#3076: Merged in the branch with the alternate driver authentication method. (34468:HEAD)

Location:
trunk/src/VBox/Frontends/VBoxBFE
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VBoxBFE/Makefile.kmk

    r10058 r11725  
    2828include $(KBUILD_PATH)/subheader.kmk
    2929
    30 PROGRAMS += VBoxBFE
     30#
     31# Targets.
     32#
     33ifdef VBOX_WITH_HARDENING
     34 ifneq ($(KBUILD_TARGET),darwin) # No hardened VBoxBFE on darwin (.m).
     35  PROGRAMS += VBoxBFEHardened
     36  DLLS += VBoxBFE
     37 endif
     38else
     39 PROGRAMS += VBoxBFE
     40endif
     41
     42#
     43# Hardened VBoxBFE.
     44#
     45VBoxBFEHardened_TEMPLATE = VBOXR3HARDENEDEXE
     46VBoxBFEHardened_SOURCES = VBoxBFEHardened.cpp
     47VBoxBFEHardened_NAME = VBoxBFE
     48
    3149
    3250#
    3351# VBoxBFE
    3452#
    35 VBoxBFE_TEMPLATE = VBOXR3NPEXE
     53VBoxBFE_TEMPLATE =
     54VBoxBFE_TEMPLATE  := $(if $(VBOX_WITH_HARDENING),VBOXR3NP,VBOXR3NPEXE)
    3655#ifdef VBOX_WITH_SECURELABEL
    3756#VBoxBFE_DEFS += VBOX_SECURELABEL
  • trunk/src/VBox/Frontends/VBoxBFE/VBoxBFE.cpp

    r11158 r11725  
    415415
    416416/** entry point */
    417 int main(int argc, char **argv)
     417extern "C" DECLEXPORT(int) TrustedMain (int argc, char **argv, char **envp)
    418418{
    419 #ifdef RT_OS_L4
    420 #ifndef L4API_l4v2onv4
    421     /* clear Fiasco kernel trace buffer */
    422     fiasco_tbuf_clear();
    423 #endif
    424     /* set the environment.  Must be done before the runtime is
    425        initialised.  Yes, it really must. */
    426     for (int i = 0; i < argc; i++)
    427         if (strcmp(argv[i], "-env") == 0)
    428         {
    429             if (++i >= argc)
    430                 return SyntaxError("missing argument to -env (format: var=value)!\n");
    431             /* add it to the environment */
    432             if (putenv(argv[i]) != 0)
    433                 return SyntaxError("Error setting environment string %s.\n", argv[i]);
    434         }
    435 #endif /* RT_OS_L4 */
    436 
    437     /*
    438      * Before we do *anything*, we initialize the runtime.
    439      */
    440     int rc = RTR3Init();
    441     if (VBOX_FAILURE(rc))
    442         return FatalError("RTR3Init failed rc=%Vrc\n", rc);
    443 
    444 
    445419    bool fFullscreen = false;
    446420#ifdef VBOX_VRDP
     
    455429    uint32_t u32MaxVRAM;
    456430#endif
     431    int rc = VINF_SUCCESS;
    457432
    458433    RTPrintf("VirtualBox Simple SDL GUI built %s %s\n", __DATE__, __TIME__);
     
    1011986
    1012987
     988#ifndef VBOX_WITH_HARDENING
     989/**
     990 * Main entry point.
     991 */
     992int main(int argc, char **argv)
     993{
     994# ifdef RT_OS_L4
     995# ifndef L4API_l4v2onv4
     996    /* clear Fiasco kernel trace buffer */
     997    fiasco_tbuf_clear();
     998# endif
     999    /* set the environment.  Must be done before the runtime is
     1000       initialised.  Yes, it really must. */
     1001    for (int i = 0; i < argc; i++)
     1002        if (strcmp(argv[i], "-env") == 0)
     1003        {
     1004            if (++i >= argc)
     1005                return SyntaxError("missing argument to -env (format: var=value)!\n");
     1006            /* add it to the environment */
     1007            if (putenv(argv[i]) != 0)
     1008                return SyntaxError("Error setting environment string %s.\n", argv[i]);
     1009        }
     1010# endif /* RT_OS_L4 */
     1011
     1012    /*
     1013     * Before we do *anything*, we initialize the runtime.
     1014     */
     1015    int rc = RTR3Init();
     1016    if (VBOX_FAILURE(rc))
     1017        return FatalError("RTR3Init failed rc=%Vrc\n", rc);
     1018
     1019    return TrustedMain(argc, argv, NULL);
     1020}
     1021#endif /* !VBOX_WITH_HARDENING */
     1022
    10131023
    10141024/**
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