summaryrefslogtreecommitdiff
path: root/procps
diff options
context:
space:
mode:
Diffstat (limited to 'procps')
-rw-r--r--procps/Makefile10
-rw-r--r--procps/Makefile.in6
2 files changed, 11 insertions, 5 deletions
diff --git a/procps/Makefile b/procps/Makefile
index 0238f7e..1cc8804 100644
--- a/procps/Makefile
+++ b/procps/Makefile
@@ -17,13 +17,15 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
-TOPDIR:= ../
+top_srcdir=..
+top_builddir=..
+srcdir=$(top_srcdir)/procps
PROCPS_DIR:=./
-include $(TOPDIR).config
-include $(TOPDIR)Rules.mak
+include $(top_builddir)/Rules.mak
+include $(top_builddir)/.config
include Makefile.in
all: $(libraries-y)
--include $(TOPDIR).depend
+-include $(top_builddir)/.depend
clean:
rm -f *.o *.a $(AR_TARGET)
diff --git a/procps/Makefile.in b/procps/Makefile.in
index 1c2e00f..ced29a1 100644
--- a/procps/Makefile.in
+++ b/procps/Makefile.in
@@ -19,8 +19,9 @@
PROCPS_AR:=procps.a
ifndef $(PROCPS_DIR)
-PROCPS_DIR:=$(TOPDIR)procps/
+PROCPS_DIR:=$(top_builddir)/procps/
endif
+srcdir=$(top_srcdir)/procps
PROCPS-y:=
PROCPS-$(CONFIG_FREE) += free.o
@@ -37,3 +38,6 @@ libraries-y+=$(PROCPS_DIR)$(PROCPS_AR)
$(PROCPS_DIR)$(PROCPS_AR): $(patsubst %,$(PROCPS_DIR)%, $(PROCPS-y))
$(AR) -ro $@ $(patsubst %,$(PROCPS_DIR)%, $(PROCPS-y))
+$(PROCPS_DIR)%.o: $(srcdir)/%.c
+ $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -c -o $@ $<
+