1SubDir HAIKU_TOP src tests add-ons kernel file_systems bfs r5 ; 2 3SetSubDirSupportedPlatformsBeOSCompatible ; 4 5# save original optimization level 6oldOPTIM = $(OPTIM) ; 7 8# set some additional defines 9{ 10 local defines = 11 KEEP_WRONG_DIRENT_RECLEN 12 UNSAFE_GET_VNODE 13 #BFS_BIG_ENDIAN_ONLY 14 ; 15 16 # By default, the R5 API version is used unless you define this 17 if $(COMPILE_FOR_ZETA) { 18 defines += COMPILE_FOR_ZETA ; 19 } 20 21 # Enable OpenBFS to be compiled as a full BFS replacement. Will 22 # report itself as "bfs" instead of "obfs" (only R5 version) 23 if $(BFS_REPLACEMENT) { 24 defines += BFS_REPLACEMENT ; 25 bfsAddOnName = bfs ; 26 } else { 27 bfsAddOnName = obfs ; 28 } 29 30 if $(DEBUG) = 0 { 31 # the gcc on BeOS doesn't compile BFS correctly with -O2 or more 32 OPTIM = -O1 ; 33 } 34 35 defines = [ FDefines $(defines) ] ; 36 SubDirCcFlags $(defines) ; 37 SubDirC++Flags $(defines) -fno-rtti ; 38} 39 40UsePrivateHeaders [ FDirName kernel ] ; # For kernel_cpp.cpp 41 42KernelStaticLibrary libbfs : 43 BlockAllocator.cpp 44 BPlusTree.cpp 45 kernel_cpp.cpp 46 Debug.cpp 47 Index.cpp 48 Inode.cpp 49 Journal.cpp 50 Query.cpp 51 Utility.cpp 52 Volume.cpp 53 BufferPool.cpp 54 ; 55 56KernelAddon $(bfsAddOnName)_r5 : 57 kernel_interface_r5.cpp 58 : libbfs.a 59 ; 60 61SEARCH on [ FGristFiles 62 kernel_cpp.cpp 63 ] = [ FDirName $(HAIKU_TOP) src system kernel util ] ; 64 65#----------------------------------------------------- 66 67rule InstallBFS 68{ 69 Depends $(<) : $(>) ; 70} 71 72actions ignore InstallBFS 73{ 74 cp $(>) /boot/home/config/add-ons/kernel/file_systems/ 75} 76 77InstallBFS install : obfs ; 78 79# restore original optimization level 80OPTIM = $(oldOPTIM) ; 81