aboutsummaryrefslogtreecommitdiffstats
path: root/tools/power/acpi/Makefile.rules
diff options
context:
space:
mode:
authorLv Zheng <lv.zheng@intel.com>2015-07-28 13:25:25 +0800
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2015-07-31 23:39:31 +0200
commit391fc234b543991dd7d0361e634cdf5abfbdd0a3 (patch)
tree6fee9fb834b018ed67b85201f9b064d783c6bbeb /tools/power/acpi/Makefile.rules
parentACPICA: Update version to 20150717 (diff)
downloadlinux-dev-391fc234b543991dd7d0361e634cdf5abfbdd0a3.tar.xz
linux-dev-391fc234b543991dd7d0361e634cdf5abfbdd0a3.zip
tools/power/acpi: Add descend support in ACPI tools Makefile
This patch splits tools/power/acpi/Makefile to support descend compling for ACPI tools. In this patch tools/ec related stuff is removed as it is originally not enabled. Also a missing .o (utnonansi.o) is added to the acpidump/Makefile. Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'tools/power/acpi/Makefile.rules')
-rw-r--r--tools/power/acpi/Makefile.rules37
1 files changed, 37 insertions, 0 deletions
diff --git a/tools/power/acpi/Makefile.rules b/tools/power/acpi/Makefile.rules
new file mode 100644
index 000000000000..ec87a9e562c0
--- /dev/null
+++ b/tools/power/acpi/Makefile.rules
@@ -0,0 +1,37 @@
+# tools/power/acpi/Makefile.rules - ACPI tool Makefile
+#
+# Copyright (c) 2015, Intel Corporation
+# Author: Lv Zheng <lv.zheng@intel.com>
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; version 2
+# of the License.
+
+$(OUTPUT)$(TOOL): $(TOOL_OBJS) FORCE
+ $(ECHO) " LD " $@
+ $(QUIET) $(LD) $(CFLAGS) $(LDFLAGS) $(TOOL_OBJS) -L$(OUTPUT) -o $@
+ $(QUIET) $(STRIPCMD) $@
+
+$(OUTPUT)%.o: %.c
+ $(ECHO) " CC " $@
+ $(QUIET) $(CC) -c $(CFLAGS) -o $@ $<
+
+all: $(OUTPUT)$(TOOL)
+clean:
+ -find $(OUTPUT) \( -not -type d \) \
+ -and \( -name '*~' -o -name '*.[oas]' \) \
+ -type f -print \
+ | xargs rm -f
+ -rm -f $(OUTPUT)$(TOOL)
+
+install-tools:
+ $(INSTALL) -d $(DESTDIR)${sbindir}
+ $(INSTALL_PROGRAM) $(OUTPUT)$(TOOL) $(DESTDIR)${sbindir}
+uninstall-tools:
+ - rm -f $(DESTDIR)${sbindir}/$(TOOL)
+
+install: all install-tools $(EXTRA_INSTALL)
+uninstall: uninstall-tools $(EXTRA_UNINSTALL)
+
+.PHONY: FORCE