Commit Graph

1786 Commits

Author SHA1 Message Date
Dan Willemsen
f05b4b634e Remove [local_]include_files am: cd114c1cb7
am: 4ae64644f1

* commit '4ae64644f1eb0b469fb281f2153f9acc8b088c89':
  Remove [local_]include_files

Change-Id: Idd9c7fec804dd2340d10a406d4772ed44d4bc50f
2016-05-26 23:29:46 +00:00
Dan Willemsen
4ae64644f1 Remove [local_]include_files
am: cd114c1cb7

* commit 'cd114c1cb707cb205ddf07e96bb61d97dfee5018':
  Remove [local_]include_files

Change-Id: Ia81168c60b0f1235f16742a23ffbb4b0c5bd6089
2016-05-26 23:27:14 +00:00
Dan Willemsen
cd114c1cb7 Remove [local_]include_files
We don't actually need to do any changes to the path for the include
files, so we can just rely on the include_dir search to work.

It would still be useful to verify that the path isn't something bad,
like an absolute path, but we'll handle that by looking at the cflags in
another change.

Change-Id: I0bd609435969191c4ff91f2cd06eccfb75f5097c
2016-05-26 23:09:46 +00:00
Dan Willemsen
81d0bec0df Export TARGET_TOOLCHAIN_ROOT am: 0bd588787b
am: f56a2b16f8

* commit 'f56a2b16f8346518f365f8410b25856a5bc72913':
  Export TARGET_TOOLCHAIN_ROOT

Change-Id: Idd3fba44cf7910b97192a9b9b8ec57b2ad6a2cba
2016-05-26 22:43:26 +00:00
Dan Willemsen
f56a2b16f8 Export TARGET_TOOLCHAIN_ROOT
am: 0bd588787b

* commit '0bd588787bac1d6add436f42a35359bee423b4d3':
  Export TARGET_TOOLCHAIN_ROOT

Change-Id: I0b93aa87530a29def050b1cfabde2cd11787b41d
2016-05-26 22:40:41 +00:00
Dan Willemsen
0bd588787b Export TARGET_TOOLCHAIN_ROOT
This is still used by brillo to find GCC for the kernel build.

Change-Id: I19238b1cc9c4220224048afebbdf6032015c3e89
2016-05-26 15:23:07 -07:00
Colin Cross
fc6e6e2bee Improve makefile parser am: 08693d2bf2 am: 21b30618ae
am: d03eb60d23

* commit 'd03eb60d2326698b9f7bb18fe885dc69d28ccecb':
  Improve makefile parser

Change-Id: I9934589b5d3b470398244a9556552a838b2f236b
2016-05-26 17:36:14 +00:00
Colin Cross
952d873b32 Fix blank line translation once and for all am: 7fd911f713 am: 26ab50e98d
am: 0c738b70e5

* commit '0c738b70e57d87ded8914fb0168348b780408af5':
  Fix blank line translation once and for all

Change-Id: I62bd34e51045b12c566ed1c97aea01eb4efef8a5
2016-05-26 17:36:08 +00:00
Colin Cross
d03eb60d23 Improve makefile parser am: 08693d2bf2
am: 21b30618ae

* commit '21b30618ae3633491deee09decbca92b05ac3993':
  Improve makefile parser

Change-Id: If0d95586af952280be210028a4a849fe7c4afc9a
2016-05-26 17:00:07 +00:00
Colin Cross
0c738b70e5 Fix blank line translation once and for all am: 7fd911f713
am: 26ab50e98d

* commit '26ab50e98d344809df349a0f87805ef67f86de21':
  Fix blank line translation once and for all

Change-Id: Ida205a5db5cfabeb27d5144e5916d7dce48cee66
2016-05-26 17:00:05 +00:00
Colin Cross
21b30618ae Improve makefile parser
am: 08693d2bf2

* commit '08693d2bf26e443bf9e0303b91a7cfc7e7e27e65':
  Improve makefile parser

