diff options
author | Pavel Šimerda <pavlix@pavlix.net> | 2017-12-28 15:21:50 +0100 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2018-01-03 15:24:04 +0100 |
commit | 1402fa7487b29fc1ea39a6bf7659fee7f30bb0e0 (patch) | |
tree | 45f01ccebb2af15249d1dc9b10fc662f278c2f22 | |
parent | 6341b6a5daff3e6506207e046d9b3be0eaec8593 (diff) | |
download | NetworkManager-1402fa7487b29fc1ea39a6bf7659fee7f30bb0e0.tar.gz |
ifcfg: test for sysconfig network path instead of distribution paths
We don't have a complete list of distributions that use ifcfg for network
configuration but we can easily check for `/etc/sysconfig/network-scripts`
and then distributions can explicitly disable the plugin of that is what
they want.
[thaller@redhat.com: cherry-picked and adjusted for rebase from
https://github.com/NetworkManager/NetworkManager/pull/49]
-rw-r--r-- | configure.ac | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index 444610550a..f90a89d45d 100644 --- a/configure.ac +++ b/configure.ac @@ -122,10 +122,7 @@ AC_ARG_ENABLE(config-plugin-ibft, AS_HELP_STRING([--enable-config-plugin-ibft], AC_ARG_ENABLE(ifcfg-rh, AS_HELP_STRING([--enable-ifcfg-rh], [enable ifcfg-rh configuration plugin (Fedora/RHEL)])) AC_ARG_ENABLE(ifupdown, AS_HELP_STRING([--enable-ifupdown], [enable ifupdown configuration plugin (Debian/Ubuntu)])) # Default alternative plugins by distribution -AS_IF([test -z "$enable_ifcfg_rh"], AC_CHECK_FILE(/etc/redhat-release, enable_ifcfg_rh=yes)) -AS_IF([test -z "$enable_ifcfg_rh"], AC_CHECK_FILE(/etc/fedora-release, enable_ifcfg_rh=yes)) -AS_IF([test -z "$enable_ifcfg_rh"], AC_CHECK_FILE(/etc/mandriva-release, enable_ifcfg_rh=yes)) -AS_IF([test -z "$enable_ifcfg_rh"], AC_CHECK_FILE(/etc/mageia-release, enable_ifcfg_rh=yes)) +AS_IF([test -z "$enable_ifcfg_rh"], AC_CHECK_FILE(/etc/sysconfig/network-scripts, enable_ifcfg_rh=yes)) AS_IF([test -z "$enable_ifupdown"], AC_CHECK_FILE(/etc/debian_version, enable_ifupdown=yes)) # Otherwise plugins default to "no" AS_IF([test -z "$enable_ifcfg_rh"], enable_ifcfg_rh=no) |