max31785-msl: Default not to install
Default not to install the max31785-msl script and provide autoconf and
meson options to install it. This is a tool used to check the revision
of the MAX31785 fan controller chip against a configuration defining
what the minimum ship level is required. Always installing this script
isn't necessary where a MAX31785 chip doesn't exist in a machine or
where the revision of it needs to be verified.
Tested:
Built using autoconf where the max31785-msl script is only installed
when `--enable-max31785-msl` is given
Build using meson where the max31785-msl script is only installed
when `-Denable-max31785-msl=true` is given
Change-Id: I563e30f093340ee035fd55c5fb0a10bef879ca12
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
diff --git a/msl/Makefile.am b/msl/Makefile.am
index fff55d6..f9fd604 100644
--- a/msl/Makefile.am
+++ b/msl/Makefile.am
@@ -1 +1,3 @@
+if WANT_MAX31785_MSL
dist_bin_SCRIPTS = max31785-msl
+endif
diff --git a/msl/meson.build b/msl/meson.build
index f92bb3e..f63f722 100644
--- a/msl/meson.build
+++ b/msl/meson.build
@@ -1,3 +1,4 @@
+if get_option('enable-max31785-msl')
configure_file(
copy: true,
input: 'max31785-msl',
@@ -5,3 +6,4 @@
install_dir: get_option('bindir'),
output: 'max31785-msl',
)
+endif