|
547 | 547 | 'use_system_libjpeg%': '<(android_build_type)',
|
548 | 548 | }],
|
549 | 549 | ],
|
| 550 | + |
| 551 | + # Set this to 1 to use the Google-internal file containing |
| 552 | + # official API keys for Google Chrome even in a developer build. |
| 553 | + # Setting this variable explicitly to 1 will cause your build to |
| 554 | + # fail if the internal file is missing. |
| 555 | + # |
| 556 | + # Set this to 0 to not use the internal file, even when it |
| 557 | + # exists in your checkout. |
| 558 | + # |
| 559 | + # Leave set to 2 to have this variable implicitly set to 1 if |
| 560 | + # you have src/google_apis/internal/google_chrome_api_keys.h in |
| 561 | + # your checkout, and implicitly set to 0 if not. |
| 562 | + # |
| 563 | + # Note that official builds always behave as if this variable |
| 564 | + # was explicitly set to 1, i.e. they always use official keys, |
| 565 | + # and will fail to build if the internal file is missing. |
| 566 | + 'use_official_google_api_keys%': 2, |
| 567 | + |
| 568 | + # Set these to bake the specified API keys and OAuth client |
| 569 | + # IDs/secrets into your build. |
| 570 | + # |
| 571 | + # If you create a build without values baked in, you can instead |
| 572 | + # set environment variables to provide the keys at runtime (see |
| 573 | + # src/google_apis/google_api_keys.h for details). Features that |
| 574 | + # require server-side APIs may fail to work if no keys are |
| 575 | + # provided. |
| 576 | + # |
| 577 | + # Note that if you are building an official build or if |
| 578 | + # use_official_google_api_keys has been set to 1 (explicitly or |
| 579 | + # implicitly), these values will be ignored and the official |
| 580 | + # keys will be used instead. |
| 581 | + 'google_api_key%': '', |
| 582 | + 'google_default_client_id%': '', |
| 583 | + 'google_default_client_secret%': '', |
550 | 584 | },
|
551 | 585 |
|
552 | 586 | # Copy conditionally-set variables out one scope.
|
|
629 | 663 | 'use_libjpeg_turbo%': '<(use_libjpeg_turbo)',
|
630 | 664 | 'use_system_libjpeg%': '<(use_system_libjpeg)',
|
631 | 665 | 'android_build_type%': '<(android_build_type)',
|
| 666 | + 'use_official_google_api_keys%': '<(use_official_google_api_keys)', |
| 667 | + 'google_api_key%': '<(google_api_key)', |
| 668 | + 'google_default_client_id%': '<(google_default_client_id)', |
| 669 | + 'google_default_client_secret%': '<(google_default_client_secret)', |
632 | 670 |
|
633 | 671 | # Use system yasm instead of bundled one.
|
634 | 672 | 'use_system_yasm%': 0,
|
|
891 | 929 | 'windows_sdk_default_path': '<(DEPTH)/third_party/platformsdk_win8/files',
|
892 | 930 | 'directx_sdk_default_path': '<(DEPTH)/third_party/directxsdk/files',
|
893 | 931 |
|
894 |
| - # Set these to bake API keys and OAuth client IDs/secrets into |
895 |
| - # your build. If they are not baked in, you can instead set |
896 |
| - # environment variables to provide the keys at runtime (see |
897 |
| - # src/google_apis/google_api_keys.h for details). Features that |
898 |
| - # require server-side APIs may fail to work if no keys are |
899 |
| - # provided. |
900 |
| - # |
901 |
| - # Note that if you are building an official build or if you set |
902 |
| - # use_official_google_api_keys to 1, these values will be ignored |
903 |
| - # and the official keys will be used instead. |
904 |
| - 'google_api_key%': '', |
905 |
| - 'google_default_client_id%': '', |
906 |
| - 'google_default_client_secret%': '', |
907 |
| - |
908 |
| - # Set this to 1 to use the Google-internal file containing |
909 |
| - # official API keys for Google Chrome even in a developer build. |
910 |
| - 'use_official_google_api_keys%': 0, |
911 |
| - |
912 | 932 | 'conditions': [
|
913 | 933 | ['OS=="win" and "<!(python <(DEPTH)/build/dir_exists.py <(windows_sdk_default_path))"=="True"', {
|
914 | 934 | 'windows_sdk_path%': '<(windows_sdk_default_path)',
|
|
920 | 940 | }, {
|
921 | 941 | 'directx_sdk_path%': '$(DXSDK_DIR)',
|
922 | 942 | }],
|
| 943 | + # If use_official_google_api_keys is already set (to 0 or 1), we |
| 944 | + # do none of the implicit checking. If it is set to 1 and the |
| 945 | + # internal keys file is missing, the build will fail at compile |
| 946 | + # time. If it is set to 0 and keys are not provided by other |
| 947 | + # means, a warning will be printed at compile time. |
| 948 | + ['use_official_google_api_keys==2', { |
| 949 | + 'use_official_google_api_keys%': |
| 950 | + '<!(python <(DEPTH)/google_apis/build/check_internal.py <(DEPTH)/google_apis/internal/google_chrome_api_keys.h)', |
| 951 | + }], |
923 | 952 | ['os_posix==1 and OS!="mac" and OS!="ios"', {
|
924 | 953 | # Figure out the python architecture to decide if we build pyauto.
|
925 | 954 | 'python_arch%': '<!(<(DEPTH)/build/linux/python_arch.sh <(sysroot)/usr/<(system_libdir)/libpython<(python_ver).so.1.0)',
|
|
0 commit comments