Skip to content

Commit 2abe039

Browse files
committed
Require libdiffpy version 1.3.2 or later.
1 parent faf2bde commit 2abe039

2 files changed

Lines changed: 4 additions & 8 deletions

File tree

srrealmodule/srreal_converters.hpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,11 @@
3232
#include <diffpy/srreal/forwardtypes.hpp>
3333
#include <diffpy/srreal/R3linalg.hpp>
3434
#include <diffpy/srreal/QuantityType.hpp>
35+
#include <diffpy/version.hpp>
3536

37+
#if DIFFPY_VERSION < 1003002000
38+
#error "diffpy.srreal requires libdiffpy 1.3.2 or later."
39+
#endif
3640

3741
/// Conversion function that supports implicit conversions in
3842
/// PairQuantity::eval and PairQuantity::setStructure

srrealmodule/wrap_libdiffpy_version.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,6 @@
2020
#include <boost/python/dict.hpp>
2121
#include <boost/python/def.hpp>
2222

23-
#if DIFFPY_VERSION < 1003000
24-
#error "diffpy.srreal requires libdiffpy 1.3 or later."
25-
#endif
26-
2723
namespace srrealmodule {
2824
namespace nswrap_libdiffpy_version {
2925

@@ -48,11 +44,7 @@ python::dict get_libdiffpy_version_info_dict()
4844
rv["micro"] = libdiffpy_version_info::micro;
4945
rv["date"] = libdiffpy_version_info::date;
5046
rv["git_sha"] = libdiffpy_version_info::git_sha;
51-
#if DIFFPY_VERSION > 1003000
5247
rv["patch"] = libdiffpy_version_info::patch;
53-
#else
54-
rv["patch"] = 0;
55-
#endif
5648
return rv;
5749
}
5850

0 commit comments

Comments
 (0)