Skip to content

Commit

Permalink
Merge pull request #53 from Tieqiong/win
Browse files Browse the repository at this point in the history
add: srreal windows support
  • Loading branch information
sbillinge authored Feb 2, 2025
2 parents fdceb92 + b83ee8f commit b075de8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
1 change: 1 addition & 0 deletions requirements/conda.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ diffpy.structure
gsl
# periodictable
# pyobjcryst (up to py3.11 for mac)
# dlfcn-win32 (for windows)
10 changes: 9 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,21 @@ def get_boost_config():
return {"include_dirs": [str(inc)], "library_dirs": [str(lib)]}


if os.name == "nt":
compile_args = ["/std:c++14"]
macros = [("_USE_MATH_DEFINES", None)]
else:
compile_args = ["-std=c++11"]
macros = []

boost_cfg = get_boost_config()
ext_kws = {
"libraries": ["diffpy"] + get_boost_libraries(),
"extra_compile_args": ["-std=c++11"],
"extra_compile_args": compile_args,
"extra_link_args": [],
"include_dirs": [numpy.get_include()] + boost_cfg["include_dirs"],
"library_dirs": boost_cfg["library_dirs"],
"define_macros": macros,
}


Expand Down

0 comments on commit b075de8

Please sign in to comment.