2002-10-10 12:38:13 +05:30
|
|
|
# This file gets included into the main Makefile, in the top directory.
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 12:38:13 +05:30
|
|
|
INSTALL += $(bin)ps
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
# files to remove
|
|
|
|
CLEAN += ps/ps ps/debug
|
2002-10-10 12:38:13 +05:30
|
|
|
|
|
|
|
# a directory for cleaning
|
|
|
|
DIRS += ps
|
|
|
|
|
|
|
|
# a file to create
|
|
|
|
ALL += ps/ps
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
PSNAMES := $(addprefix ps/,display escape global help output parser select sortformat)
|
|
|
|
PSOBJ := $(addsuffix .o,$(PSNAMES))
|
|
|
|
PSSRC := $(addsuffix .c,$(PSNAMES))
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
ps/ps: $(PSOBJ) $(LIBPROC)
|
|
|
|
$(CC) $(LDFLAGS) -o $@ $^
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
# This just adds the stacktrace code
|
|
|
|
ps/debug: $(PSOBJ) stacktrace.o $(LIBPROC)
|
|
|
|
$(CC) -o $@ $^ -lefence
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
$(PSOBJ): %.o: ps/%.c ps/common.h proc/$(SONAME)
|
|
|
|
# $(CC) -c $(CFLAGS) $< -o $@
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
ps/stacktrace.o: ps/stacktrace.c
|
2002-10-09 02:47:06 +05:30
|
|
|
|
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
$(bin)ps: ps/ps
|
|
|
|
install --mode a=rx --strip $< $@
|
2002-10-09 02:47:06 +05:30
|
|
|
|
2002-10-10 14:41:50 +05:30
|
|
|
$(man1)ps.1 : ps/ps.1
|
|
|
|
install --mode a=r $< $@
|
2002-10-09 02:47:06 +05:30
|
|
|
-rm -f $(DESTDIR)/var/catman/cat1/ps.1.gz $(DESTDIR)/var/man/cat1/ps.1.gz
|