Build from source on Windows failing 
@AIML-ankit Could you please confirm if you are using TF v2.12 which is the latest version?
As per the tested build configuration listed [here](https://www.tensorflow.org/install/source_windows#tested_build_configurations) please let us know if the build from source on windows is not failing now!
For installing TF lite with CMake, please refer to [this](https://www.tensorflow.org/lite/guide/build_cmake).  
Thank you! This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you. C:\Users\Anmaheshwari\TF_2\tensorflow>bazel build --config=opt //tensorflow/tools/pip_package:build_pip_package
INFO: Options provided by the client:
Inherited 'common' options: --isatty=1 --terminal_columns=172
INFO: Reading rc options for 'build' from c:\users\anmaheshwari\tf_2\tensorflow.bazelrc:
Inherited 'common' options: --experimental_repo_remote_exec
INFO: Options provided by the client:
'build' options: --python_path=C:/Users/Anmaheshwari/python/python.exe
INFO: Reading rc options for 'build' from c:\users\anmaheshwari\tf_2\tensorflow.bazelrc:
'build' options: --define framework_shared_object=true --define tsl_protobuf_header_only=true --define=use_fast_cpp_protos=true --define=allow_oversize_protos=true --spawn_strategy=standalone -c opt --announce_rc --define=grpc_no_ares=true --noincompatible_remove_legacy_whole_archive --enable_platform_specific_config --define=with_xla_support=true --config=short_logs --config=v2 --define=no_aws_support=true --define=no_hdfs_support=true --experimental_cc_shared_library --experimental_link_static_libraries_once=false --incompatible_enforce_config_setting_visibility
INFO: Reading rc options for 'build' from c:\users\anmaheshwari\tf_2\tensorflow.tf_configure.bazelrc:
'build' options: --action_env PYTHON_BIN_PATH=C:/Users/Anmaheshwari/python/python.exe --action_env PYTHON_LIB_PATH=C:/Users/Anmaheshwari/python/lib/site-packages --python_path=C:/Users/Anmaheshwari/python/python.exe --copt=/d2ReducedOptimizeHugeFunctions --host_copt=/d2ReducedOptimizeHugeFunctions --define=override_eigen_strong_inline=true
INFO: Reading rc options for 'build' from c:\users\anmaheshwari\tf_2\tensorflow.bazelrc:
'build' options: --deleted_packages=tensorflow/compiler/mlir/tfrt,tensorflow/compiler/mlir/tfrt/benchmarks,tensorflow/compiler/mlir/tfrt/jit/python_binding,tensorflow/compiler/mlir/tfrt/jit/transforms,tensorflow/compiler/mlir/tfrt/python_tests,tensorflow/compiler/mlir/tfrt/tests,tensorflow/compiler/mlir/tfrt/tests/ir,tensorflow/compiler/mlir/tfrt/tests/analysis,tensorflow/compiler/mlir/tfrt/tests/jit,tensorflow/compiler/mlir/tfrt/tests/lhlo_to_tfrt,tensorflow/compiler/mlir/tfrt/tests/lhlo_to_jitrt,tensorflow/compiler/mlir/tfrt/tests/tf_to_corert,tensorflow/compiler/mlir/tfrt/tests/tf_to_tfrt_data,tensorflow/compiler/mlir/tfrt/tests/saved_model,tensorflow/compiler/mlir/tfrt/transforms/lhlo_gpu_to_tfrt_gpu,tensorflow/core/runtime_fallback,tensorflow/core/runtime_fallback/conversion,tensorflow/core/runtime_fallback/kernel,tensorflow/core/runtime_fallback/opdefs,tensorflow/core/runtime_fallback/runtime,tensorflow/core/runtime_fallback/util,tensorflow/core/tfrt/eager,tensorflow/core/tfrt/eager/backends/cpu,tensorflow/core/tfrt/eager/backends/gpu,tensorflow/core/tfrt/eager/core_runtime,tensorflow/core/tfrt/eager/cpp_tests/core_runtime,tensorflow/core/tfrt/gpu,tensorflow/core/tfrt/run_handler_thread_pool,tensorflow/core/tfrt/runtime,tensorflow/core/tfrt/saved_model,tensorflow/core/tfrt/graph_executor,tensorflow/core/tfrt/saved_model/tests,tensorflow/core/tfrt/tpu,tensorflow/core/tfrt/utils
INFO: Found applicable config definition build:short_logs in file c:\users\anmaheshwari\tf_2\tensorflow.bazelrc: --output_filter=DONT_MATCH_ANYTHING
INFO: Found applicable config definition build:v2 in file c:\users\anmaheshwari\tf_2\tensorflow.bazelrc: --define=tf_api_version=2 --action_env=TF2_BEHAVIOR=1
INFO: Found applicable config definition build:opt in file c:\users\anmaheshwari\tf_2\tensorflow.tf_configure.bazelrc: --copt=/arch:AVX --host_copt=/arch:AVX
INFO: Found applicable config definition build:windows in file c:\users\anmaheshwari\tf_2\tensorflow.bazelrc: --copt=/W0 --host_copt=/W0 --copt=/Zc:__cplusplus --host_copt=/Zc:__cplusplus --copt=/D_USE_MATH_DEFINES --host_copt=/D_USE_MATH_DEFINES --features=compiler_param_file --copt=/d2ReducedOptimizeHugeFunctions --host_copt=/d2ReducedOptimizeHugeFunctions --cxxopt=/std:c++17 --host_cxxopt=/std:c++17 --config=monolithic --copt=-DWIN32_LEAN_AND_MEAN --host_copt=-DWIN32_LEAN_AND_MEAN --copt=-DNOGDI --host_copt=-DNOGDI --copt=/Zc:preprocessor --host_copt=/Zc:preprocessor --linkopt=/DEBUG --host_linkopt=/DEBUG --linkopt=/OPT:REF --host_linkopt=/OPT:REF --linkopt=/OPT:ICF --host_linkopt=/OPT:ICF --verbose_failures --features=compiler_param_file
INFO: Found applicable config definition build:monolithic in file c:\users\anmaheshwari\tf_2\tensorflow.bazelrc: --define framework_shared_object=false --define tsl_protobuf_header_only=false --experimental_link_static_libraries_once=false
INFO: Repository local_execution_config_python instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:962:19: in workspace
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:96:27: in _tf_toolchains
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/tools/toolchains/remote_config/configs.bzl:6:28: in initialize_rbe_configs
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/tools/toolchains/remote_config/rbe_config.bzl:158:27: in _tensorflow_local_config
Repository rule local_python_configure defined at:
C:/users/anmaheshwari/tf_2/tensorflow/third_party/py/python_configure.bzl:279:41: in
INFO: Repository local_config_python instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:962:19: in workspace
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:106:21: in _tf_toolchains
Repository rule python_configure defined at:
C:/users/anmaheshwari/tf_2/tensorflow/third_party/py/python_configure.bzl:298:35: in
ERROR: An error occurred during the fetch of repository 'local_execution_config_python':
Traceback (most recent call last):
File "C:/users/anmaheshwari/tf_2/tensorflow/third_party/py/python_configure.bzl", line 212, column 22, in _create_local_python_repository
_check_python_bin(repository_ctx, python_bin)
File "C:/users/anmaheshwari/tf_2/tensorflow/third_party/py/python_configure.bzl", line 145, column 25, in _check_python_bin
auto_config_fail("--define %s='%s' is not executable. Is it the python binary?" % (
File "C:/users/anmaheshwari/tf_2/tensorflow/third_party/remote_config/common.bzl", line 12, column 9, in auto_config_fail
fail("%sConfiguration Error:%s %s\n" % (red, no_color, msg))
Error in fail: Configuration Error: --define PYTHON_BIN_PATH='C:/Users/Anmaheshwari/python/python.exe' is not executable. Is it the python binary?
ERROR: C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: fetching local_python_configure rule //external:local_execution_config_python: Traceback (most recent call last):
File "C:/users/anmaheshwari/tf_2/tensorflow/third_party/py/python_configure.bzl", line 212, column 22, in _create_local_python_repository
_check_python_bin(repository_ctx, python_bin)
File "C:/users/anmaheshwari/tf_2/tensorflow/third_party/py/python_configure.bzl", line 145, column 25, in _check_python_bin
auto_config_fail("--define %s='%s' is not executable. Is it the python binary?" % (
File "C:/users/anmaheshwari/tf_2/tensorflow/third_party/remote_config/common.bzl", line 12, column 9, in auto_config_fail
fail("%sConfiguration Error:%s %s\n" % (red, no_color, msg))
Error in fail: Configuration Error: --define PYTHON_BIN_PATH='C:/Users/Anmaheshwari/python/python.exe' is not executable. Is it the python binary?
INFO: Repository stablehlo instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:965:28: in workspace
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:83:14: in _initialize_third_party
C:/users/anmaheshwari/tf_2/tensorflow/third_party/stablehlo/workspace.bzl:11:20: in repo
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:136:21: in tf_http_archive
Repository rule _tf_http_archive defined at:
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:89:35: in
INFO: Repository termcolor_archive instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:972:21: in workspace
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:388:20: in _tf_repositories
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:136:21: in tf_http_archive
Repository rule _tf_http_archive defined at:
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:89:35: in
INFO: Repository eigen_archive instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:965:28: in workspace
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:65:11: in _initialize_third_party
C:/users/anmaheshwari/tf_2/tensorflow/third_party/eigen3/workspace.bzl:14:20: in repo
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:136:21: in tf_http_archive
Repository rule _tf_http_archive defined at:
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:89:35: in
INFO: Repository cpuinfo instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:972:21: in workspace
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:166:20: in _tf_repositories
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:136:21: in tf_http_archive
Repository rule _tf_http_archive defined at:
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:89:35: in
INFO: Repository sobol_data instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:15:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:965:28: in workspace
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace2.bzl:82:15: in _initialize_third_party
C:/users/anmaheshwari/tf_2/tensorflow/third_party/sobol_data/workspace.bzl:6:20: in repo
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:136:21: in tf_http_archive
Repository rule _tf_http_archive defined at:
C:/users/anmaheshwari/tf_2/tensorflow/third_party/repo.bzl:89:35: in
INFO: Repository go_sdk instantiated at:
C:/users/anmaheshwari/tf_2/tensorflow/WORKSPACE:23:14: in
C:/users/anmaheshwari/tf_2/tensorflow/tensorflow/workspace0.bzl:135:20: in workspace
C:/users/anmaheshwari/_bazel_anmaheshwari/unnl57ya/external/com_github_grpc_grpc/bazel/grpc_extra_deps.bzl:36:27: in grpc_extra_deps
C:/users/anmaheshwari/_bazel_anmaheshwari/unnl57ya/external/io_bazel_rules_go/go/private/sdk.bzl:431:28: in go_register_toolchains
C:/users/anmaheshwari/_bazel_anmaheshwari/unnl57ya/external/io_bazel_rules_go/go/private/sdk.bzl:130:21: in go_download_sdk
Repository rule _go_download_sdk defined at:
C:/users/anmaheshwari/_bazel_anmaheshwari/unnl57ya/external/io_bazel_rules_go/go/private/sdk.bzl:117:35: in
ERROR: Analysis of target '//tensorflow/tools/pip_package:build_pip_package' failed; build aborted: Configuration Error: --define PYTHON_BIN_PATH='C:/Users/Anmaheshwari/python/python.exe' is not executable. Is it the python binary?
INFO: Elapsed time: 1.792s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (34 packages loaded, 194 targets configured)
currently loading: @llvm-project//llvm ... (11 packages)
Fetching https://github.com/boringssl; fetching
Fetching @com_google_absl; fetching
Fetching @libjpeg_turbo; fetching
Fetching @png; fetching
Fetching ...ingssl; Extracting C:/users/anmaheshwari/_bazel_anmaheshwari/unnl57ya/external/boringssl/temp13612522096612888484/c00d7ca810e93780bd0c8ee4eea28f4f2ea4bcdc
.tar.gz

C:\Users\Anmaheshwari\TF_2\tensorflow> Hi @AIML-ankit 

Looks like this is duplicate of issue #60112 . Can you please close this issue, since it is already being tracked there?

Thanks. This issue is stale because it has been open for 7 days with no activity. It will be closed if no further activity occurs. Thank you. This issue was closed because it has been inactive for 7 days since being marked as stale. Please reopen if you'd like to work on this further. Are you satisfied with the resolution of your issue?
<a href="https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/60083">Yes</a>
<a href="https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/60083">No</a>

### 1. System information

- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Windows 
- TensorFlow installation (pip package or built from source): Build from source on Windows
- TensorFlow library (version, if pip package or github SHA, if built from source): 2.12

bazel version - 5.3
python version - 3.9 

i am following below link -

https://www.tensorflow.org/install/source_windows


command that I am  running - 
bazel build //tensorflow/tools/pip_package:build_pip_package




Error message -

Repository rule _tf_http_archive defined at:
  C:/users/anmaheshwari/downloads/tf/tensorflow-2.12.0/tensorflow-2.12.0/third_party/repo.bzl:89:35: in <toplevel>
ERROR: C:/users/anmaheshwari/downloads/tf/tensorflow-2.12.0/tensorflow-2.12.0/tensorflow/core/BUILD:511:11: //tensorflow/core:ops depends on //tensorflow/compiler/mlir/tensorflow:mlir_passthrough_op in repository @ which failed to fetch. no such package '@llvm-project//mlir': Failed to find python3 binary
ERROR: Analysis of target '//tensorflow/lite/delegates/flex:tensorflowlite_flex' failed; build aborted:
INFO: Elapsed time: 297.423s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (87 packages loaded, 331 targets configured)
    currently loading: tensorflow/lite/schema ... (4 packages)
    Fetching @flatbuffers; fetching
    Fetching ...ri/grgp23z7/external/flatbuffers; Extracting C:/users/anmaheshwari/_bazel_anmaheshwari/grgp23z7/external/flatbuffers/temp5290822748239123909/v2.0.6.tar.gz
    Fetching @nsync; fetching
    Fetching https://storage.googleapis.com/mirror.tensorflow.org/github.com/abseil/abseil-cpp/archive/273292d1cfc0a94a65082ee350509af1d113344d.tar.gz

C:\Users\Anmaheshwari\Downloads\TF\tensorflow-2.12.0\tensorflow-2.12.0>