summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
Diffstat (limited to 'fs')
-rw-r--r--fs/Makefile4
-rw-r--r--fs/cramfs/Makefile16
-rw-r--r--fs/ext2/Makefile18
-rw-r--r--fs/fat/Makefile15
-rw-r--r--fs/fdos/Makefile17
-rw-r--r--fs/jffs2/Makefile16
-rw-r--r--fs/reiserfs/Makefile18
7 files changed, 60 insertions, 44 deletions
diff --git a/fs/Makefile b/fs/Makefile
index 79cbdeaa7a..273d90e011 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -1,5 +1,5 @@
#
-# (C) Copyright 2000, 2001
+# (C) Copyright 2000-2006
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
#
# See file CREDITS for list of people who contributed to this
@@ -24,6 +24,6 @@
SUBDIRS := jffs2 cramfs fdos fat reiserfs ext2
-.depend all:
+$(obj).depend all:
@for dir in $(SUBDIRS) ; do \
$(MAKE) -C $$dir $@ ; done
diff --git a/fs/cramfs/Makefile b/fs/cramfs/Makefile
index 54a475ef85..1a6f4b7d00 100644
--- a/fs/cramfs/Makefile
+++ b/fs/cramfs/Makefile
@@ -1,5 +1,5 @@
#
-# (C) Copyright 2000, 2001
+# (C) Copyright 2000-2006
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
#
# See file CREDITS for list of people who contributed to this
@@ -23,25 +23,27 @@
include $(TOPDIR)/config.mk
-LIB = libcramfs.a
+LIB = $(obj)libcramfs.a
AOBJS =
COBJS = cramfs.o uncompress.o
-OBJS = $(AOBJS) $(COBJS)
+
+SRCS := $(AOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS := $(addprefix $(obj),$(AOBJS) $(COBJS))
#CPPFLAGS +=
all: $(LIB) $(AOBJS)
-$(LIB): .depend $(OBJS)
+$(LIB): $(obj).depend $(OBJS)
$(AR) crv $@ $(OBJS)
#########################################################################
-.depend: Makefile $(AOBJS:.o=.S) $(COBJS:.o=.c)
- $(CC) -M $(CFLAGS) $(AOBJS:.o=.S) $(COBJS:.o=.c) > $@
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
-sinclude .depend
+sinclude $(obj).depend
#########################################################################
diff --git a/fs/ext2/Makefile b/fs/ext2/Makefile
index 3b193684f5..2e420d536b 100644
--- a/fs/ext2/Makefile
+++ b/fs/ext2/Makefile
@@ -1,4 +1,7 @@
#
+# (C) Copyright 2006
+# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
+#
# (C) Copyright 2003
# Pavel Bartusek, Sysgo Real-Time Solutions AG, pba@sysgo.de
#
@@ -24,25 +27,26 @@
include $(TOPDIR)/config.mk
-LIB = libext2fs.a
+LIB = $(obj)libext2fs.a
AOBJS =
COBJS = ext2fs.o dev.o
-OBJS = $(AOBJS) $(COBJS)
+
+SRCS := $(AOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS := $(addprefix $(obj),$(AOBJS) $(COBJS))
#CPPFLAGS +=
all: $(LIB) $(AOBJS)
-$(LIB): .depend $(OBJS)
+$(LIB): $(obj).depend $(OBJS)
$(AR) crv $@ $(OBJS)
-
#########################################################################
-.depend: Makefile $(AOBJS:.o=.S) $(COBJS:.o=.c)
- $(CC) -M $(CFLAGS) $(AOBJS:.o=.S) $(COBJS:.o=.c) > $@
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
-sinclude .depend
+sinclude $(obj).depend
#########################################################################
diff --git a/fs/fat/Makefile b/fs/fat/Makefile
index e4627577b7..2fa428c4dc 100644
--- a/fs/fat/Makefile
+++ b/fs/fat/Makefile
@@ -19,28 +19,27 @@
# MA 02111-1307 USA
#
-TOPDIR=../../
-
include $(TOPDIR)/config.mk
-LIB = libfat.a
+LIB = $(obj)libfat.a
AOBJS =
COBJS = fat.o file.o
-OBJS = $(AOBJS) $(COBJS)
+SRCS := $(AOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS := $(addprefix $(obj),$(AOBJS) $(COBJS))
all: $(LIB) $(AOBJS)
-$(LIB): .depend $(OBJS)
+$(LIB): $(obj).depend $(OBJS)
$(AR) crv $@ $(OBJS)
#########################################################################
-.depend: Makefile $(AOBJS:.o=.S) $(COBJS:.o=.c)
- $(CC) -M $(CFLAGS) $(AOBJS:.o=.S) $(COBJS:.o=.c) > $@
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
-sinclude .depend
+sinclude $(obj).depend
#########################################################################
diff --git a/fs/fdos/Makefile b/fs/fdos/Makefile
index c25e744b92..e55ac8abbd 100644
--- a/fs/fdos/Makefile
+++ b/fs/fdos/Makefile
@@ -1,4 +1,7 @@
#
+# (C) Copyright 2006
+# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
+#
# (C) Copyright 2002
# Stäubli Faverges - <www.staubli.com>
# Pierre AUBERT p.aubert@staubli.com
@@ -25,25 +28,27 @@
include $(TOPDIR)/config.mk
-LIB = libfdos.a
+LIB = $(obj)libfdos.a
AOBJS =
COBJS = fat.o vfat.o dev.o fdos.o fs.o subdir.o
-OBJS = $(AOBJS) $(COBJS)
+
+SRCS := $(AOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS := $(addprefix $(obj),$(AOBJS) $(COBJS))
#CPPFLAGS +=
all: $(LIB) $(AOBJS)
-$(LIB): .depend $(OBJS)
+$(LIB): $(obj).depend $(OBJS)
$(AR) crv $@ $(OBJS)
#########################################################################
-.depend: Makefile $(AOBJS:.o=.S) $(COBJS:.o=.c)
- $(CC) -M $(CFLAGS) $(AOBJS:.o=.S) $(COBJS:.o=.c) > $@
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
-sinclude .depend
+sinclude $(obj).depend
#########################################################################
diff --git a/fs/jffs2/Makefile b/fs/jffs2/Makefile
index f28b17a414..82436bbfec 100644
--- a/fs/jffs2/Makefile
+++ b/fs/jffs2/Makefile
@@ -1,5 +1,5 @@
#
-# (C) Copyright 2000, 2001
+# (C) Copyright 2000-2006
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
#
# See file CREDITS for list of people who contributed to this
@@ -23,26 +23,28 @@
include $(TOPDIR)/config.mk
-LIB = libjffs2.a
+LIB = $(obj)libjffs2.a
AOBJS =
COBJS = jffs2_1pass.o compr_rtime.o compr_rubin.o compr_zlib.o mini_inflate.o
COBJS += compr_lzo.o compr_lzari.o
-OBJS = $(AOBJS) $(COBJS)
+
+SRCS := $(AOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS := $(addprefix $(obj),$(AOBJS) $(COBJS))
#CPPFLAGS +=
all: $(LIB) $(AOBJS)
-$(LIB): .depend $(OBJS)
+$(LIB): $(obj).depend $(OBJS)
$(AR) crv $@ $(OBJS)
#########################################################################
-.depend: Makefile $(AOBJS:.o=.S) $(COBJS:.o=.c)
- $(CC) -M $(CFLAGS) $(AOBJS:.o=.S) $(COBJS:.o=.c) > $@
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
-sinclude .depend
+sinclude $(obj).depend
#########################################################################
diff --git a/fs/reiserfs/Makefile b/fs/reiserfs/Makefile
index 98a9a8d30e..45028cb15e 100644
--- a/fs/reiserfs/Makefile
+++ b/fs/reiserfs/Makefile
@@ -1,4 +1,7 @@
#
+# (C) Copyright 2006
+# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
+#
# (C) Copyright 2003
# Pavel Bartusek, Sysgo Real-Time Solutions AG, pba@sysgo.de
#
@@ -24,25 +27,26 @@
include $(TOPDIR)/config.mk
-LIB = libreiserfs.a
+LIB = $(obj)libreiserfs.a
AOBJS =
COBJS = reiserfs.o dev.o mode_string.o
-OBJS = $(AOBJS) $(COBJS)
+
+SRCS := $(AOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS := $(addprefix $(obj),$(AOBJS) $(COBJS))
#CPPFLAGS +=
all: $(LIB) $(AOBJS)
-$(LIB): .depend $(OBJS)
+$(LIB): $(obj).depend $(OBJS)
$(AR) crv $@ $(OBJS)
-
#########################################################################
-.depend: Makefile $(AOBJS:.o=.S) $(COBJS:.o=.c)
- $(CC) -M $(CFLAGS) $(AOBJS:.o=.S) $(COBJS:.o=.c) > $@
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
-sinclude .depend
+sinclude $(obj).depend
#########################################################################