summaryrefslogtreecommitdiffstats
path: root/qt-ostree
diff options
context:
space:
mode:
authorRainer Keller <rainer.keller@theqtcompany.com>2016-04-14 10:26:02 +0200
committerRainer Keller <rainer.keller@theqtcompany.com>2016-04-15 10:08:00 +0000
commit37854ffebb8637488453f85f9782485cacc05d8a (patch)
tree85eeb2b2b9637252d379eeeb19e62ff57d646598 /qt-ostree
parented5ca342c34da8fe1646f448bdfc544d69f394a3 (diff)
Use ostree binary from SDK by default
Change-Id: I85f6ccb283d4598dcf93d220824baecb15142b1a Reviewed-by: Gatis Paeglis <gatis.paeglis@theqtcompany.com>
Diffstat (limited to 'qt-ostree')
-rwxr-xr-xqt-ostree/qt-ostree14
1 files changed, 4 insertions, 10 deletions
diff --git a/qt-ostree/qt-ostree b/qt-ostree/qt-ostree
index 1b00231..015dff1 100755
--- a/qt-ostree/qt-ostree
+++ b/qt-ostree/qt-ostree
@@ -116,7 +116,7 @@ print_usage_header()
echo $msg
fi
echo
- echo "Usage: sudo PATH=PATH_TO_OSTREE_BIN:\$PATH $0 OPTIONS"
+ echo "Usage: sudo $0 OPTIONS"
echo
}
@@ -129,15 +129,9 @@ initialize()
fi
# Check for OSTree dependency.
- OSTREE=$(which ostree || /bin/true)
- if [ -z "${OSTREE}" ] ; then
- print_usage_header "Needed command 'ostree' not found in PATH"
- qt_ostree_exit 1
- fi
- rpath=$(objdump -x ${OSTREE} | grep RPATH | awk '{print $2}')
- if [ "${rpath}" != "\$ORIGIN/lib/" ] ; then
- print_usage_header "This script depends on 'ostree' binary from the SDK, but PATH is set to ${OSTREE}"
- qt_ostree_exit 1
+ OSTREE=$(readlink -m "${ROOT}"/../../../ostree/ostree)
+ if [ ! -x "${OSTREE}" ] ; then
+ qt_ostree_error "Needed command 'ostree' not found in SDK"
fi
}