mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 10:52:44 +00:00 
			
		
		
		
	 6a1c85aa61
			
		
	
	
		6a1c85aa61
		
	
	
	
	
		
			
			Previously, PartitionTable was constructed using a Kernel::StorageDevice making it only usable in the kernel. This commit adds a new constructor that takes a Core::File instead, making it usable in userland as well. This also adds the m_block_size field which stores the block size of the underlying device obtained by calling StorageDevice::block_size() in the kernel or by using the STORAGE_DEVICE_GET_BLOCK_SIZE ioctl in userland. This avoids the need for an #ifdef every time block size is needed.
		
			
				
	
	
		
			10 lines
		
	
	
	
		
			228 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
			
		
		
	
	
			10 lines
		
	
	
	
		
			228 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
| set(SOURCES
 | |
|     DiskPartitionMetadata.cpp
 | |
|     EBRPartitionTable.cpp
 | |
|     GUIDPartitionTable.cpp
 | |
|     MBRPartitionTable.cpp
 | |
|     PartitionTable.cpp
 | |
| )
 | |
| 
 | |
| serenity_lib(LibPartition partition)
 | |
| target_link_libraries(LibPartition LibCore)
 |