File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -83,19 +83,19 @@ function(generate_bindings_for_kernels)
8383 execute_process (
8484 COMMAND
8585 "${PYTHON_EXECUTABLE} " -c
86- "from distutils.sysconfig import get_python_lib; print(get_python_lib( ))"
87- OUTPUT_VARIABLE site-packages -out
88- ERROR_VARIABLE site-packages -out-error
89- RESULT_VARIABLE site-packages -result
86+ "import torchgen; import os; print(os.path.dirname(torchgen.__file__ ))"
87+ OUTPUT_VARIABLE torchgen -out
88+ ERROR_VARIABLE torchgen -out-error
89+ RESULT_VARIABLE torchgen -result
9090 WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
9191 OUTPUT_STRIP_TRAILING_WHITESPACE
9292 )
93- file (GLOB_RECURSE _torchgen_srcs "${site-packages- out}/torchgen /*.py" )
93+ file (GLOB_RECURSE _torchgen_srcs "${torchgen- out}/*.py" )
9494 set (_gen_command
9595 "${PYTHON_EXECUTABLE} " -m torchgen.gen_executorch
9696 --source -path =${EXECUTORCH_ROOT} /codegen --install -dir=${_out_dir}
97- --tags-path =${site-packages- out}/torchgen /packaged/ATen/native/tags.yaml
98- --aten-yaml-path =${site-packages- out}/torchgen /packaged/ATen/native/native_functions.yaml
97+ --tags-path =${torchgen- out}/packaged/ATen/native/tags.yaml
98+ --aten-yaml-path =${torchgen- out}/packaged/ATen/native/native_functions.yaml
9999 --op-selection-yaml-path =${_oplist_yaml}
100100 )
101101 if (GEN_ADD_EXCEPTION_BOUNDARY)
You can’t perform that action at this time.
0 commit comments