Lines Matching +full:1 +full:- +full:installer +full:- +full:darwin +full:- +full:x86_64
7 # http://www.apache.org/licenses/LICENSE-2.0
30 # pylint: disable=g-import-not-at-top
35 # pylint: enable=g-import-not-at-top
54 'lib64/', 'lib/powerpc64le-linux-gnu/', 'lib/x86_64-linux-gnu/', ''
84 return platform.system() == 'Darwin'
100 answer = input(question) # pylint: disable=bad-builtin
107 """Force symlink, equivalent of 'ln -sf'.
144 write_to_bazelrc('build --action_env {}="{}"'.format(var_name, str(var)))
157 return output.decode('UTF-8').strip()
173 python_bin_path, '-c',
180 python_bin_path, '-c',
199 return run_shell([python_bin_path, '-c', 'import sys; print(sys.version[0])'])
231 if environ_cp.get('USE_DEFAULT_PYTHON_LIB_PATH') == '1':
246 write_to_bazelrc('build --host_force_python=PY2')
252 # Set-up env variables used by python_configure.bzl
255 write_to_bazelrc('build --python_path=\"{}"'.format(python_bin_path))
341 true_strings = ('1', 't', 'true', 'y', 'yes')
394 bazel_config_name: Name for Bazel --config argument to enable build feature.
399 if var == '1':
400 write_to_bazelrc('build:%s --define %s=true' %
402 write_to_bazelrc('build --config=%s' % bazel_config_name)
404 # TODO(mikecase): Migrate all users of configure.py to use --config Bazel
406 write_to_bazelrc('build:%s --define %s=true' %
441 write_to_bazelrc('build --config=%s' % bazel_config_name)
448 Version strings of the form X.YZ and X.Y.Z-xxxxx are supported. The
457 version = version.split('-')[0]
482 sys.exit(1)
485 curr_version = run_shell(['bazel', '--version'],
489 curr_version = curr_version.split('bazel ')[1]
506 sys.exit(1)
510 'build TensorFlow! To downgrade: download the installer for the old '
512 'run the installer.' % max_version)
513 sys.exit(1)
518 """Set up architecture-dependent optimization flags.
526 # gcc on ppc64le does not support -march, use mcpu instead
527 default_cc_opt_flags = '-mcpu=native'
531 # On all other platforms, no longer use `-march=native` as this can result
534 # `-march=native` there.
536 default_cc_opt_flags = '-Wno-sign-compare'
538 ' bazel option "--config=opt" is specified [Default is %s]: '
543 write_to_bazelrc('build:opt --copt=%s' % opt)
544 write_to_bazelrc('build:opt --host_copt=%s' % opt)
545 write_to_bazelrc('build:opt --define with_default_optimizations=true')
701 default_ndk_path = cygpath('%s/Android/Sdk/ndk-bundle' %
704 default_ndk_path = '%s/library/Android/Sdk/ndk-bundle' % environ_cp['HOME']
706 default_ndk_path = '%s/Android/Sdk/ndk-bundle' % environ_cp['HOME']
738 os.path.exists(os.path.join(path, 'build-tools')))
747 'subdirectories "platforms" and "build-tools".'))
751 api_levels = [x.replace('android-', '') for x in api_levels]
756 'android-' + api_level))
761 var_default=api_levels[-1],
765 error_msg='Android-%s is not present in the SDK path.')
767 build_tools = os.path.join(android_sdk_home_path, 'build-tools')
772 os.path.join(android_sdk_home_path, 'build-tools', version))
777 var_default=versions[-1],
781 error_msg=('The selected SDK does not have build-tools version %s '
802 ndk_version = revision.group(1)
818 x.replace('android-', '') for x in api_levels if 'android-' in x
824 'android-' + api_level))
833 error_msg='Android-%s is not present in the NDK path.')
864 Given (7, 2) -> 7.0
865 (7.0.1, 2) -> 7.0
866 (5, 1) -> 5
867 (5.0.3.2, 1) -> 5
878 v = v + (['0'] * (sequence_count - len(v)))
886 'Please specify the comma-separated list of base paths to look for CUDA '
936 if cudnn and len(cudnn.group(1)):
937 cudnn = convert_version_to_int(cudnn.group(1))
938 if cudart and len(cudart.group(1)):
939 cudart = convert_version_to_int(cudart.group(1))
995 pattern = re.compile('[0-9]*\\.[0-9]*')
1016 'Please specify a list of comma-separated CUDA compute capabilities '
1018 'device at: https://developer.nvidia.com/cuda-gpus. Each capability '
1034 m = re.match('[0-9]+.[0-9]+', compute_capability)
1037 sm_compute_match = re.match('(sm|compute)_?([0-9]+[0-9]+)',
1047 ' capabilities of sm_30 and higher. Please re-specify the list'
1057 'and higher. Please re-specify the list of compute '
1079 if environ_cp.get('TF_CUDA_CLANG') == '1':
1080 write_to_bazelrc('build --config=cuda_clang')
1082 write_to_bazelrc('build --config=cuda')
1121 write_to_bazelrc('test --flaky_test_attempts=3')
1122 write_to_bazelrc('test --test_size_filters=small,medium')
1124 # Each instance of --test_tag_filters or --build_tag_filters overrides all
1128 # Filters to use with both --test_tag_filters and --build_tag_filters
1129 test_and_build_filters = ['-benchmark-test', '-no_oss']
1130 # Additional filters for --test_tag_filters beyond those in
1132 test_only_filters = ['-oss_serial']
1134 test_and_build_filters.append('-no_windows')
1135 if ((environ_cp.get('TF_NEED_CUDA', None) == '1') or
1136 (environ_cp.get('TF_NEED_ROCM', None) == '1')):
1137 test_and_build_filters += ['-no_windows_gpu', '-no_gpu']
1139 test_and_build_filters.append('-gpu')
1141 test_and_build_filters += ['-gpu', '-nomac', '-no_mac']
1143 if ((environ_cp.get('TF_NEED_CUDA', None) == '1') or
1144 (environ_cp.get('TF_NEED_ROCM', None) == '1')):
1145 test_and_build_filters.append('-no_gpu')
1146 write_to_bazelrc('test --test_env=LD_LIBRARY_PATH')
1148 test_and_build_filters.append('-gpu')
1151 write_to_bazelrc('test:v1 --test_tag_filters=%s' %
1153 write_to_bazelrc('test:v1 --build_tag_filters=%s' %
1156 'test:v2 --test_tag_filters=%s' %
1157 ','.join(test_and_build_filters + test_only_filters + ['-v1only']))
1158 write_to_bazelrc('test:v2 --build_tag_filters=%s' %
1159 ','.join(test_and_build_filters + ['-v1only']))
1173 write_to_bazelrc('build --define=%s=%s' % (varname, environ_cp[varname]))
1181 # pylint: disable=line-too-long
1183 'build --copt=/d2ReducedOptimizeHugeFunctions --host_copt=/d2ReducedOptimizeHugeFunctions'
1197 write_to_bazelrc('build --define=override_eigen_strong_inline=true')
1202 print('\t--config=%-12s\t# %s' % (name, help_text))
1292 '--workspace',
1309 print('Error checking bazel version: ', e.output.decode('UTF-8').strip())
1333 if environ_cp.get('TF_ENABLE_XLA', '1') == '1':
1334 write_to_bazelrc('build --config=xla')
1338 if (environ_cp.get('TF_NEED_ROCM') == '1' and
1340 environ_cp.get('LD_LIBRARY_PATH') != '1'):
1344 if (environ_cp.get('TF_NEED_ROCM') == '1' and environ_cp.get('ROCM_PATH')):
1347 if ((environ_cp.get('TF_NEED_ROCM') == '1') and
1348 (environ_cp.get('TF_ENABLE_MLIR_GENERATED_GPU_KERNELS') == '1')):
1350 'build:rocm --define tensorflow_enable_mlir_generated_gpu_kernels=1')
1354 if (environ_cp.get('TF_NEED_CUDA') == '1' and
1408 'LD_LIBRARY_PATH') != '1':
1413 if environ_cp.get('TF_CUDA_CLANG') == '1':
1416 if environ_cp.get('TF_DOWNLOAD_CLANG') != '1':
1421 write_to_bazelrc('build:cuda_clang --config=download_clang_use_lld')
1434 # At most 1 GPU platform can be configured.
1436 if environ_cp.get('TF_NEED_ROCM') == '1':
1437 gpu_platform_count += 1
1438 if environ_cp.get('TF_NEED_CUDA') == '1':
1439 gpu_platform_count += 1
1442 'At most 1 GPU platform can be configured.')
1459 if environ_cp.get('TF_CONFIGURE_IOS') == '1':
1463 'adding "--config=<>" to your build command. See .bazelrc for more '
1472 config_info_line('v2', 'Build TensorFlow 2.x instead of 1.x.')