SubDir HAIKU_TOP src add-ons kernel file_systems bfs ;

# R5 support has been removed!
#
# Have a look in src/tests/add-ons/kernel/file_systems/bfs/r5/
# for an R5 compatible version.
# In order to make the current BFS version R5 compatible again,
# we would need to port over the Haiku cache API to R5.

# set some additional defines
{
	local defines =
		BFS_DEBUGGER_COMMANDS
		#BFS_BIG_ENDIAN_ONLY
		;

	if $(DEBUG) = 0 {
		# the gcc on BeOS doesn't compile BFS correctly with -O2 or more
		OPTIM = -O1 ;
	}

	defines = [ FDefines $(defines) ] ;
	SubDirCcFlags $(defines) ;
	SubDirC++Flags $(defines) ;
}

UsePrivateKernelHeaders ;
UsePrivateHeaders [ FDirName kernel disk_device_manager ] ;
UsePrivateHeaders shared storage ;

KernelAddon bfs :
	bfs_disk_system.cpp
	BlockAllocator.cpp
	BPlusTree.cpp
	kernel_cpp.cpp
	Attribute.cpp
	Debug.cpp
	Index.cpp
	Inode.cpp
	Journal.cpp
	Query.cpp
	Volume.cpp

	kernel_interface.cpp
	;

SEARCH on [ FGristFiles
		kernel_cpp.cpp
	] = [ FDirName $(HAIKU_TOP) src system kernel util ] ;

