diff options
Diffstat (limited to 'applets')
-rw-r--r-- | applets/Makefile | 12 | ||||
-rw-r--r-- | applets/Makefile.in | 11 |
2 files changed, 13 insertions, 10 deletions
diff --git a/applets/Makefile b/applets/Makefile index 5f9167442..b566e4d12 100644 --- a/applets/Makefile +++ b/applets/Makefile | |||
@@ -17,13 +17,15 @@ | |||
17 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 17 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
18 | # | 18 | # |
19 | 19 | ||
20 | TOPDIR:= ../ | 20 | top_srcdir=.. |
21 | top_builddir=.. | ||
22 | srcdir=$(top_srcdir)/applets | ||
21 | APPLETS_DIR:=./ | 23 | APPLETS_DIR:=./ |
22 | include $(TOPDIR).config | 24 | include $(top_builddir)/Rules.mak |
23 | include $(TOPDIR)Rules.mak | 25 | include $(top_builddir)/.config |
24 | include Makefile.in | 26 | include $(srcdir)/Makefile.in |
25 | all: $(libraries-y) | 27 | all: $(libraries-y) |
26 | -include $(TOPDIR).depend | 28 | -include $(top_builddir).depend |
27 | 29 | ||
28 | clean: | 30 | clean: |
29 | rm -f *.o *.a $(AR_TARGET) | 31 | rm -f *.o *.a $(AR_TARGET) |
diff --git a/applets/Makefile.in b/applets/Makefile.in index afd5cbeb9..e31bb6fd9 100644 --- a/applets/Makefile.in +++ b/applets/Makefile.in | |||
@@ -19,18 +19,19 @@ | |||
19 | 19 | ||
20 | APPLETS_AR:=applets.a | 20 | APPLETS_AR:=applets.a |
21 | ifndef $(APPLETS_DIR) | 21 | ifndef $(APPLETS_DIR) |
22 | APPLETS_DIR:=$(TOPDIR)applets/ | 22 | APPLETS_DIR:=$(top_builddir)/applets/ |
23 | endif | 23 | endif |
24 | srcdir=$(top_srcdir)/applets | ||
24 | 25 | ||
25 | APPLET_SRC:=applets.c busybox.c | 26 | APPLET_SRC:=applets.c busybox.c |
26 | APPLET_OBJ:= $(patsubst %.c,$(APPLETS_DIR)%.o, $(APPLET_SRC)) | 27 | APPLET_OBJ:= $(patsubst %.c,$(APPLETS_DIR)%.o, $(APPLET_SRC)) |
27 | 28 | ||
28 | |||
29 | |||
30 | libraries-y+=$(APPLETS_DIR)$(APPLETS_AR) | 29 | libraries-y+=$(APPLETS_DIR)$(APPLETS_AR) |
31 | 30 | ||
32 | $(APPLET_OBJ): $(TOPDIR).config | ||
33 | |||
34 | $(APPLETS_DIR)$(APPLETS_AR): $(APPLET_OBJ) | 31 | $(APPLETS_DIR)$(APPLETS_AR): $(APPLET_OBJ) |
35 | $(AR) -ro $@ $(APPLET_OBJ) | 32 | $(AR) -ro $@ $(APPLET_OBJ) |
36 | 33 | ||
34 | $(APPLET_OBJ): $(top_builddir)/.config | ||
35 | $(APPLET_OBJ): $(APPLETS_DIR)%.o: $(srcdir)/%.c | ||
36 | $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $< | ||
37 | |||