summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xsetup.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index bd41bc91..3b0af03c 100755
--- a/setup.py
+++ b/setup.py
@@ -81,9 +81,13 @@ INITSYS_TYPES = sorted(list(INITSYS_ROOTS.keys()))
# FreeBSD systems.
USR = "/usr"
ETC = "/etc"
+USR_LIB_EXEC = "/usr/lib"
if os.uname()[0] == 'FreeBSD':
USR = "/usr/local"
+ USR_LIB_EXEC = "/usr/local/lib"
ETC = "/usr/local/etc"
+elif os.path.isfile('/etc/redhat-release'):
+ USR_LIB_EXEC = "/usr/libexec"
def get_version():
@@ -149,7 +153,7 @@ setuptools.setup(name='cloud-init',
data_files=[(ETC + '/cloud', glob('config/*.cfg')),
(ETC + '/cloud/cloud.cfg.d', glob('config/cloud.cfg.d/*')),
(ETC + '/cloud/templates', glob('templates/*')),
- (USR + '/lib/cloud-init',
+ (USR_LIB_EXEC + '/cloud-init',
['tools/uncloud-init',
'tools/write-ssh-key-fingerprints']),
(USR + '/share/doc/cloud-init',