Change-Id: If9f5b7123fad0216298b2140352b249737d1a9a6
2016-05-26 16:50:05 +00:00
Colin Cross
26ab50e98d Fix blank line translation once and for all
am: 7fd911f713

* commit '7fd911f713937029ec9a61602b2086c05a672b96':
  Fix blank line translation once and for all

Change-Id: Ie7188b30447830bda3b7a496a6519e60b2a4ca50
2016-05-26 16:49:59 +00:00
Colin Cross
7692542afb Merge "Fix non-deterministic errors with LOCAL_*_x86_64" am: ad14e6e227 am: 95879d5b51
am: 8aee9c7b48

* commit '8aee9c7b4857b0ed4e1893ec3e4c53a4a2a69ed6':
  Fix non-deterministic errors with LOCAL_*_x86_64

Change-Id: I643ffd7113b77b986bb4a15c939f6d91c2227f6f
2016-05-26 03:40:06 +00:00
Colin Cross
08693d2bf2 Improve makefile parser
Improve the androidmk makefile parser based on ideas from go/ast and
friends:
   - Use type switching instead of the As* mess
   - Don't store endPos for every node, compute it based on the last
     known position in the node plus the length of the last token
   - Store positions as only the offset into the file, and then unpack
     them into Line/Column scanner.Position objects later

Change-Id: I87eb6661859951e6c2ea5a85db6229fa5561d615
2016-05-26 03:34:30 +00:00
Colin Cross
7fd911f713 Fix blank line translation once and for all
Track the position in the input makefile and output blueprint file
separately.  When parsing a new makefile line, increment the line in the
output position by the number of lines between the end of the last
makefile line and the beginning of this line.  Any extra blank lines
will be discarded by the blueprint printer.

Change-Id: I85c6e006667b5733b15e03b56b91caf29fbc0ea0
2016-05-26 03:34:17 +00:00
Colin Cross
8aee9c7b48 Merge "Fix non-deterministic errors with LOCAL_*_x86_64" am: ad14e6e227
am: 95879d5b51

* commit '95879d5b51ce847bc60b7448641fffce617afbc0':
  Fix non-deterministic errors with LOCAL_*_x86_64

Change-Id: I09f2416293aba18fd2faeeb16e2ef4406dab3b38
2016-05-26 03:30:56 +00:00
Colin Cross
95879d5b51 Merge "Fix non-deterministic errors with LOCAL_*_x86_64"
am: ad14e6e227

* commit 'ad14e6e2279a196366c43f9a58f46d6201d29d70':
  Fix non-deterministic errors with LOCAL_*_x86_64

Change-Id: Ia56b3affe0ab8e1ff64d9574ad311fd8e6782c30
2016-05-26 03:20:41 +00:00
Treehugger Robot
ad14e6e227 Merge "Fix non-deterministic errors with LOCAL_*_x86_64" 2016-05-26 03:06:08 +00:00
Dan Willemsen
c2a4c12299 Add flag property checking am: 20acc5c520 am: 7c0e27d309
am: 5baea967fa

* commit '5baea967fa7ddc5c2b6e4423411211f2b2cdf0d8':
  Add flag property checking

Change-Id: I7e94b7d250cc688a6810364fe2936e675d6c60e7
2016-05-26 02:43:31 +00:00
Dan Willemsen
5baea967fa Add flag property checking am: 20acc5c520
am: 7c0e27d309

* commit '7c0e27d3098420776981e103fb94ce7141e19707':
  Add flag property checking

Change-Id: Idd248aec69a65264cb18c8ca96442b4bb913d12d
2016-05-26 02:29:42 +00:00
Dan Willemsen
7c0e27d309 Add flag property checking
am: 20acc5c520

* commit '20acc5c520c8d6021824b3f839000db45be36a6e':
  Add flag property checking

