Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion deploy/platform/debian/test-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ DEBIAN_FRONTEND=noninteractive \

echo "=== Testing ==="
. /usr/local/mdsplus/setup.sh
mdstcl show version

python3 -c 'import MDSplus; print(MDSplus.__version__)' || exit 42

mdstcl show version
# MDSplus uses weird return codes
[ $? -eq 1 ] || exit 42
6 changes: 4 additions & 2 deletions deploy/platform/redhat/test-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ dnf install -y "$@" || exit 1

echo "=== Testing ==="
. /usr/local/mdsplus/setup.sh
mdstcl show version

python3 -c 'import MDSplus; print(MDSplus.__version__)' || exit 42

mdstcl show version
# MDSplus uses weird return codes
[ $? -eq 1 ] || exit 42
[ $? -eq 1 ] || exit 42
1 change: 1 addition & 0 deletions rpm/envsyms.in
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#
MDS_PATH $MDSPLUS_DIR/tdi
MDS_PYDEVICE_PATH $MDSPLUS_DIR/pydevices
PYTHONPATH $MDSPLUS_DIR/python >:
PYTHONPATH $MDSPLUS_DIR/pydevices >:
MATLABPATH $MDSPLUS_DIR/matlab <:
UIDPATH $MDSPLUS_DIR/uid/%U <:
Expand Down
15 changes: 3 additions & 12 deletions rpm/python_module_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,12 @@ if test "${module}" = "MDSplus"; then
srcdir=${mdsplus_dir}/python
if test "$(${mdsplus_dir}/rpm/python_module_remove.sh ${module} y)" = "y"; then
setup_install=y
elif test -z "${MDSPLUS_SETUP_PY}"; then
echo "Set MDSPLUS_SETUP_PY=y if you wish to run setup.py install."
fi
else
setup_install=
srcdir=${mdsplus_dir}/pydevices
fi

for python in python2 python3; do
if ( ${python} -c pass >/dev/null 2>&1 ); then
${python} -m compileall -q -f ${srcdir}/${module} >/dev/null 2>&1
if test "${setup_install}" = "y"; then
if ! ${python} ${srcdir}/${module}/setup.py -q install >/dev/null; then
echo "Could not 'setup.py install' MDSplus for ${python}"
fi
fi
fi
done
if test "${setup_install}" = "y"; then
echo "MDSPLUS_SETUP_PY has been removed, and ${mdsplus_dir}/python has been placed in the PYTHONPATH in ${mdsplus_dir}/etc/envsyms"
fi