summaryrefslogtreecommitdiff
path: root/emulators
diff options
context:
space:
mode:
authorBernhard Froehlich <decke@FreeBSD.org>2011-03-17 13:29:04 +0000
committerBernhard Froehlich <decke@FreeBSD.org>2011-03-17 13:29:04 +0000
commitb454a3ee69b22a037d3f13de60b7a057580b42b9 (patch)
tree9af296c3ed4a2cfad5754aef13f3d8d3f3e9a26f /emulators
parentmcwm is a minimalistic floating window manager for the X Window System. (diff)
- Enable createrawvmdk -relative under FreeBSD
- Bump PORTREVISION PR: ports/155236 Submitted by: Dmitry Pryanishnikov <lynx.ripe@gmail.com>
Notes
Notes: svn path=/head/; revision=271112
Diffstat (limited to 'emulators')
-rw-r--r--emulators/virtualbox-ose-legacy/Makefile1
-rw-r--r--emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp48
-rw-r--r--emulators/virtualbox-ose/Makefile1
-rw-r--r--emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp48
4 files changed, 98 insertions, 0 deletions
diff --git a/emulators/virtualbox-ose-legacy/Makefile b/emulators/virtualbox-ose-legacy/Makefile
index 688804e6dd7b..a8e96b066394 100644
--- a/emulators/virtualbox-ose-legacy/Makefile
+++ b/emulators/virtualbox-ose-legacy/Makefile
@@ -7,6 +7,7 @@
PORTNAME= virtualbox-ose
DISTVERSION= 3.2.12
+PORTREVISION= 1
CATEGORIES= emulators
MASTER_SITES= http://tmp.chruetertee.ch/ \
http://freebsd.unixfreunde.de/sources/ \
diff --git a/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
new file mode 100644
index 000000000000..fdffb0aab896
--- /dev/null
+++ b/emulators/virtualbox-ose-legacy/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
@@ -0,0 +1,48 @@
+--- src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp.orig 2010-12-01 18:09:24.000000000 +0100
++++ src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp 2011-03-16 10:58:37.000000000 +0100
+@@ -178,8 +178,9 @@
+ " (the partitioning information in the MBR file is ignored).\n"
+ " The diskname is on Linux e.g. /dev/sda, and on Windows e.g.\n"
+ " \\\\.\\PhysicalDrive0).\n"
+- " On Linux host the parameter -relative causes a VMDK file to be created\n"
+- " which refers to individual partitions instead to the entire disk.\n"
++ " On Linux or FreeBSD host the parameter -relative causes a VMDK file to\n"
++ " be created which refers to individual partitions instead to the entire\n"
++ " disk.\n"
+ " Optionally the created image can be immediately registered.\n"
+ " The necessary partition numbers can be queried with\n"
+ " VBoxManage internalcommands listpartitions\n"
+@@ -926,12 +927,12 @@
+ {
+ fRegister = true;
+ }
+-#ifdef RT_OS_LINUX
++#if defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
+ else if (strcmp(argv[i], "-relative") == 0)
+ {
+ fRelative = true;
+ }
+-#endif /* RT_OS_LINUX */
++#endif /* RT_OS_LINUX || RT_OS_FREEBSD */
+ else
+ {
+ return errorSyntax(USAGE_CREATERAWVMDK, "Invalid parameter '%s'", Utf8Str(argv[i]).raw());
+@@ -1280,10 +1281,16 @@
+ {
+ if (fRelative)
+ {
+-#ifdef RT_OS_LINUX
++#if defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
+ /* Refer to the correct partition and use offset 0. */
+ char *psz;
+- vrc = RTStrAPrintf(&psz, "%s%u", rawdisk.raw(),
++ vrc = RTStrAPrintf(&psz,
++#if defined(RT_OS_LINUX)
++ "%s%u",
++#elif defined(RT_OS_FREEBSD)
++ "%ss%u",
++#endif
++ rawdisk.raw(),
+ partitions.aPartitions[i].uIndex);
+ if (RT_FAILURE(vrc))
+ {
diff --git a/emulators/virtualbox-ose/Makefile b/emulators/virtualbox-ose/Makefile
index 688804e6dd7b..a8e96b066394 100644
--- a/emulators/virtualbox-ose/Makefile
+++ b/emulators/virtualbox-ose/Makefile
@@ -7,6 +7,7 @@
PORTNAME= virtualbox-ose
DISTVERSION= 3.2.12
+PORTREVISION= 1
CATEGORIES= emulators
MASTER_SITES= http://tmp.chruetertee.ch/ \
http://freebsd.unixfreunde.de/sources/ \
diff --git a/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp b/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
new file mode 100644
index 000000000000..fdffb0aab896
--- /dev/null
+++ b/emulators/virtualbox-ose/files/patch-src-VBox-Frontends-VBoxManage-VBoxInternalManage.cpp
@@ -0,0 +1,48 @@
+--- src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp.orig 2010-12-01 18:09:24.000000000 +0100
++++ src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp 2011-03-16 10:58:37.000000000 +0100
+@@ -178,8 +178,9 @@
+ " (the partitioning information in the MBR file is ignored).\n"
+ " The diskname is on Linux e.g. /dev/sda, and on Windows e.g.\n"
+ " \\\\.\\PhysicalDrive0).\n"
+- " On Linux host the parameter -relative causes a VMDK file to be created\n"
+- " which refers to individual partitions instead to the entire disk.\n"
++ " On Linux or FreeBSD host the parameter -relative causes a VMDK file to\n"
++ " be created which refers to individual partitions instead to the entire\n"
++ " disk.\n"
+ " Optionally the created image can be immediately registered.\n"
+ " The necessary partition numbers can be queried with\n"
+ " VBoxManage internalcommands listpartitions\n"
+@@ -926,12 +927,12 @@
+ {
+ fRegister = true;
+ }
+-#ifdef RT_OS_LINUX
++#if defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
+ else if (strcmp(argv[i], "-relative") == 0)
+ {
+ fRelative = true;
+ }
+-#endif /* RT_OS_LINUX */
++#endif /* RT_OS_LINUX || RT_OS_FREEBSD */
+ else
+ {
+ return errorSyntax(USAGE_CREATERAWVMDK, "Invalid parameter '%s'", Utf8Str(argv[i]).raw());
+@@ -1280,10 +1281,16 @@
+ {
+ if (fRelative)
+ {
+-#ifdef RT_OS_LINUX
++#if defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
+ /* Refer to the correct partition and use offset 0. */
+ char *psz;
+- vrc = RTStrAPrintf(&psz, "%s%u", rawdisk.raw(),
++ vrc = RTStrAPrintf(&psz,
++#if defined(RT_OS_LINUX)
++ "%s%u",
++#elif defined(RT_OS_FREEBSD)
++ "%ss%u",
++#endif
++ rawdisk.raw(),
+ partitions.aPartitions[i].uIndex);
+ if (RT_FAILURE(vrc))
+ {