aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel/src/xds.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2017-10-18 11:58:50 +0200
committerThomas White <taw@physics.org>2017-10-18 11:58:50 +0200
commite18c025df6f5d8e2ecd0b0ac2b827e657fb53415 (patch)
treede8d92370d468f2e72094991ef8a09e40ff391bf /libcrystfel/src/xds.c
parent0821a7ddae7901b70ea5ae216c71fe41109fec55 (diff)
Check that dirax,felix,mosflm or xds are available at the start
Avoids a confusing error message later.
Diffstat (limited to 'libcrystfel/src/xds.c')
-rw-r--r--libcrystfel/src/xds.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/libcrystfel/src/xds.c b/libcrystfel/src/xds.c
index a234d1e0..bd98aec4 100644
--- a/libcrystfel/src/xds.c
+++ b/libcrystfel/src/xds.c
@@ -45,6 +45,7 @@
#include <sys/ioctl.h>
#include <errno.h>
+#include "xds.h"
#include "cell.h"
#include "image.h"
#include "utils.h"
@@ -596,6 +597,12 @@ void *xds_prepare(IndexingMethod *indm, UnitCell *cell)
{
struct xds_private *xp;
+ if ( xds_probe(cell) == NULL ) {
+ ERROR("XDS does not appear to run properly.\n");
+ ERROR("Please check your XDS installation.\n");
+ return NULL;
+ }
+
/* Either cell,latt and cell provided, or nocell-nolatt and no cell
* - complain about anything else. Could figure this out automatically,
* but we'd have to decide whether the user just forgot the cell, or