Change-Id: Ia9c635286974db0a363bfbc99c6366781ce12914
2016-05-26 02:18:16 +00:00
Dan Willemsen
20acc5c520 Add flag property checking
Some checks for common errors with user-provided compiler and linker
flags:

* Using -I instead of include_dirs
* Using -l<lib> in ldflags instead of host_ldlibs (or shared_libs)
* Using -L in ldflags
* Splitting a multi-word flag into two flags
* Combining two flags into one list entry
* Using a path that could search outside the source or output trees
* Using a non-whitelisted library in host_ldlibs

Maybe some of the flag checks should happen during a static analysis
pass, but we don't have one right now, and this only adds ~1/2 second to
our 73 second Mega_device runs (recompile the changed code, run
soong_build, then report unknown target).

Change-Id: Icea7436260f1caa62c0cec29817a1cfea27b3e7c
2016-05-25 17:50:05 -07:00
Colin Cross
ab6e6e0135 Fix non-deterministic errors with LOCAL_*_x86_64
LOCAL_*_x86_64 was sometimes recognized as a _64 suffix and other times
as the correct _x86_64 suffix, based on the random order of the
propertyPrefixes map.  Replace the map with a slice so that the ordering
is consistent, and ensure 64 as after x86_64.

Change-Id: I1a4b4959f8ef4273ad4a1cdd0672ad557bf1891e
2016-05-25 17:17:40 -07:00
Colin Cross
dd3976daa7 Fix sanitize host builds am: b36ab1a1a0 am: ef6073265b
am: 0f8af7b05f

* commit '0f8af7b05f2c21ea6e9f421bc61470029575e89c':
  Fix sanitize host builds

Change-Id: I852918d29e7ad51e634605e497aedd2d17344b25
2016-05-25 19:54:39 +00:00
Colin Cross
0f8af7b05f Fix sanitize host builds am: b36ab1a1a0
am: ef6073265b

* commit 'ef6073265bb5fb164eaf5cc981db7b2dd915dfae':
  Fix sanitize host builds

Change-Id: I3faf7520a77c31c30b30c454d9586c36781849f9
2016-05-25 19:50:06 +00:00
Colin Cross
ef6073265b Fix sanitize host builds
am: b36ab1a1a0

* commit 'b36ab1a1a0355d15d692e2b6ff5955cae1275174':
  Fix sanitize host builds

Change-Id: If49c199b05902d2662472a3e99903104b2839a2e
2016-05-25 19:45:49 +00:00
Colin Cross
50d1f282c6 Support sanitizer variants inside make builds am: bc6fb16b26 am: 991008ce19
am: 390f076154

* commit '390f0761548a8492233c733e93773c9f92eb7f1a':
  Support sanitizer variants inside make builds

Change-Id: Ia5462a100077f008d4f23e84827fee0881eea3c8
2016-05-25 19:37:53 +00:00
Colin Cross
b36ab1a1a0 Fix sanitize host builds
Host builds don't have a separate place to install asan modules, so only
create a single variant for them.

Change-Id: I81f7090debd7935db778f8600d8cbc86dd53b1cb
2016-05-25 12:35:53 -07:00
Colin Cross
390f076154 Support sanitizer variants inside make builds am: bc6fb16b26
am: 991008ce19

* commit '991008ce19f63117f72553d8d46f21304342d8f9':
  Support sanitizer variants inside make builds

Change-Id: I646ce88d295f8090602860fe514fcd71debe4601
2016-05-25 19:33:13 +00:00
Colin Cross
991008ce19 Support sanitizer variants inside make builds
am: bc6fb16b26

* commit 'bc6fb16b26dedee0e9f10239cb9a6c8a3e647b04':
  Support sanitizer variants inside make builds

Change-Id: I5c75ac2dcc8a11eba3155e0d1d382edb176e8de7
2016-05-25 19:29:07 +00:00
Colin Cross
bc6fb16b26 Support sanitizer variants inside make builds
Create both sanitized and unsanitized variants inside make builds with
sanitizers enabled.  Only export the sanitized version to make, and
always install the sanitized version in /data to match the make build.

