Граф коммитов

19 Коммитов

Автор SHA1 Сообщение Дата
hashimoto a92d81eb80 GN: Respect system libdir whenever building with the traget sysroot
Nacl uses its own toolchain with the target sysroot.
System libdir should be respected with that toolchain too.

BUG=606432

Review URL: https://codereview.chromium.org/1914103002

Cr-Original-Commit-Position: refs/heads/master@{#389830}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: a82baa163c5969ef8f4733ecfeb5fe20cf51cd13
2016-04-26 18:59:21 +00:00
zforman 31d7d1b4ed Reverts fdca07 and makes it possible to force absolute paths.
Explicitly: This reverts the patch that reverted the patch that
removed the majority of absolute paths from linux builds, and makes
it possible to use an absolute path by setting dont_embed_build_metadata
to false.

In conjunction with codereview.chromium.org/1642193002 that modifies the codesearch
buildbot to use dont_embed_build_metadata = false, this CL should allow
codesearch to continue working, and all other buildbots and users
to gain the benefits of not requiring absolute paths.

BUG=580103

Review URL: https://codereview.chromium.org/1643523004

Cr-Original-Commit-Position: refs/heads/master@{#373432}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 4b6f030a35226c0d6e412b1025e791e5391b1455
2016-02-04 02:24:31 +00:00
sbc 8a7026fdcf GN: Only honour system_libdir for target toolchain
Without this change when system_libdir is set (e.g.
to lib64) it would apply this to all toolchains
including the host toolchain.

Review URL: https://codereview.chromium.org/1583093002

Cr-Original-Commit-Position: refs/heads/master@{#371875}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: d4566597ab32adc5586831308625c0de954e4920
2016-01-27 21:37:28 +00:00
dsansome ac259f6da2 Revert "clang: Makes builds with clang less dependent on absolute file path"
This reverts commit fdca0741b22a4dddbf1808b8d0081651662b22c5.

This seems to break codesearch grok indexing.

BUG=580103
TBR=brettw

Review URL: https://codereview.chromium.org/1620583002

Cr-Original-Commit-Position: refs/heads/master@{#370919}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: f6ea5e493b26f559ee94fcdd5b7e9a4727c62587
2016-01-22 07:22:18 +00:00
zforman 41a6d7b815 clang: Makes builds with clang less dependent on absolute file path
[Note: Dependency claims are only valid on Linux builds]

This change removes absolute file paths from several locations in
produced binaries, reducing the total number of files containing
absolute file paths from ~30k to ~4k.

Specifically, this removes absolute paths from:
.rodata (sysroot based)
.debug_str, .debug_info (debug prefix based)
.debug_line (debug prefix and sysroot based)

.debug_info still contains (on Linux) 22 absolute paths, but
as discussed below, this is most likely simple to resolve.

This can be measured by using
$ find out/Default/ -type f | grep -v ninja | xargs -I '{}' grep -l \
  'absolute-path-component' '{}' | wc -l

Before: 30420
After: 3917 (https://gist.github.com/anonymous/fd870076c990fcf792c7)

The remaining instances mostly originate from NaCL not
having the flag enabled. Enabling requires updating the
toolchain's version of clang to newer than release 3.8

Generated ninja files still have some absolute file paths. At
the very least, they contain -fdebug-prefix-map=/ABSOLUTE/PATH/TO/DIR.
This will be removed later.

BUG=439949

Review URL: https://codereview.chromium.org/1556923002

Cr-Original-Commit-Position: refs/heads/master@{#370320}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: fdca0741b22a4dddbf1808b8d0081651662b22c5
2016-01-20 05:20:27 +00:00
rjkroege ad3a6e9321 Introduce a GN arg controlling the path prefix in pkg-config and modify pkg-config.py to use it.
Review URL: https://codereview.chromium.org/1564503002

Cr-Original-Commit-Position: refs/heads/master@{#367987}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: a7efe0d67a564d1dbe540d70de2bf1f4ef409bb4
2016-01-07 02:12:58 +00:00
brettw 299e90170d Use new GN features in the build.
Uses forward_variables_from for some obvious cases not including the Android build, and use the template() function in the component() definition.

Remove uses of component_mode since I want to delete that.

Review URL: https://codereview.chromium.org/1265263002

Cr-Original-Commit-Position: refs/heads/master@{#341767}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: a09029884e02a3c027a485877886cf75969f6b3d
2015-08-04 19:52:35 +00:00
dpranke 6b94cd7a12 Update Chomium's build files to work w/ latest GN binaries.
The latest GN binaries rename cpu_arch to current_cpu and/or target_cpu
as appropriate, build_cpu_arch to host_cpu, and os to current_os and target_os as appropriate.

R=brettw@chromium.org
TBR=ddorwin@chromium.org
EXTRA_TRYBOTS=tryserver.chromium.linux:android_chromium_gn_compile_dbg,android_chromium_gn_compile_rel;tryserver.chromium.win:win8_chromium_gn_rel,win8_chromium_gn_dbg;tryserver.chromium.mac:mac_chromium_gn_rel,mac_chromium_gn_dbg
BUG=344767

Review URL: https://codereview.chromium.org/913373002

Cr-Original-Commit-Position: refs/heads/master@{#317223}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 4327621a322c964a8bc6d1ef5a4534f0f877d63e
2015-02-20 02:56:07 +00:00
scottmg fd96972e70 gn format //build
A starting point for doing all of src, and adding a PRESUBMIT.

Includes https://codereview.chromium.org/772663002/ and https://codereview.chromium.org/770053002/.
I haven't pushed new binaries yet.

Generated via:
> cd build
> git ls-files *.gn *.gni | sed -e "s/^/@..\\\\out\\\\Debug\\\\gn format --in-place /" >x.bat && x.bat

The only things that I don't love in the current output are:

1. Turning

    args = [
      "--depfile", rebase_path(depfile, root_build_dir),
      "--android-sdk-tools", rebased_android_sdk_build_tools,
      "--dex-path", rebased_output,
    ]

into:

    args = [
      "--depfile",
      rebase_path(depfile, root_build_dir),
      "--android-sdk-tools",
      rebased_android_sdk_build_tools,
      "--dex-path",
      rebased_output,
    ]

The heuristic for this isn't trivial though, and it also affects e.g. '-Xclang' in cflags, as well
as assignments to temporaries that are later assigned to args.

2. Turning single line

    if (defined(invoker.inputs)) { inputs = invoker.inputs }

into

    if (defined(invoker.inputs)) {
      inputs = invoker.inputs
    }

This could be argued to be an improvement, but as it's very boilerplate-y perhaps an exception to
allow single line in this case is worthwhile. I think there was discussion of new syntax for this
case too, something like "inputs ?= invoker.inputs" maybe.

In both cases, I think it's worthwhile to get formatting turned on, and then go back and special
case these if we decide it's worthwhile.

R=brettw@chromium.org
BUG=348474

Review URL: https://codereview.chromium.org/766573003

Cr-Original-Commit-Position: refs/heads/master@{#306305}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: b199254f481c5db36d56e83fce40594b06d2b81f
2014-12-02 00:25:35 +00:00
Brett Wilson 7e331f3aa0 Add chrome perf tests to GN build, fix harfbuzz
This also hooks up the chrome test support target which was previously not compiled (the file wasn't referenced).

This duplicates the harfbuzz logic from the GYP build where the system one is conditionally used if the pangoft2 version is sufficiently large. There are some additions to the pkg-config wrapper script to check versions.

Write a service_discovery_sniffer target but don't hook it up. Currently this gives linker errors.

Fix grit warnings for the remoting resources.

R=dpranke@chromium.org

Review URL: https://codereview.chromium.org/702903004

Cr-Original-Commit-Position: refs/heads/master@{#303489}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 32ce17ab53d97a66e50e7e49ef57e8fa9f881714
2014-11-10 17:46:17 +00:00
cmasone fbf385d4ba GN: Fix compile errors with os==chromeos mojo/public build
The big changes here are:
1) Allow injecting of a target toolchain via args for os==chromeos.
2) For ARM builds, allow injecting -mtune and -mfloat-abi settings.
3) Allow injecting a pkg-config wrapper that correctly handles the
   CrOS build environment. This is how pkg-config is handled for
   all other packages in the build.
4) Create libmojo_sdk target, a static library of public Mojo code
   suitable for distribution.
5) Added testonly = true to a few targets under mojo/ that are not
   meant to be used in production.

BUG=388412
TEST=Create a target that builds //mojo/public, build with os==chromeos

Review URL: https://codereview.chromium.org/549453004

Cr-Original-Commit-Position: refs/heads/master@{#296849}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 2c8e745d9c4de27b44f4d866a2bf0f0a880d9b8c
2014-09-26 01:28:15 +00:00
brettw@chromium.org dc4dfd1fd1 Add CC to the GN build, work on GPU more
BUG=
R=jamesr@chromium.org
TBR=piman

Review URL: https://codereview.chromium.org/300973003

git-svn-id: http://src.chromium.org/svn/trunk/src/build@273588 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2014-05-29 20:54:24 +00:00
brettw@chromium.org 696094c61a Add SSL support to the GN build
This moves files from the secondary tree to the main one, and renames the "meta" one to //crypto:ssl. It also adds the crypto unit tests.

R=rsleevi@chromium.org

Review URL: https://codereview.chromium.org/231673006

git-svn-id: http://src.chromium.org/svn/trunk/src/build@263744 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2014-04-14 23:25:13 +00:00
brettw@chromium.org 08fbbcc064 Pull GN @ r262225
Implement GN visibility in the build, which this new version implements

BUG=
R=scottmg@chromium.org

Review URL: https://codereview.chromium.org/217273004

git-svn-id: http://src.chromium.org/svn/trunk/src/build@262438 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2014-04-08 16:50:01 +00:00
brettw@chromium.org c8f200451d Update .gn files to use new template syntax.
This uses the invoker() syntax.

R=scottmg@chromium.org, scottmg

Review URL: https://codereview.chromium.org/212843007

git-svn-id: http://src.chromium.org/svn/trunk/src/build@260151 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2014-03-28 16:19:02 +00:00
brettw@chromium.org 22b3476400 Work on Clang for pure GN build.
This hooks up Clang in the pure GN build (not the hybrid GYP mode).

Clang gave some warnings about compiler flags which made me realize that we were giving linker flags to the compiler in some cases. So I enhanced our pkg-config wrapper to to add libraries to the cflags (missing else), return ldflags separately, and also strip out -pthread which was getting included over and over.

BUG=

Review URL: https://codereview.chromium.org/147923010

git-svn-id: http://src.chromium.org/svn/trunk/src/build@248477 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2014-02-03 12:11:38 +00:00
bbudge@chromium.org d9ea552975 GN: Get Mac build working for IPC target at least.
- Move sysroot.gni up a directory, as it applies to multiple
platforms now.
- Use existing find_sdk.py script to locate Mac SDK.
- Fix some gtest includes for Mac files.

BUG=
R=brettw@chromium.org

Review URL: https://codereview.chromium.org/116763005

git-svn-id: http://src.chromium.org/svn/trunk/src/build@243654 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2014-01-08 21:38:35 +00:00
brettw@chromium.org 6949c9d667 Add support for sysroots to GN's pkg-config.
This adds support similar to the GYP scripts for running pkg-config in the presence of sysroots.

It also adds the linker flags by calling the existing horrible sysroot_ld_path.sh shell script that extracts stuff from the sysroot's configuration.

With this change, official 32-bit linux builds work in the checked in 32-bit Debian sysroots.

R=piman@chromium.org

Review URL: https://codereview.chromium.org/116803003

git-svn-id: http://src.chromium.org/svn/trunk/src/build@241397 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2013-12-17 22:54:18 +00:00
brettw@chromium.org 8dfb008faa Separate out pkg-config execution in the GN build.
This makes a template to invoke the pkg-config script so that we can change how it's invoked in one place rather than in every call site.

BUG=
R=piman@chromium.org

Review URL: https://codereview.chromium.org/109443004

git-svn-id: http://src.chromium.org/svn/trunk/src/build@241068 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
2013-12-16 23:53:47 +00:00