Skip to content

Commit e21ee09

Browse files
committed
windows support
1 parent 609d1f8 commit e21ee09

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

setup.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
1+
import platform
12
from setuptools import setup, find_packages
23
import torch
34
from torch.utils.cpp_extension import CppExtension, CUDAExtension, CUDA_HOME
45

6+
extra_compile_args = []
7+
if platform.system() != 'Windows':
8+
extra_compile_args += ['-Wno-unused-variable']
9+
510
ext_modules = [
611
CppExtension(
712
'torch_scatter.scatter_cpu', ['cpu/scatter.cpp'],
8-
extra_compile_args=['-Wno-unused-variable'])
13+
extra_compile_args=extra_compile_args)
914
]
1015
cmdclass = {'build_ext': torch.utils.cpp_extension.BuildExtension}
1116

0 commit comments

Comments
 (0)