Change-Id: I5a17bcbddc7a9d871c929c84d3c116228ef3258f
2016-05-24 17:14:15 -07:00
Dan Willemsen
7dca6945ce Stop sorting (C|CPP|LD)FLAGS when checking am: 9598e1048a am: a897cbfd33
am: d6e7df3545

* commit 'd6e7df354584dcc95961498b7a279dd6330203df':
  Stop sorting (C|CPP|LD)FLAGS when checking

Change-Id: I1cf98161a71394537c0dce78e76175d3851f6b5e
2016-05-24 01:14:30 +00:00
Dan Willemsen
d21dcb7477 Fix and check CLANG_CONFIG_UNKNOWN_CFLAGS am: e8c5237775 am: c99fc3d097
am: f1a1389e65

* commit 'f1a1389e65bd8dc0e76080ab0b3c78e4a142f0e2':
  Fix and check CLANG_CONFIG_UNKNOWN_CFLAGS

Change-Id: I7b582fde7082c89b1b2a42121b4c6c6c24f98b58
2016-05-24 01:14:29 +00:00
Dan Willemsen
d6e7df3545 Stop sorting (C|CPP|LD)FLAGS when checking am: 9598e1048a
am: a897cbfd33

* commit 'a897cbfd3399cd93bf2bb87a8aa6cef5bcd2a750':
  Stop sorting (C|CPP|LD)FLAGS when checking

Change-Id: I9f5f85edcfb5708d9b375e3e6fa4a46bf369bf15
2016-05-24 01:11:41 +00:00
Dan Willemsen
f1a1389e65 Fix and check CLANG_CONFIG_UNKNOWN_CFLAGS am: e8c5237775
am: c99fc3d097

* commit 'c99fc3d097eb72e4045d935bbd2997ce39d928df':
  Fix and check CLANG_CONFIG_UNKNOWN_CFLAGS

Change-Id: I1085f05f212c9165e5026efe9886d4a152a0ea45
2016-05-24 01:11:41 +00:00
Dan Willemsen
a897cbfd33 Stop sorting (C|CPP|LD)FLAGS when checking
am: 9598e1048a

* commit '9598e1048a890810fc35b9655ee603a6994e8665':
  Stop sorting (C|CPP|LD)FLAGS when checking

Change-Id: I04fc04fb2d019777d68c26262c6636fb6b18d806
2016-05-24 01:09:14 +00:00
Dan Willemsen
c99fc3d097 Fix and check CLANG_CONFIG_UNKNOWN_CFLAGS
am: e8c5237775

* commit 'e8c5237775f413bbb56084e19054a3d979e15985':
  Fix and check CLANG_CONFIG_UNKNOWN_CFLAGS

Change-Id: I3725569bc11883534d4a41035d91a9599200a756
2016-05-24 01:09:13 +00:00
Dan Willemsen
9598e1048a Stop sorting (C|CPP|LD)FLAGS when checking
Make isn't defining these anymore, so we don't need to sort them before
comparing.

Change-Id: Ia2f13f665309569ee8c564a8fb82639d174a83bb
2016-05-23 15:15:13 -07:00
Dan Willemsen
035a9a3107 Check more Make variables am: 558e517ae9 am: e9b7ce1d10
am: 637583fc52

* commit '637583fc5271116cfc12ad8bab709f5aea8d8f9b':
  Check more Make variables

Change-Id: I60775a6c8046925412789e6f1a5a42ddf5093d11
2016-05-23 19:37:21 +00:00
Dan Willemsen
637583fc52 Check more Make variables am: 558e517ae9
am: e9b7ce1d10

* commit 'e9b7ce1d10210ddd79e060f182c38f9699508dc1':
  Check more Make variables

