diff --git a/Makefile b/Makefile
index 59c7cfd035c8ea19977c66f2a2f9247c3ceb0c48..f4bde335d8100e756dc22337e08796943b34af63 100644
--- a/Makefile
+++ b/Makefile
@@ -248,17 +248,7 @@ endif
 LIBS-$(CONFIG_OF_EMBED) += dts/libdts.o
 LIBS-y += arch/$(ARCH)/lib/lib$(ARCH).o
 LIBS-y += fs/libfs.o \
-	fs/cbfs/libcbfs.o \
-	fs/cramfs/libcramfs.o \
-	fs/ext4/libext4fs.o \
-	fs/fat/libfat.o \
-	fs/fdos/libfdos.o \
-	fs/jffs2/libjffs2.o \
-	fs/reiserfs/libreiserfs.o \
-	fs/sandbox/libsandboxfs.o \
-	fs/ubifs/libubifs.o \
-	fs/yaffs2/libyaffs2.o \
-	fs/zfs/libzfs.o
+	fs/fat/libfat.o
 LIBS-y += net/libnet.o
 LIBS-y += disk/libdisk.o
 LIBS-y += drivers/libdrivers.o
diff --git a/fs/Makefile b/fs/Makefile
index ea2eb0967bea4b6ab13ff97b5824dc0ff3735e95..bdcd74631d603def66d49b079c4200519236846a 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -7,3 +7,14 @@
 #
 
 obj-y				+= fs.o
+
+obj-y += cbfs/
+obj-y += cramfs/
+obj-y += ext4/
+obj-y += fdos/
+obj-y += jffs2/
+obj-y += reiserfs/
+obj-y += sandbox/
+obj-y += ubifs/
+obj-y += yaffs2/
+obj-y += zfs/