Changeset 3668 in vbox
- Timestamp:
- Jul 17, 2007 8:56:37 AM (17 years ago)
- Location:
- trunk/src/VBox/Main
- Files:
-
- 33 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/AudioAdapterImpl.cpp
r3348 r3668 230 230 { 231 231 case AudioDriverType_NullAudioDriver: 232 #ifdef __WIN__232 #ifdef RT_OS_WINDOWS 233 233 #ifdef VBOX_WITH_WINMM 234 234 case AudioDriverType_WINMMAudioDriver: 235 235 #endif 236 236 case AudioDriverType_DSOUNDAudioDriver: 237 #endif /* __WIN__*/238 #ifdef __LINUX__237 #endif /* RT_OS_WINDOWS */ 238 #ifdef RT_OS_LINUX 239 239 case AudioDriverType_OSSAudioDriver: 240 240 #ifdef VBOX_WITH_ALSA 241 241 case AudioDriverType_ALSAAudioDriver: 242 242 #endif 243 #endif /* __LINUX__*/244 #ifdef __DARWIN__243 #endif /* RT_OS_LINUX */ 244 #ifdef RT_OS_DARWIN 245 245 case AudioDriverType_CoreAudioDriver: 246 246 #endif 247 #ifdef __OS2__247 #ifdef RT_OS_OS2 248 248 case AudioDriverType_MMPMAudioDriver: 249 249 #endif -
trunk/src/VBox/Main/ConsoleImpl.cpp
r3661 r3668 20 20 */ 21 21 22 #if defined( __WIN__)23 #elif defined( __LINUX__)22 #if defined(RT_OS_WINDOWS) 23 #elif defined(RT_OS_LINUX) 24 24 # include <errno.h> 25 25 # include <sys/ioctl.h> … … 1271 1271 case NetworkAttachmentType_HostInterfaceNetworkAttachment: 1272 1272 { 1273 #ifdef __WIN__1273 #ifdef RT_OS_WINDOWS 1274 1274 /* a valid host interface must have been set */ 1275 1275 Bstr hostif; … … 1295 1295 hostif.raw()); 1296 1296 } 1297 #endif /* __WIN__*/1297 #endif /* RT_OS_WINDOWS */ 1298 1298 break; 1299 1299 } … … 1910 1910 Guid (aId).raw()); 1911 1911 1912 #ifdef __DARWIN__1912 #ifdef RT_OS_DARWIN 1913 1913 /* Notify the USB Proxy that we're about to detach the device. Since 1914 1914 * we don't dare do IPC when holding the console lock, so we'll have … … 4481 4481 AssertReturn (task, VERR_GENERAL_FAILURE); 4482 4482 4483 #if defined( __WIN__)4483 #if defined(RT_OS_WINDOWS) 4484 4484 { 4485 4485 /* initialize COM */ … … 4564 4564 else 4565 4565 fHWVirtExEnabled = (hwVirtExEnabled == TriStateBool_True); 4566 #ifndef __DARWIN__/** @todo Implement HWVirtExt on darwin. See #1865. */4566 #ifndef RT_OS_DARWIN /** @todo Implement HWVirtExt on darwin. See #1865. */ 4567 4567 if (fHWVirtExEnabled) 4568 4568 { … … 5334 5334 rc = CFGMR3InsertInteger(pCfg, "FileHandle", pConsole->maTapFD[ulInstance]); RC_CHECK(); 5335 5335 } 5336 #elif defined( __WIN__)5336 #elif defined(RT_OS_WINDOWS) 5337 5337 if (fSniffer) 5338 5338 { … … 5376 5376 switch (hrc) 5377 5377 { 5378 #ifdef __LINUX__5378 #ifdef RT_OS_LINUX 5379 5379 case VERR_ACCESS_DENIED: 5380 5380 return VMSetError(pVM, VERR_HOSTIF_INIT_FAILED, RT_SRC_POS, N_( … … 5384 5384 "sure that these changes are permanently in particular if you are " 5385 5385 "using udev")); 5386 #endif /* __LINUX__*/5386 #endif /* RT_OS_LINUX */ 5387 5387 default: 5388 5388 AssertMsgFailed(("Could not attach to host interface! Bad!\n")); … … 5556 5556 break; 5557 5557 } 5558 #ifdef __WIN__5558 #ifdef RT_OS_WINDOWS 5559 5559 #ifdef VBOX_WITH_WINMM 5560 5560 case AudioDriverType_WINMMAudioDriver: … … 5569 5569 break; 5570 5570 } 5571 #endif /* __WIN__*/5572 #ifdef __LINUX__5571 #endif /* RT_OS_WINDOWS */ 5572 #ifdef RT_OS_LINUX 5573 5573 case AudioDriverType_OSSAudioDriver: 5574 5574 { … … 5583 5583 } 5584 5584 # endif 5585 #endif /* __LINUX__*/5586 #ifdef __DARWIN__5585 #endif /* RT_OS_LINUX */ 5586 #ifdef RT_OS_DARWIN 5587 5587 case AudioDriverType_CoreAudioDriver: 5588 5588 { … … 5825 5825 { 5826 5826 LogFlowThisFunc(("\n")); 5827 #ifdef __LINUX__5827 #ifdef RT_OS_LINUX 5828 5828 /* Command line to start the script with. */ 5829 5829 char szCommand[4096]; … … 5891 5891 LogFlowThisFunc(("rc=S_OK\n")); 5892 5892 return S_OK; 5893 #else /* __LINUX__not defined */5893 #else /* RT_OS_LINUX not defined */ 5894 5894 LogFlowThisFunc(("rc=E_NOTIMPL\n")); 5895 5895 return E_NOTIMPL; /* not yet supported */ … … 5951 5951 * Allocate a host interface device 5952 5952 */ 5953 #ifdef __WIN__5953 #ifdef RT_OS_WINDOWS 5954 5954 /* nothing to do */ 5955 5955 int rcVBox = VINF_SUCCESS; 5956 #elif defined( __LINUX__)5956 #elif defined(RT_OS_LINUX) 5957 5957 int rcVBox = RTFileOpen(&maTapFD[slot], "/dev/net/tun", 5958 5958 RTFILE_O_READWRITE | RTFILE_O_OPEN | RTFILE_O_DENY_NONE | RTFILE_O_INHERIT); … … 6067 6067 } 6068 6068 } 6069 #elif defined( __DARWIN__)6069 #elif defined(RT_OS_DARWIN) 6070 6070 /** @todo Implement tap networking for Darwin. */ 6071 6071 int rcVBox = VERR_NOT_IMPLEMENTED; 6072 #elif defined( __OS2__)6072 #elif defined(RT_OS_OS2) 6073 6073 /** @todo Implement tap networking for OS/2. */ 6074 6074 int rcVBox = VERR_NOT_IMPLEMENTED; … … 6559 6559 AssertReturn (!task->mProgress.isNull(), VERR_INVALID_PARAMETER); 6560 6560 6561 #if defined( __WIN__)6561 #if defined(RT_OS_WINDOWS) 6562 6562 { 6563 6563 /* initialize COM */ … … 6623 6623 static const char * const s_apszGroups[] = VBOX_LOGGROUP_NAMES; 6624 6624 RTUINT fFlags = RTLOGFLAGS_PREFIX_TIME_PROG; 6625 #if defined ( __WIN__) || defined (__OS2__)6625 #if defined (RT_OS_WINDOWS) || defined (RT_OS_OS2) 6626 6626 fFlags |= RTLOGFLAGS_USECRLF; 6627 6627 #endif … … 6964 6964 } 6965 6965 6966 #if defined( __WIN__)6966 #if defined(RT_OS_WINDOWS) 6967 6967 /* uninitialize COM */ 6968 6968 CoUninitialize(); -
trunk/src/VBox/Main/HostImpl.cpp
r3663 r3668 19 19 */ 20 20 21 #ifdef __LINUX__21 #ifdef RT_OS_LINUX 22 22 #include <sys/types.h> 23 23 #include <sys/stat.h> … … 38 38 #endif 39 39 #include <errno.h> 40 #endif /* __LINUX __*/41 42 #ifdef __WIN__40 #endif /* RT_OS_LINUX */ 41 42 #ifdef RT_OS_WINDOWS 43 43 #define _WIN32_DCOM 44 44 #include <windows.h> … … 51 51 #include <shlobj.h> 52 52 #include <cfgmgr32.h> 53 #endif /* __WIN__*/53 #endif /* RT_OS_WINDOWS */ 54 54 55 55 … … 66 66 #include "Logging.h" 67 67 68 #ifdef __DARWIN__68 #ifdef RT_OS_DARWIN 69 69 #include "darwin/iokit.h" 70 70 #endif 71 71 72 #ifdef __WIN__72 #ifdef RT_OS_WINDOWS 73 73 #include "HostNetworkInterfaceImpl.h" 74 74 #endif … … 119 119 mParent = parent; 120 120 121 #if defined ( __DARWIN__) && defined (VBOX_WITH_USB)121 #if defined (RT_OS_DARWIN) && defined (VBOX_WITH_USB) 122 122 mUSBProxyService = new USBProxyServiceDarwin (this); 123 #elif defined ( __LINUX__) && defined (VBOX_WITH_USB)123 #elif defined (RT_OS_LINUX) && defined (VBOX_WITH_USB) 124 124 mUSBProxyService = new USBProxyServiceLinux (this); 125 #elif defined ( __WIN__) && defined (VBOX_WITH_USB)125 #elif defined (RT_OS_WINDOWS) && defined (VBOX_WITH_USB) 126 126 mUSBProxyService = new USBProxyServiceWin32 (this); 127 127 #else … … 179 179 std::list <ComObjPtr <HostDVDDrive> > list; 180 180 181 #if defined( __WIN__)181 #if defined(RT_OS_WINDOWS) 182 182 int sz = GetLogicalDriveStrings(0, NULL); 183 183 TCHAR *hostDrives = new TCHAR[sz+1]; … … 199 199 while (*p); 200 200 delete[] hostDrives; 201 #elif defined( __LINUX__)201 #elif defined(RT_OS_LINUX) 202 202 #ifdef VBOX_USE_LIBHAL 203 203 if (!getDVDInfoFromHal(list)) /* Playing with #defines in this way is nasty, I know. */ … … 246 246 } 247 247 } 248 #elif defined( __DARWIN__)248 #elif defined(RT_OS_DARWIN) 249 249 PDARWINDVD cur = DarwinGetDVDDrives(); 250 250 while (cur) … … 287 287 std::list <ComObjPtr <HostFloppyDrive> > list; 288 288 289 #ifdef __WIN__289 #ifdef RT_OS_WINDOWS 290 290 int sz = GetLogicalDriveStrings(0, NULL); 291 291 TCHAR *hostDrives = new TCHAR[sz+1]; … … 307 307 while (*p); 308 308 delete[] hostDrives; 309 #elif defined( __LINUX__)309 #elif defined(RT_OS_LINUX) 310 310 #ifdef VBOX_USE_LIBHAL 311 311 if (!getFloppyInfoFromHal(list)) /* Playing with #defines in this way is nasty, I know. */ … … 363 363 } 364 364 365 #ifdef __WIN__365 #ifdef RT_OS_WINDOWS 366 366 367 367 static bool IsTAPDevice(const char *guid) … … 502 502 return S_OK; 503 503 } 504 #endif /* __WIN__*/504 #endif /* RT_OS_WINDOWS */ 505 505 506 506 STDMETHODIMP Host::COMGETTER(USBDevices)(IHostUSBDeviceCollection **aUSBDevices) … … 686 686 //////////////////////////////////////////////////////////////////////////////// 687 687 688 #ifdef __WIN__688 #ifdef RT_OS_WINDOWS 689 689 690 690 /** … … 874 874 } 875 875 876 #endif /* __WIN__*/876 #endif /* RT_OS_WINDOWS */ 877 877 878 878 STDMETHODIMP Host::CreateUSBDeviceFilter (INPTR BSTR aName, IHostUSBDeviceFilter **aFilter) … … 1458 1458 //////////////////////////////////////////////////////////////////////////////// 1459 1459 1460 #ifdef __LINUX__1460 #ifdef RT_OS_LINUX 1461 1461 # ifdef VBOX_USE_LIBHAL 1462 1462 /** … … 1878 1878 return retValue; 1879 1879 } 1880 #endif // __LINUX__1880 #endif // RT_OS_LINUX 1881 1881 1882 1882 /** … … 2206 2206 } 2207 2207 2208 #ifdef __WIN__2208 #ifdef RT_OS_WINDOWS 2209 2209 2210 2210 /* The original source of the VBoxTAP adapter creation/destruction code has the following copyright */ … … 3071 3071 } 3072 3072 3073 #endif /* __WIN__*/3074 3073 #endif /* RT_OS_WINDOWS */ 3074 -
trunk/src/VBox/Main/HostUSBDeviceImpl.cpp
r3664 r3668 841 841 } 842 842 843 #if !defined ( __WIN__)843 #if !defined (RT_OS_WINDOWS) 844 844 // these filters are temporarily ignored on Win32 845 845 if (!aData.mManufacturer.isMatch (Bstr (mUsb->pszManufacturer))) … … 1057 1057 isImportant = false; 1058 1058 break; 1059 #ifndef __WIN__/* Only windows really knows whether the device is unavailable or captured. */1059 #ifndef RT_OS_WINDOWS /* Only windows really knows whether the device is unavailable or captured. */ 1060 1060 case USBDeviceState_USBDeviceCaptured: 1061 1061 if (!mIsStatePending) … … 1080 1080 break; 1081 1081 case USBDeviceState_USBDeviceCaptured: 1082 #ifndef __WIN__/* Only Windows really knows whether the device is busy or captured. */1082 #ifndef RT_OS_WINDOWS /* Only Windows really knows whether the device is busy or captured. */ 1083 1083 if (!mIsStatePending) 1084 1084 return false; … … 1186 1186 AssertReturnVoid (isLockedOnCurrentThread()); 1187 1187 1188 #ifndef __WIN__/* no timeouts on windows yet since I don't have all the details here... */1188 #ifndef RT_OS_WINDOWS /* no timeouts on windows yet since I don't have all the details here... */ 1189 1189 if (isStatePending() && mPendingSince) 1190 1190 { -
trunk/src/VBox/Main/MachineImpl.cpp
r3652 r3668 20 20 */ 21 21 22 #if defined( __WIN__)23 #elif defined( __LINUX__)22 #if defined(RT_OS_WINDOWS) 23 #elif defined(RT_OS_LINUX) 24 24 #endif 25 25 … … 63 63 #include <algorithm> 64 64 65 #if defined( __WIN__) || defined(__OS2__)65 #if defined(RT_OS_WINDOWS) || defined(RT_OS_OS2) 66 66 #define HOSTSUFF_EXE ".exe" 67 #else /* ! __WIN__*/67 #else /* !RT_OS_WINDOWS */ 68 68 #define HOSTSUFF_EXE "" 69 #endif /* ! __WIN__*/69 #endif /* !RT_OS_WINDOWS */ 70 70 71 71 // defines / prototypes … … 2801 2801 if (type == "gui") 2802 2802 { 2803 #ifdef __DARWIN__/* Avoid Lanuch Services confusing this with the selector by using a helper app. */2803 #ifdef RT_OS_DARWIN /* Avoid Lanuch Services confusing this with the selector by using a helper app. */ 2804 2804 const char VirtualBox_exe[] = "../Resources/VirtualBoxVM.app/Contents/MacOS/VirtualBoxVM"; 2805 2805 #else … … 2810 2810 2811 2811 Utf8Str idStr = mData->mUuid.toString(); 2812 #ifdef __WIN__/** @todo drop this once the RTProcCreate bug has been fixed */2812 #ifdef RT_OS_WINDOWS /** @todo drop this once the RTProcCreate bug has been fixed */ 2813 2813 const char * args[] = {path, "-startvm", idStr, 0 }; 2814 2814 #else … … 2827 2827 2828 2828 Utf8Str idStr = mData->mUuid.toString(); 2829 #ifdef __WIN__2829 #ifdef RT_OS_WINDOWS 2830 2830 const char * args[] = {path, "-startvm", idStr, 0 }; 2831 2831 #else … … 2844 2844 2845 2845 Utf8Str idStr = mData->mUuid.toString(); 2846 #ifdef __WIN__2846 #ifdef RT_OS_WINDOWS 2847 2847 const char * args[] = {path, "-startvm", idStr, "-capture", 0 }; 2848 2848 #else … … 4262 4262 Bstr name; 4263 4263 CFGLDRQueryBSTR (attachmentNode, "name", name.asOutParam()); 4264 #ifdef __WIN__4264 #ifdef RT_OS_WINDOWS 4265 4265 /* @name can be empty on Win32, but not null */ 4266 4266 ComAssertBreak (!name.isNull(), rc = E_FAIL); … … 4354 4354 if (driver == L"null") 4355 4355 ; // Null has been set above 4356 #ifdef __WIN__4356 #ifdef RT_OS_WINDOWS 4357 4357 else if (driver == L"winmm") 4358 4358 #ifdef VBOX_WITH_WINMM … … 4364 4364 else if (driver == L"dsound") 4365 4365 audioDriver = AudioDriverType_DSOUNDAudioDriver; 4366 #endif // __WIN__4367 #ifdef __LINUX__4366 #endif // RT_OS_WINDOWS 4367 #ifdef RT_OS_LINUX 4368 4368 else if (driver == L"oss") 4369 4369 audioDriver = AudioDriverType_OSSAudioDriver; … … 4375 4375 audioDriver = AudioDriverType_OSSAudioDriver; 4376 4376 #endif 4377 #endif // __LINUX__4378 #ifdef __DARWIN__4377 #endif // RT_OS_LINUX 4378 #ifdef RT_OS_DARWIN 4379 4379 else if (driver == L"coreaudio") 4380 4380 audioDriver = AudioDriverType_CoreAudioDriver; 4381 4381 #endif 4382 #ifdef __OS2__4382 #ifdef RT_OS_OS2 4383 4383 else if (driver == L"mmpm") 4384 4384 audioDriver = AudioDriverType_MMPMAudioDriver; … … 6088 6088 CFGLDRAppendChildNode (networkAdapterNode, "HostInterface", &attachmentNode); 6089 6089 const Bstr &name = mNetworkAdapters [slot]->data()->mHostInterface; 6090 #ifdef __WIN__6090 #ifdef RT_OS_WINDOWS 6091 6091 Assert (!name.isNull()); 6092 6092 #endif … … 6169 6169 break; 6170 6170 } 6171 #ifdef __WIN__6171 #ifdef RT_OS_WINDOWS 6172 6172 case AudioDriverType_WINMMAudioDriver: 6173 # ifdef VBOX_WITH_WINMM6173 # ifdef VBOX_WITH_WINMM 6174 6174 { 6175 6175 CFGLDRSetString (adapterNode, "driver", "winmm"); 6176 6176 break; 6177 6177 } 6178 # endif6178 # endif 6179 6179 case AudioDriverType_DSOUNDAudioDriver: 6180 6180 { … … 6182 6182 break; 6183 6183 } 6184 #endif /* __WIN__*/6185 #ifdef __LINUX__6184 #endif /* RT_OS_WINDOWS */ 6185 #ifdef RT_OS_LINUX 6186 6186 case AudioDriverType_ALSAAudioDriver: 6187 # ifdef VBOX_WITH_ALSA6187 # ifdef VBOX_WITH_ALSA 6188 6188 { 6189 6189 CFGLDRSetString (adapterNode, "driver", "alsa"); 6190 6190 break; 6191 6191 } 6192 # endif6192 # endif 6193 6193 case AudioDriverType_OSSAudioDriver: 6194 6194 { … … 6196 6196 break; 6197 6197 } 6198 #endif /* __LINUX__*/6199 #ifdef __DARWIN__6198 #endif /* RT_OS_LINUX */ 6199 #ifdef RT_OS_DARWIN 6200 6200 case AudioDriverType_CoreAudioDriver: 6201 6201 { … … 6204 6204 } 6205 6205 #endif 6206 #ifdef __OS2__6206 #ifdef RT_OS_OS2 6207 6207 case AudioDriverType_MMPMAudioDriver: 6208 6208 { … … 7543 7543 unconst (mType) = IsSessionMachine; 7544 7544 7545 #if defined( __WIN__)7545 #if defined(RT_OS_WINDOWS) 7546 7546 mIPCSem = NULL; 7547 #elif defined( __OS2__)7547 #elif defined(RT_OS_OS2) 7548 7548 mIPCSem = NULLHANDLE; 7549 7549 #elif defined(VBOX_WITH_SYS_V_IPC_SESSION_WATCHER) … … 7580 7580 7581 7581 /* create the interprocess semaphore */ 7582 #if defined( __WIN__)7582 #if defined(RT_OS_WINDOWS) 7583 7583 mIPCSemName = aMachine->mData->mConfigFileFull; 7584 7584 for (size_t i = 0; i < mIPCSemName.length(); i++) … … 7590 7590 mIPCSemName.raw(), ::GetLastError()), 7591 7591 E_FAIL); 7592 #elif defined( __OS2__)7592 #elif defined(RT_OS_OS2) 7593 7593 Utf8Str ipcSem = Utf8StrFmt ("\\SEM32\\VBOX\\VM\\{%Vuuid}", 7594 7594 aMachine->mData->mUuid.raw()); … … 7713 7713 */ 7714 7714 LogFlowThisFunc (("Initialization failed.\n")); 7715 #if defined( __WIN__)7715 #if defined(RT_OS_WINDOWS) 7716 7716 if (mIPCSem) 7717 7717 ::CloseHandle (mIPCSem); 7718 7718 mIPCSem = NULL; 7719 #elif defined( __OS2__)7719 #elif defined(RT_OS_OS2) 7720 7720 if (mIPCSem != NULLHANDLE) 7721 7721 ::DosCloseMutexSem (mIPCSem); … … 7861 7861 7862 7862 /* close the interprocess semaphore before leaving the shared lock */ 7863 #if defined( __WIN__)7863 #if defined(RT_OS_WINDOWS) 7864 7864 if (mIPCSem) 7865 7865 ::CloseHandle (mIPCSem); 7866 7866 mIPCSem = NULL; 7867 #elif defined( __OS2__)7867 #elif defined(RT_OS_OS2) 7868 7868 if (mIPCSem != NULLHANDLE) 7869 7869 ::DosCloseMutexSem (mIPCSem); … … 7925 7925 AutoReaderLock alock (this); 7926 7926 7927 #if defined( __WIN__) || defined(__OS2__)7927 #if defined(RT_OS_WINDOWS) || defined(RT_OS_OS2) 7928 7928 mIPCSemName.cloneTo (id); 7929 7929 return S_OK; … … 8681 8681 Uninit::Abnormal; 8682 8682 8683 #if defined( __WIN__)8683 #if defined(RT_OS_WINDOWS) 8684 8684 8685 8685 AssertMsg (mIPCSem, ("semaphore must be created")); … … 8692 8692 ret = true; 8693 8693 8694 #elif defined( __OS2__)8694 #elif defined(RT_OS_OS2) 8695 8695 8696 8696 AssertMsg (mIPCSem, ("semaphore must be created")); -
trunk/src/VBox/Main/NetworkAdapterImpl.cpp
r3348 r3668 402 402 /** @todo Validate input string length. r=dmik: do it in XML schema?*/ 403 403 404 #ifdef __WIN__404 #ifdef RT_OS_WINDOWS 405 405 // we don't allow null strings for the host interface on Win32 406 406 // (because the @name attribute of <HostInerface> must be always present, … … 990 990 { 991 991 /* reset handle and device name */ 992 #ifdef __WIN__992 #ifdef RT_OS_WINDOWS 993 993 mData->mHostInterface = ""; 994 994 #endif -
trunk/src/VBox/Main/ProgressImpl.cpp
r3191 r3668 769 769 770 770 #if !defined (VBOX_WITH_XPCOM) 771 #if defined ( __WIN__)771 #if defined (RT_OS_WINDOWS) 772 772 773 773 ComPtr <IErrorInfo> err; … … 780 780 } 781 781 782 #endif // !defined ( __WIN__)782 #endif // !defined (RT_OS_WINDOWS) 783 783 #else // !defined (VBOX_WITH_XPCOM) 784 784 -
trunk/src/VBox/Main/SessionImpl.cpp
r3652 r3668 20 20 */ 21 21 22 #if defined( __WIN__)23 #elif defined( __LINUX__)22 #if defined(RT_OS_WINDOWS) 23 #elif defined(RT_OS_LINUX) 24 24 #endif 25 25 … … 40 40 #include <iprt/process.h> 41 41 42 #if defined( __WIN__) || defined (__OS2__)42 #if defined(RT_OS_WINDOWS) || defined (RT_OS_OS2) 43 43 /** VM IPC mutex holder thread */ 44 44 static DECLCALLBACK(int) IPCMutexHolderThread (RTTHREAD Thread, void *pvUser); … … 91 91 mType = SessionType_InvalidSessionType; 92 92 93 #if defined( __WIN__)93 #if defined(RT_OS_WINDOWS) 94 94 mIPCSem = NULL; 95 95 mIPCThreadSem = NULL; 96 #elif defined( __OS2__)96 #elif defined(RT_OS_OS2) 97 97 mIPCThread = NIL_RTTHREAD; 98 98 mIPCThreadSem = NIL_RTSEMEVENT; … … 676 676 mState = SessionState_SessionClosed; 677 677 mType = SessionType_InvalidSessionType; 678 #if defined( __WIN__)678 #if defined(RT_OS_WINDOWS) 679 679 Assert (!mIPCSem && !mIPCThreadSem); 680 #elif defined( __OS2__)680 #elif defined(RT_OS_OS2) 681 681 Assert (mIPCThread == NIL_RTTHREAD && 682 682 mIPCThreadSem == NIL_RTSEMEVENT); … … 783 783 LogFlowThisFunc (("ipcId='%ls'\n", ipcId.raw())); 784 784 785 #if defined( __WIN__)785 #if defined(RT_OS_WINDOWS) 786 786 787 787 /* … … 826 826 } 827 827 828 #elif defined( __OS2__)828 #elif defined(RT_OS_OS2) 829 829 830 830 /* We use XPCOM where any message (including close()) can arrive on any … … 884 884 { 885 885 /* release the IPC semaphore */ 886 #if defined( __WIN__)886 #if defined(RT_OS_WINDOWS) 887 887 888 888 if (mIPCSem && mIPCThreadSem) … … 898 898 } 899 899 900 #elif defined( __OS2__)900 #elif defined(RT_OS_OS2) 901 901 902 902 if (mIPCThread != NIL_RTTHREAD) … … 934 934 } 935 935 936 #if defined( __WIN__)936 #if defined(RT_OS_WINDOWS) 937 937 /** VM IPC mutex holder thread */ 938 938 DECLCALLBACK(int) IPCMutexHolderThread (RTTHREAD Thread, void *pvUser) … … 984 984 #endif 985 985 986 #if defined( __OS2__)986 #if defined(RT_OS_OS2) 987 987 /** VM IPC mutex holder thread */ 988 988 DECLCALLBACK(int) IPCMutexHolderThread (RTTHREAD Thread, void *pvUser) -
trunk/src/VBox/Main/SharedFolderImpl.cpp
r3007 r3668 147 147 * RTDirOpenFiltered() call (see HostServices/SharedFolders) that seems to 148 148 * accept both the slashified paths and not. */ 149 #if defined ( __OS2__) || defined (__WIN__)149 #if defined (RT_OS_OS2) || defined (RT_OS_WINDOWS) 150 150 if (hostPathLen > 2 && 151 151 RTPATH_IS_SEP (hostPath.raw()[hostPathLen - 1]) && -
trunk/src/VBox/Main/USBControllerImpl.cpp
r3421 r3668 1121 1121 continue; 1122 1122 1123 #if !defined ( __WIN__)1123 #if !defined (RT_OS_WINDOWS) 1124 1124 /* these filters are temporarily ignored on Win32 */ 1125 1125 if (!aData.mManufacturer.isMatch (manufacturer)) -
trunk/src/VBox/Main/USBDeviceFilterImpl.cpp
r3412 r3668 423 423 tr ("Vendor ID filter string '%ls' is not valid (error at position %d)"), 424 424 aVendorId, flt.errorPosition() + 1); 425 #if defined ( __WIN__)425 #if defined (RT_OS_WINDOWS) 426 426 // intervalic filters are temporarily disabled 427 427 if (!flt.first().isNull() && flt.first().isValid()) … … 477 477 tr ("Product ID filter string '%ls' is not valid (error at position %d)"), 478 478 aProductId, flt.errorPosition() + 1); 479 #if defined ( __WIN__)479 #if defined (RT_OS_WINDOWS) 480 480 // intervalic filters are temporarily disabled 481 481 if (!flt.first().isNull() && flt.first().isValid()) … … 531 531 tr ("Revision filter string '%ls' is not valid (error at position %d)"), 532 532 aRevision, flt.errorPosition() + 1); 533 #if defined ( __WIN__)533 #if defined (RT_OS_WINDOWS) 534 534 // intervalic filters are temporarily disabled 535 535 if (!flt.first().isNull() && flt.first().isValid()) … … 725 725 tr ("Port number filter string '%ls' is not valid (error at position %d)"), 726 726 aPort, flt.errorPosition() + 1); 727 #if defined ( __WIN__)727 #if defined (RT_OS_WINDOWS) 728 728 // intervalic filters are temporarily disabled 729 729 if (!flt.first().isNull() && flt.first().isValid()) … … 1149 1149 tr ("Vendor ID filter string '%ls' is not valid (error at position %d)"), 1150 1150 aVendorId, flt.errorPosition() + 1); 1151 #if defined ( __WIN__)1151 #if defined (RT_OS_WINDOWS) 1152 1152 // intervalic filters are temporarily disabled 1153 1153 if (!flt.first().isNull() && flt.first().isValid()) … … 1198 1198 tr ("Product ID filter string '%ls' is not valid (error at position %d)"), 1199 1199 aProductId, flt.errorPosition() + 1); 1200 #if defined ( __WIN__)1200 #if defined (RT_OS_WINDOWS) 1201 1201 // intervalic filters are temporarily disabled 1202 1202 if (!flt.first().isNull() && flt.first().isValid()) … … 1247 1247 tr ("Revision filter string '%ls' is not valid (error at position %d)"), 1248 1248 aRevision, flt.errorPosition() + 1); 1249 #if defined ( __WIN__)1249 #if defined (RT_OS_WINDOWS) 1250 1250 // intervalic filters are temporarily disabled 1251 1251 if (!flt.first().isNull() && flt.first().isValid()) … … 1422 1422 tr ("Port number filter string '%ls' is not valid (error at position %d)"), 1423 1423 aPort, flt.errorPosition() + 1); 1424 #if defined ( __WIN__)1424 #if defined (RT_OS_WINDOWS) 1425 1425 // intervalic filters are temporarily disabled 1426 1426 if (!flt.first().isNull() && flt.first().isValid()) -
trunk/src/VBox/Main/VirtualBoxBase.cpp
r3191 r3668 21 21 22 22 #if !defined (VBOX_WITH_XPCOM) 23 #if defined ( __WIN__)23 #if defined (RT_OS_WINDOWS) 24 24 #include <windows.h> 25 25 #include <dbghelp.h> … … 509 509 AssertReturn (aLock, (void) 0); 510 510 511 #if (defined( __LINUX__) || defined(__OS2__)) && defined(__GNUC__)511 #if (defined(RT_OS_LINUX) || defined(RT_OS_OS2)) && defined(__GNUC__) 512 512 513 513 RTCritSectEnterDebug (aLock, … … 515 515 (RTUINTPTR) __builtin_return_address (1)); 516 516 517 #elif defined( __WIN__)517 #elif defined(RT_OS_WINDOWS) 518 518 519 519 STACKFRAME sf; … … 572 572 RTCritSectEnter (aLock); 573 573 574 #endif // defined( __LINUX__)...574 #endif // defined(RT_OS_LINUX)... 575 575 } 576 576 … … 674 674 675 675 #if !defined (VBOX_WITH_XPCOM) 676 #if defined ( __WIN__)676 #if defined (RT_OS_WINDOWS) 677 677 678 678 ComPtr <IVirtualBoxErrorInfo> curInfo; -
trunk/src/VBox/Main/VirtualBoxErrorInfoImpl.cpp
r3191 r3668 88 88 89 89 #if !defined (VBOX_WITH_XPCOM) 90 #if defined ( __WIN__)90 #if defined (RT_OS_WINDOWS) 91 91 92 92 /** … … 143 143 } 144 144 145 #endif // defined ( __WIN__)145 #endif // defined (RT_OS_WINDOWS) 146 146 #else // !defined (VBOX_WITH_XPCOM) 147 147 -
trunk/src/VBox/Main/VirtualBoxImpl.cpp
r3482 r3668 34 34 #include "GuestOSTypeImpl.h" 35 35 36 #ifdef __WIN__36 #ifdef RT_OS_WINDOWS 37 37 #include "win32/svchlp.h" 38 38 #endif … … 276 276 { 277 277 /* start the client watcher thread */ 278 #if defined( __WIN__)278 #if defined(RT_OS_WINDOWS) 279 279 unconst (mWatcherData.mUpdateReq) = ::CreateEvent (NULL, FALSE, FALSE, NULL); 280 #elif defined( __OS2__)280 #elif defined(RT_OS_OS2) 281 281 RTSemEventCreate (&unconst (mWatcherData.mUpdateReq)); 282 282 #elif defined(VBOX_WITH_SYS_V_IPC_SESSION_WATCHER) … … 417 417 } 418 418 mWatcherData.mProcesses.clear(); 419 #if defined( __WIN__)419 #if defined(RT_OS_WINDOWS) 420 420 if (mWatcherData.mUpdateReq != NULL) 421 421 { … … 423 423 unconst (mWatcherData.mUpdateReq) = NULL; 424 424 } 425 #elif defined( __OS2__)425 #elif defined(RT_OS_OS2) 426 426 if (mWatcherData.mUpdateReq != NIL_RTSEMEVENT) 427 427 { … … 2154 2154 } 2155 2155 2156 #ifdef __WIN__2156 #ifdef RT_OS_WINDOWS 2157 2157 2158 2158 struct StartSVCHelperClientData … … 2388 2388 } 2389 2389 2390 #endif /* __WIN__*/2390 #endif /* RT_OS_WINDOWS */ 2391 2391 2392 2392 /** … … 2404 2404 2405 2405 /* sent an update request */ 2406 #if defined( __WIN__)2406 #if defined(RT_OS_WINDOWS) 2407 2407 ::SetEvent (mWatcherData.mUpdateReq); 2408 #elif defined( __OS2__)2408 #elif defined(RT_OS_OS2) 2409 2409 RTSemEventSignal (mWatcherData.mUpdateReq); 2410 2410 #elif defined(VBOX_WITH_SYS_V_IPC_SESSION_WATCHER) … … 2425 2425 2426 2426 /// @todo (dmik) Win32? 2427 #ifndef __WIN__2427 #ifndef RT_OS_WINDOWS 2428 2428 AutoLock alock (this); 2429 2429 mWatcherData.mProcesses.push_back (pid); … … 3350 3350 if (aHardDisk->storageType() == HardDiskStorageType_VirtualDiskImage) 3351 3351 #if !defined (VBOX_WITH_XPCOM) 3352 #if defined( __WIN__)3352 #if defined(RT_OS_WINDOWS) 3353 3353 /// @todo (dmik) stupid BSTR declaration lacks the BCSTR counterpart 3354 3354 const_cast <BSTR> (aFilePathFull) = aHardDisk->asVDI()->filePathFull(); … … 4373 4373 size_t cnt = 0; 4374 4374 4375 #if defined( __WIN__)4375 #if defined(RT_OS_WINDOWS) 4376 4376 4377 4377 HRESULT hrc = CoInitializeEx (NULL, … … 4453 4453 ::CoUninitialize(); 4454 4454 4455 #elif defined ( __OS2__)4455 #elif defined (RT_OS_OS2) 4456 4456 4457 4457 /// @todo (dmik) processes reaping! -
trunk/src/VBox/Main/glue/EventQueue.cpp
r2981 r3668 29 29 //////////////////////////////////////////////////////////////////////////////// 30 30 31 #if defined ( __WIN__)31 #if defined (RT_OS_WINDOWS) 32 32 33 33 #define CHECK_THREAD_RET(ret) \ … … 38 38 } while (0) 39 39 40 #else // !defined ( __WIN__)40 #else // !defined (RT_OS_WINDOWS) 41 41 42 42 #define CHECK_THREAD_RET(ret) \ … … 51 51 } while (0) 52 52 53 #endif // !defined ( __WIN__)53 #endif // !defined (RT_OS_WINDOWS) 54 54 55 55 /** … … 62 62 EventQueue::EventQueue() 63 63 { 64 #if defined ( __WIN__)64 #if defined (RT_OS_WINDOWS) 65 65 66 66 mThreadId = GetCurrentThreadId(); … … 112 112 EventQueue::~EventQueue() 113 113 { 114 #if defined ( __WIN__)114 #if defined (RT_OS_WINDOWS) 115 115 #else 116 116 // process all pending events before destruction … … 137 137 BOOL EventQueue::postEvent (Event *event) 138 138 { 139 #if defined ( __WIN__)139 #if defined (RT_OS_WINDOWS) 140 140 141 141 return PostThreadMessage (mThreadId, WM_USER, (WPARAM) event, NULL); … … 180 180 CHECK_THREAD_RET (FALSE); 181 181 182 #if defined ( __WIN__)182 #if defined (RT_OS_WINDOWS) 183 183 184 184 MSG msg; -
trunk/src/VBox/Main/glue/com.cpp
r3387 r3668 47 47 48 48 49 #ifdef __DARWIN__49 #ifdef RT_OS_DARWIN 50 50 #define VBOX_USER_HOME_SUFFIX "Library/VirtualBox" 51 51 #else -
trunk/src/VBox/Main/include/Collection.h
r2981 r3668 58 58 public VirtualBoxSupportErrorInfoImpl <IfaceVectorEnumerator <IEnum, IEnumItem, 59 59 EnumItem, ComponentClass>, IEnum>, 60 #ifdef __WIN__60 #ifdef RT_OS_WINDOWS 61 61 public CComObjectRootEx <CComSingleThreadModel>, 62 62 #else … … 182 182 public VirtualBoxSupportErrorInfoImpl <ReadonlyIfaceVector <IColl, ICollItem, 183 183 IEnum, CollItem, Enum, ComponentClass>, IColl>, 184 #ifdef __WIN__184 #ifdef RT_OS_WINDOWS 185 185 public CComObjectRootEx <CComSingleThreadModel>, 186 186 #else … … 476 476 COM_DECL_READONLY_ENUM_AND_COLLECTION_AS_END (prefix, iface) 477 477 478 #ifdef __WIN__478 #ifdef RT_OS_WINDOWS 479 479 480 480 #define COM_IMPL_READONLY_ENUM_AND_COLLECTION_EX(itemcls, iface, prefix) … … 482 482 #define COM_IMPL_READONLY_ENUM_AND_COLLECTION_AS(prefix, iface) 483 483 484 #else // ! __WIN__484 #else // !RT_OS_WINDOWS 485 485 486 486 /** … … 558 558 COM_IMPL_READONLY_ENUM_AND_COLLECTION_EX (0, iface, prefix) 559 559 560 #endif // ! __WIN__560 #endif // !RT_OS_WINDOWS 561 561 562 562 #endif // ____H_COLLECTION -
trunk/src/VBox/Main/include/HostImpl.h
r3566 r3668 27 27 #include "USBDeviceFilterImpl.h" 28 28 29 #ifdef __WIN__29 #ifdef RT_OS_WINDOWS 30 30 #include "win32/svchlp.h" 31 31 #endif … … 72 72 STDMETHOD(COMGETTER(USBDevices))(IHostUSBDeviceCollection **aUSBDevices); 73 73 STDMETHOD(COMGETTER(USBDeviceFilters))(IHostUSBDeviceFilterCollection ** aUSBDeviceFilters); 74 #ifdef __WIN__74 #ifdef RT_OS_WINDOWS 75 75 STDMETHOD(COMGETTER(NetworkInterfaces))(IHostNetworkInterfaceCollection **networkInterfaces); 76 76 #endif … … 85 85 86 86 // IHost methods 87 #ifdef __WIN__87 #ifdef RT_OS_WINDOWS 88 88 STDMETHOD(CreateHostNetworkInterface) (INPTR BSTR aName, 89 89 IHostNetworkInterface **aHostNetworkInterface, … … 119 119 USBProxyService *usbProxyService() { return mUSBProxyService; } 120 120 121 #ifdef __WIN__121 #ifdef RT_OS_WINDOWS 122 122 static int networkInterfaceHelperServer (SVCHlpClient *aClient, 123 123 SVCHlpMsg::Code aMsgCode); … … 129 129 private: 130 130 131 #ifdef __LINUX__131 #ifdef RT_OS_LINUX 132 132 # ifdef VBOX_USE_LIBHAL 133 133 bool getDVDInfoFromHal(std::list <ComObjPtr <HostDVDDrive> > &list); … … 153 153 ComObjPtr <HostUSBDevice> &aDevice); 154 154 155 #ifdef __WIN__155 #ifdef RT_OS_WINDOWS 156 156 static int createNetworkInterface (SVCHlpClient *aClient, 157 157 const Utf8Str &aName, -
trunk/src/VBox/Main/include/HostNetworkInterfaceImpl.h
r2981 r3668 23 23 #define ____H_HOSTNETWORKINTERFACEIMPL 24 24 25 #ifndef __WIN__25 #ifndef RT_OS_WINDOWS 26 26 #error This is Windows only stuff! 27 27 #endif -
trunk/src/VBox/Main/include/HostUSBDeviceImpl.h
r3566 r3668 177 177 178 178 friend class USBProxyService; 179 #ifdef __LINUX__179 #ifdef RT_OS_LINUX 180 180 friend class USBProxyServiceLinux; 181 181 #endif -
trunk/src/VBox/Main/include/MachineImpl.h
r3652 r3668 766 766 bool checkForDeath(); 767 767 768 #if defined ( __WIN__)768 #if defined (RT_OS_WINDOWS) 769 769 HANDLE ipcSem() { return mIPCSem; } 770 #elif defined ( __OS2__)770 #elif defined (RT_OS_OS2) 771 771 HMTX ipcSem() { return mIPCSem; } 772 772 #endif … … 832 832 833 833 /** interprocess semaphore handle (id) for this machine */ 834 #if defined( __WIN__)834 #if defined(RT_OS_WINDOWS) 835 835 HANDLE mIPCSem; 836 836 Bstr mIPCSemName; 837 #elif defined( __OS2__)837 #elif defined(RT_OS_OS2) 838 838 HMTX mIPCSem; 839 839 Bstr mIPCSemName; -
trunk/src/VBox/Main/include/NetworkAdapterImpl.h
r3348 r3668 42 42 , mAttachmentType (NetworkAttachmentType_NoNetworkAttachment) 43 43 , mCableConnected (TRUE), mTraceEnabled (FALSE) 44 #ifdef __WIN__44 #ifdef RT_OS_WINDOWS 45 45 , mHostInterface ("") // cannot be null 46 46 #endif -
trunk/src/VBox/Main/include/SessionImpl.h
r3652 r3668 26 26 #include "ConsoleImpl.h" 27 27 28 #ifdef __WIN__28 #ifdef RT_OS_WINDOWS 29 29 #include "win32/resource.h" 30 30 #endif … … 45 45 public VirtualBoxSupportErrorInfoImpl <Session, ISession>, 46 46 public VirtualBoxSupportTranslation <Session>, 47 #ifdef __WIN__47 #ifdef RT_OS_WINDOWS 48 48 public IDispatchImpl<ISession, &IID_ISession, &LIBID_VirtualBox, 49 49 kTypeLibraryMajorVersion, kTypeLibraryMinorVersion>, … … 128 128 129 129 /* interprocess semaphore handle (id) for the opened machine */ 130 #if defined( __WIN__)130 #if defined(RT_OS_WINDOWS) 131 131 HANDLE mIPCSem; 132 132 HANDLE mIPCThreadSem; 133 #elif defined( __OS2__)133 #elif defined(RT_OS_OS2) 134 134 RTTHREAD mIPCThread; 135 135 RTSEMEVENT mIPCThreadSem; -
trunk/src/VBox/Main/include/USBProxyService.h
r3662 r3668 243 243 #ifdef VBOX_WITH_USB 244 244 245 # ifdef __DARWIN__245 # ifdef RT_OS_DARWIN 246 246 # include <VBox/param.h> 247 247 # undef PAGE_SHIFT … … 285 285 bool volatile mFakeAsync; 286 286 }; 287 # endif /* __DARWIN__*/288 289 290 # ifdef __LINUX__287 # endif /* RT_OS_DARWIN */ 288 289 290 # ifdef RT_OS_LINUX 291 291 # include <stdio.h> 292 292 … … 326 326 unsigned mUdevPolls; 327 327 }; 328 # endif /* __LINUX__*/329 330 331 # ifdef __WIN__328 # endif /* RT_OS_LINUX */ 329 330 331 # ifdef RT_OS_WINDOWS 332 332 /** 333 333 * The Win32 hosted USB Proxy Service. … … 356 356 HANDLE hEventInterrupt; 357 357 }; 358 # endif /* __WIN__*/358 # endif /* RT_OS_WINDOWS */ 359 359 360 360 #endif /* VBOX_WITH_USB */ -
trunk/src/VBox/Main/include/VirtualBoxBase.h
r3033 r3668 43 43 #include <map> 44 44 45 #if defined ( __WIN__)45 #if defined (RT_OS_WINDOWS) 46 46 47 47 #include <atlcom.h> … … 119 119 }; 120 120 121 #endif // defined ( __WIN__)121 #endif // defined (RT_OS_WINDOWS) 122 122 123 123 // macros … … 381 381 382 382 class ATL_NO_VTABLE VirtualBoxBaseNEXT_base 383 #ifdef __WIN__383 #ifdef RT_OS_WINDOWS 384 384 : public CComObjectRootEx <CComMultiThreadModel> 385 385 #else … … 877 877 /// @todo (dmik) remove after we switch to VirtualBoxBaseNEXT completely 878 878 class ATL_NO_VTABLE VirtualBoxBase : public VirtualBoxBaseNEXT_base 879 //#ifdef __WIN__879 //#ifdef RT_OS_WINDOWS 880 880 // : public CComObjectRootEx<CComMultiThreadModel> 881 881 //#else … … 1108 1108 class ATL_NO_VTABLE VirtualBoxSupportErrorInfoImpl 1109 1109 : protected VirtualBoxSupportErrorInfoImplBase 1110 #if defined ( __WIN__)1110 #if defined (RT_OS_WINDOWS) 1111 1111 , public ISupportErrorInfo 1112 1112 #else … … 1115 1115 public: 1116 1116 1117 #if defined ( __WIN__)1117 #if defined (RT_OS_WINDOWS) 1118 1118 STDMETHOD(InterfaceSupportsErrorInfo) (REFIID riid) 1119 1119 { … … 1146 1146 return bSupports ? S_OK : S_FALSE; 1147 1147 } 1148 #endif // defined ( __WIN__)1148 #endif // defined (RT_OS_WINDOWS) 1149 1149 1150 1150 protected: -
trunk/src/VBox/Main/include/VirtualBoxErrorInfoImpl.h
r2981 r3668 28 28 29 29 class ATL_NO_VTABLE VirtualBoxErrorInfo 30 #if defined ( __WIN__)30 #if defined (RT_OS_WINDOWS) 31 31 : public CComObjectRootEx <CComMultiThreadModel> 32 32 #else … … 48 48 NS_DECL_ISUPPORTS 49 49 50 #if defined ( __WIN__)50 #if defined (RT_OS_WINDOWS) 51 51 52 52 HRESULT init (IErrorInfo *aInfo); … … 58 58 STDMETHOD(GetHelpContext) (DWORD *pdwHelpContext); 59 59 60 #else // !defined ( __WIN__)60 #else // !defined (RT_OS_WINDOWS) 61 61 62 62 HRESULT init (nsIException *aInfo); -
trunk/src/VBox/Main/include/VirtualBoxImpl.h
r3480 r3668 34 34 #include <map> 35 35 36 #ifdef __WIN__36 #ifdef RT_OS_WINDOWS 37 37 #include "win32/resource.h" 38 38 #endif … … 56 56 class SystemProperties; 57 57 58 #ifdef __WIN__58 #ifdef RT_OS_WINDOWS 59 59 class SVCHlpClient; 60 60 #endif … … 67 67 public VirtualBoxSupportErrorInfoImpl <VirtualBox, IVirtualBox>, 68 68 public VirtualBoxSupportTranslation <VirtualBox>, 69 #ifdef __WIN__69 #ifdef RT_OS_WINDOWS 70 70 public IDispatchImpl<IVirtualBox, &IID_IVirtualBox, &LIBID_VirtualBox, 71 71 kTypeLibraryMajorVersion, kTypeLibraryMinorVersion>, … … 186 186 HRESULT removeProgress (INPTR GUIDPARAM aId); 187 187 188 #ifdef __WIN__188 #ifdef RT_OS_WINDOWS 189 189 typedef DECLCALLBACKPTR (HRESULT, SVCHelperClientFunc) 190 190 (SVCHlpClient *aClient, Progress *aProgress, void *aUser, int *aVrc); … … 354 354 { 355 355 ClientWatcherData() 356 #if defined( __WIN__)356 #if defined(RT_OS_WINDOWS) 357 357 : mUpdateReq (NULL) 358 #elif defined( __OS2__)358 #elif defined(RT_OS_OS2) 359 359 : mUpdateReq (NIL_RTSEMEVENT) 360 360 #elif defined(VBOX_WITH_SYS_V_IPC_SESSION_WATCHER) … … 366 366 367 367 // const objects not requiring locking 368 #if defined( __WIN__)368 #if defined(RT_OS_WINDOWS) 369 369 const HANDLE mUpdateReq; 370 #elif defined( __OS2__)370 #elif defined(RT_OS_OS2) 371 371 const RTSEMEVENT mUpdateReq; 372 372 #elif defined(VBOX_WITH_SYS_V_IPC_SESSION_WATCHER) … … 393 393 static DECLCALLBACK(int) AsyncEventHandler (RTTHREAD thread, void *pvUser); 394 394 395 #ifdef __WIN__395 #ifdef RT_OS_WINDOWS 396 396 static DECLCALLBACK(int) SVCHelperClientThread (RTTHREAD aThread, void *aUser); 397 397 #endif -
trunk/src/VBox/Main/include/VirtualBoxXMLUtil.h
r3191 r3668 36 36 37 37 /** VirtualBox XML settings version string */ 38 #if defined ( __WIN__)38 #if defined (RT_OS_WINDOWS) 39 39 # define VBOX_XML_PLATFORM "windows" 40 #elif defined ( __LINUX__)40 #elif defined (RT_OS_LINUX) 41 41 # define VBOX_XML_PLATFORM "linux" 42 #elif defined ( __DARWIN__)42 #elif defined (RT_OS_DARWIN) 43 43 # define VBOX_XML_PLATFORM "macosx" 44 #elif defined ( __OS2__)44 #elif defined (RT_OS_OS2) 45 45 # define VBOX_XML_PLATFORM "os2" 46 46 #else -
trunk/src/VBox/Main/linux/server.cpp
r3652 r3668 56 56 57 57 // for the backtrace signal handler 58 #if defined(DEBUG) && defined( __LINUX__)58 #if defined(DEBUG) && defined(RT_OS_LINUX) 59 59 # define USE_BACKTRACE 60 60 #endif … … 66 66 # endif 67 67 # include <ucontext.h> 68 # ifdef __AMD64__68 # ifdef RT_ARCH_AMD64 69 69 # define REG_PC REG_RIP 70 70 # else … … 992 992 static RTFILE pidFile = NIL_RTFILE; 993 993 994 #ifdef __OS2__994 #ifdef RT_OS_OS2 995 995 996 996 /* nothing to do here, the process is supposed to be already … … 998 998 NOREF(fDaemonize); 999 999 1000 #else // ifdef __OS2__1000 #else // ifdef RT_OS_OS2 1001 1001 1002 1002 static int daemon_pipe_fds[2]; … … 1062 1062 } 1063 1063 1064 #endif // ifdef __OS2__1064 #endif // ifdef RT_OS_OS2 1065 1065 1066 1066 #if defined(USE_BACKTRACE) … … 1178 1178 { 1179 1179 printf ("\nStarting event loop....\n[send TERM signal to quit]\n"); 1180 #ifndef __OS2__1180 #ifndef RT_OS_OS2 1181 1181 /* now we're ready, signal the parent process */ 1182 1182 write(daemon_pipe_fds[1], "READY", strlen("READY")); … … 1239 1239 if (fDaemonize) 1240 1240 { 1241 #ifndef __OS2__1241 #ifndef RT_OS_OS2 1242 1242 /* close writing end of the pipe as well */ 1243 1243 close(daemon_pipe_fds[1]); -
trunk/src/VBox/Main/linux/server_module.cpp
r3388 r3668 20 20 */ 21 21 22 #ifdef __OS2__22 #ifdef RT_OS_OS2 23 23 # include <prproces.h> 24 24 #endif … … 59 59 60 60 /// @todo move this to RT headers (and use them in MachineImpl.cpp as well) 61 #if defined( __WIN__) || defined(__OS2__)61 #if defined(RT_OS_WINDOWS) || defined(RT_OS_OS2) 62 62 #define HOSTSUFF_EXE ".exe" 63 #else /* ! __WIN__*/63 #else /* !RT_OS_WINDOWS */ 64 64 #define HOSTSUFF_EXE "" 65 #endif /* ! __WIN__*/65 #endif /* !RT_OS_WINDOWS */ 66 66 67 67 … … 169 169 startedOnce = true; 170 170 171 #ifdef __OS2__171 #ifdef RT_OS_OS2 172 172 char *const args[] = { VBoxSVCPath, "--automate", 0 }; 173 173 /* use NSPR because we want the process to be detached right -
trunk/src/VBox/Main/testcase/tstAPI.cpp
r3480 r3668 447 447 do 448 448 { 449 #if defined __LINUX__449 #if defined RT_OS_LINUX 450 450 Bstr src = L"/mnt/hugaida/common/develop/innotek/images/freedos-linux.vdi"; 451 451 #else … … 484 484 static const wchar_t *Names[] = 485 485 { 486 #ifndef __LINUX__486 #ifndef RT_OS_LINUX 487 487 L"E:/Develop/innotek/images/thinker/freedos.vdi", 488 488 L"E:/Develop/innotek/images/thinker/fReeDoS.vDI", … … 550 550 { 551 551 ComPtr <IMachine> machine; 552 #if defined ( __LINUX__)552 #if defined (RT_OS_LINUX) 553 553 Bstr baseDir = L"/tmp/vbox"; 554 554 #else -
trunk/src/VBox/Main/xml/cfgldr.cpp
r2981 r3668 107 107 #define OLECHAR wchar_t 108 108 #define BSTR void* 109 #if defined( __WIN__)109 #if defined(RT_OS_WINDOWS) 110 110 extern "C" BSTR __stdcall SysAllocString(const OLECHAR* sz); 111 111 #else -
trunk/src/VBox/Main/xml/cfgldrhlp.cpp
r2981 r3668 20 20 */ 21 21 22 #ifdef __WIN__22 #ifdef RT_OS_WINDOWS 23 23 # if _MSC_VER < 1400 24 24 /// @todo Without this I cannot get the stuff to … … 33 33 } 34 34 # endif 35 #endif /* __WIN__*/35 #endif /* RT_OS_WINDOWS */ 36 36 37 37 #include "cfgldrhlp.h"
Note:
See TracChangeset
for help on using the changeset viewer.