Change-Id: Iaf0c1e05c7c4bf00ff94b80a5cc526af70e1da71
2016-05-23 19:34:37 +00:00
Dan Willemsen
e9b7ce1d10 Check more Make variables
am: 558e517ae9

* commit '558e517ae99d018305a45da6f46ee2a53f47c928':
  Check more Make variables

Change-Id: I6d661d3815302209bf158feaa9f1bb1094b10e12
2016-05-23 19:31:30 +00:00
Dan Willemsen
e8c5237775 Fix and check CLANG_CONFIG_UNKNOWN_CFLAGS
Change-Id: Id8d4ab5e7bf7c9ed161596c19ccdfe00aaa2f7c6
2016-05-20 00:19:14 -07:00
Dan Willemsen
558e517ae9 Check more Make variables
Some more common makevars methods were required in order to remove the
"-isystem" prefixes from the toolchain.IncludeFlags() value. In Make,
the -isystem is prepended at time of use, not in TARGET_C_INCLUDES
itself.

Change-Id: If07e69ddb7357d11c7dd48ab60f503d219f29de8
2016-05-20 00:19:14 -07:00
Colin Cross
b1cdcb8759 Add libclang_rt.asan-mips[64]-android.so am: d87145fe05 am: 9deacc3cc5
am: 23175b8661

* commit '23175b86612fdb3884db2d5ca77ee725a0d70ea3':
  Add libclang_rt.asan-mips[64]-android.so

Change-Id: Ieb863e3103d43401b543f6c4bc635b63c99f7877
2016-05-20 07:13:18 +00:00
Colin Cross
23175b8661 Add libclang_rt.asan-mips[64]-android.so am: d87145fe05
am: 9deacc3cc5

* commit '9deacc3cc5b74204e9fe100fbbe84fcb7dbab3a1':
  Add libclang_rt.asan-mips[64]-android.so

Change-Id: I0ff10e53f87367fd16f43a4ed45609ebfc302fef
2016-05-20 07:10:38 +00:00
Colin Cross
9deacc3cc5 Add libclang_rt.asan-mips[64]-android.so
am: d87145fe05

* commit 'd87145fe0560f8a5f6a1b5d0e90c8dde30ee66cb':
  Add libclang_rt.asan-mips[64]-android.so

Change-Id: I840e3608be5e561c1c8b61b9fccd384b1704851d
2016-05-20 07:07:47 +00:00
Colin Cross
d87145fe05 Add libclang_rt.asan-mips[64]-android.so
Add the clang asan runtime libraries to the mips and mips64 toolchain
definitions.  Fixes missing symbol build errors on asan_test.

Change-Id: I10c46599af2c7758f4726814920b8881644c6f97
2016-05-19 22:43:46 -07:00
Dan Willemsen
39317638f6 Fix makevars (C|LD)FLAGS ordering am: d26a713dca am: 1866cb4290
am: 9139e19dfd

* commit '9139e19dfdbb9609e3bb42f1b9bfec15fc681283':
  Fix makevars (C|LD)FLAGS ordering

Change-Id: Id057b36012ad9b8b6f35853ff5bc9ae4219463f0
2016-05-19 18:44:10 +00:00
Dan Willemsen
8936b5ff17 Move -msoft-float to ToolchainCflags am: c264c16638 am: 2c979349fa
am: 14776e92f0

* commit '14776e92f03d0683fef0559f838ddd2c98e784bd':
  Move -msoft-float to ToolchainCflags

Change-Id: I977b4e29c58949676709f38954959512f016f4b4
2016-05-19 18:44:09 +00:00
Dan Willemsen
9139e19dfd Fix makevars (C|LD)FLAGS ordering am: d26a713dca
am: 1866cb4290

* commit '1866cb4290ccf564abac8755961156a11c0dd5e1':
  Fix makevars (C|LD)FLAGS ordering

Change-Id: Ief4d0886f4dc9224f35842e6361f967aae39cfea
2016-05-19 18:36:36 +00:00