]> git.sur5r.net Git - u-boot/blobdiff - board/sorcery/Makefile
i.MX28: bug fixes in PMU configuration code
[u-boot] / board / sorcery / Makefile
index 3d6d673792a11735b3bd8fd378bcde2662290f09..e1752e3fa3ecd5551c7cc3aa2857d0e9baf6b7d9 100644 (file)
@@ -1,4 +1,5 @@
-# (C) Copyright 2005
+#
+# (C) Copyright 2005-2006
 # Wolfgang Denk, DENX Software Engineering, wd@denx.de.
 #
 # See file CREDITS for list of people who contributed to this
 
 include $(TOPDIR)/config.mk
 
-LIB    = lib$(BOARD).a
-
-OBJS   := $(BOARD).o
+LIB    = $(obj)lib$(BOARD).o
 
-$(LIB):        $(OBJS) $(SOBJS)
-       $(AR) crv $@ $(OBJS)
+COBJS  := $(BOARD).o
 
-clean:
-       rm -f $(SOBJS) $(OBJS)
+SRCS   := $(SOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS))
+SOBJS  := $(addprefix $(obj),$(SOBJS))
 
-distclean:     clean
-       rm -f $(LIB) core *.bak .depend
+$(LIB):        $(OBJS)
+       $(call cmd_link_o_target, $(OBJS))
 
 #########################################################################
 
-.depend:       Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
-               $(CC) -M $(CPPFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
 
--include .depend
+sinclude $(obj).depend
 
 #########################################################################