wok-6.x diff parted/stuff/device_mapper.u @ rev 23856
codeblocks: use wxWidgets and gcc49
author | Richard Dunbar <mojo@slitaz.org> |
---|---|
date | Tue Jun 16 23:39:15 2020 -0400 (2020-06-16) |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/parted/stuff/device_mapper.u Tue Jun 16 23:39:15 2020 -0400 1.3 @@ -0,0 +1,44 @@ 1.4 +--- parted-3.2/libparted/arch/linux.c.device-mapper 2014-06-15 20:15:54.000000000 +0100 1.5 ++++ parted-3.2/libparted/arch/linux.c 2014-07-29 22:27:54.487430030 +0100 1.6 +@@ -2307,6 +2307,7 @@ zasprintf (const char *format, ...) 1.7 + static char * 1.8 + dm_canonical_path (PedDevice const *dev) 1.9 + { 1.10 ++#ifdef ENABLE_DEVICE_MAPPER 1.11 + LinuxSpecific const *arch_specific = LINUX_SPECIFIC (dev); 1.12 + 1.13 + /* Get map name from devicemapper */ 1.14 +@@ -2324,6 +2325,7 @@ dm_canonical_path (PedDevice const *dev) 1.15 + dm_task_destroy (task); 1.16 + return dev_name; 1.17 + err: 1.18 ++#endif 1.19 + return NULL; 1.20 + } 1.21 + 1.22 +@@ -2944,13 +2946,14 @@ _disk_sync_part_table (PedDisk* disk) 1.23 + unsigned long long *start, 1.24 + unsigned long long *length); 1.25 + 1.26 +- 1.27 ++#ifdef ENABLE_DEVICE_MAPPER 1.28 + if (disk->dev->type == PED_DEVICE_DM) { 1.29 + add_partition = _dm_add_partition; 1.30 + remove_partition = _dm_remove_partition; 1.31 + resize_partition = _dm_resize_partition; 1.32 + get_partition_start_and_length = _dm_get_partition_start_and_length; 1.33 + } else { 1.34 ++#endif 1.35 + add_partition = _blkpg_add_partition; 1.36 + remove_partition = _blkpg_remove_partition; 1.37 + #ifdef BLKPG_RESIZE_PARTITION 1.38 +@@ -2959,7 +2962,9 @@ _disk_sync_part_table (PedDisk* disk) 1.39 + resize_partition = NULL; 1.40 + #endif 1.41 + get_partition_start_and_length = _kernel_get_partition_start_and_length; 1.42 ++#ifdef ENABLE_DEVICE_MAPPER 1.43 + } 1.44 ++#endif 1.45 + 1.46 + /* lpn = largest partition number. 1.47 + * for remove pass, use greater of device or label limit */