ifeq ($(VFS_PROJECT),)
VFS_PROJECT=True

ifeq ($(BASE_DIR),)
   include ../Makefile.common
   BASE_DIR=$(shell pwd)
   VFS_ROOT=True
endif

VFS_BASE_DIR := $(BASE_DIR)

BASE_DIR=$(VFS_BASE_DIR)/../kernel
include $(BASE_DIR)/Makefile.kernel

VFS_SRC_DIRS = $(VFS_BASE_DIR)/src
SRC_DIRS += $(VFS_SRC_DIRS)
C_SRCS = \
  $(foreach name,$(VFS_SRC_DIRS),$(notdir $(wildcard $(name)/*$(C_EXT))))
VFS_SRCS := \
  $(foreach name,$(VFS_SRC_DIRS),$(notdir $(wildcard $(name)/*$(C_EXT))))
VFS_OBJ_DIR = $(VFS_BASE_DIR)/obj
OBJ_DIR = $(VFS_OBJ_DIR)

CFLAGS = -g -O2

PROJECT_FILE = vfs
ADA_SOURCES=vfs_module.adb

ifneq ($(strip $(VFS_SRCS)),)
   LIBS := $(VFS_OBJ_DIR)/libvfs$(AR_EXT) $(LIBS)
endif

ifeq ($(VFS_ROOT),True)
   include ../builder/src/Makefile.generic
else
   DEPS_PROJECTS += $(VFS_BASE_DIR)/vfs
endif

endif
