acrn-hypervisor/tools/acrnlog/Makefile
Yan, Like 57d6a933f6 tools: correct several Makefile problems
1. mkdir ./tools/build if it does not exist;
2. correct static lib path for acrn-manager;
3. do not remove acrnlog.service if build under source code dir by default.

Reviewed-by: Geoffroy VanCutsem <geoffroy.vancutsem@intel.com>
Signed-off-by: Yan, Like <like.yan@intel.com>
2018-06-19 15:33:31 +08:00

19 lines
454 B
Makefile

OUT_DIR ?= .
all:
$(CC) -g acrnlog.c -o $(OUT_DIR)/acrnlog -lpthread
cp acrnlog.service $(OUT_DIR)/acrnlog.service
clean:
rm -f $(OUT_DIR)/acrnlog
ifneq ($(OUT_DIR),.)
rm -f $(OUT_DIR)/acrnlog.service
endif
install: $(OUT_DIR)/acrnlog
install -d $(DESTDIR)/usr/bin
install -t $(DESTDIR)/usr/bin $(OUT_DIR)/acrnlog
install -d $(DESTDIR)/usr/lib/systemd/system
install -p -D -m 0644 $(OUT_DIR)/acrnlog.service $(DESTDIR)/usr/lib/systemd/system