]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-detect-init: plain setup.py install on make install 4663/head
authorLoic Dachary <ldachary@redhat.com>
Wed, 13 May 2015 10:45:58 +0000 (12:45 +0200)
committerLoic Dachary <ldachary@redhat.com>
Wed, 13 May 2015 10:45:58 +0000 (12:45 +0200)
If no DESTDIR environment variable is set, just

  python setup.py install

instead of setting --root, --prefix or --install-layout. These options
are tested to do the right thing in the context of RPM and deb packaging
but they are presumably not what someone using make install manually
would want.

http://tracker.ceph.com/issues/11598 Fixes: #11598

Signed-off-by: Loic Dachary <ldachary@redhat.com>
src/ceph-detect-init/Makefile.am

index 72741afe339fb2c20d4809fc0f7ac7b09d615235..3e5ad03f73277cb803488a2a4157af134d6496a8 100644 (file)
@@ -61,9 +61,12 @@ clean-local::
 
 install-data-local::
        cd ceph-detect-init ; \
-       if lsb_release -si | grep --quiet 'Ubuntu\|Debian\|Devuan' ; then \
-               options=--install-layout=deb ; \
-       else \
-               options=--prefix=/usr ; \
+       if test "$(DESTDIR)" ; then \
+               if lsb_release -si | grep --quiet 'Ubuntu\|Debian\|Devuan' ; then \
+                       options=--install-layout=deb ; \
+               else \
+                       options=--prefix=/usr ; \
+               fi ; \
+               root="--root=$(DESTDIR)" ; \
        fi ; \
-       python setup.py install --root=$(DESTDIR) $$options
+       python setup.py install $$root $$options