2996 Commits

Author SHA1 Message Date
Casey Dahlin
9941dcc7aa First pass on reentrant C++-ish parser
We're flipping Flex/Bison in to reentrant mode, cutting down on global
variables, and exposing a more C++-like interface earlier. This is the first
phase. There's still a couple of weird hacks to deal with the previous code's
reckless disregard for scope sanity, but the outline of things to come is
starting to appear, and this CL really doesn't need to get any bigger.

Change-Id: Ife2d70db026d7ab1319bdf6c586959315666d0bb
Signed-off-by: Casey Dahlin <sadmac@google.com>
2015-09-10 16:55:18 -07:00
Dan Willemsen
8d6f9bf3c8 Whitelist windows module
Bug: 23566667
Change-Id: I030733ffd2b43a0ea74b0fd5f34a0d13ef8dcf7c
2015-09-04 14:22:17 -07:00
Christopher Wiley
b1db04f371 Merge "aidl: Add end to end test" 2015-09-02 21:10:30 +00:00
Christopher Wiley
b14e7b8429 Merge "aidl: Remove example test" 2015-09-02 21:10:09 +00:00
Casey Dahlin
d6b6b80cdb Delete outdated options tests
Bug: 23718807
Test: Re-ran make. Confirmed code was not linked.
Change-Id: If065b9287ed70b9e380281cae42f89bd5f1ffb06
Signed-off-by: Casey Dahlin <sadmac@google.com>
2015-09-02 13:34:26 -07:00
Casey Dahlin
ca4543cdba Remove RPC interface Type
AIDL previously supported "rpc" and "flatten" types, which are not used
anywhere in the Android tree. This patch removes them, which significantly cuts
down code and complexity.

Bug: 23517584
Test: Rebuilt AOSP tree against new version
Change-Id: I6cf38d43c1ce109ffca987cc14520945aa22431f
Signed-off-by: Casey Dahlin <sadmac@google.com>
2015-09-02 13:34:26 -07:00
Christopher Wiley
5ed76073a4 aidl: Add end to end test
This test sets up an artificial hierarchy of .aidl files, then
checks that the generated code contains a substring that we
know to be correct.  This isn't a very good unittest, but it does
validate that the whole flow works start to finish.

Bug: 23516947
Test: compiles, unit tests pass.

Change-Id: I931b7659731b05440040623e12596669604cef3a
2015-09-02 13:00:09 -07:00
Christopher Wiley
6d57207f37 aidl: Remove example test
We have enough tests demonstrating how to write them.

Bug: 23516947
Change-Id: I966cb6bb2d754db389be8f9b90957ac33cf66639
Test: Unittests pass.
2015-09-02 12:55:07 -07:00
Christopher Wiley
1ab54c12e3 aidl: Don't link librt on Mac
This fixes unittest build on Mac.

Change-Id: I5180f647d1b5b41f99c4d0423aaec9d05fee6355
2015-09-02 08:59:30 -07:00
Christopher Wiley
1006bfe09d aidl: Stop using Bionic's test main
This allows us to build unittests on Mac, where Bionic's test main
does not build.

Change-Id: I59c805d233498bb67575f2e5f7049341f70ce55c
2015-09-01 12:40:15 -07:00
Christopher Wiley
a25d35106e aidl: Separate aidl logic into its own static library
Compile aidl's logic into a static library that can be
linked against both the unittest binary and the executable. Validate
that this is working by writing a basic unittest against options
parsing.

Provide default values for Options struct members.  These were
previously taking on values according to the the bits in the memory
allocated to hold them for preprocessed inputs.

Bug: 23516947
Change-Id: Ib57cd7f473995f7851d788deac39f9c4d9018e8f
Test: compiles and unittests pass
2015-09-01 11:15:31 -07:00
Christopher Wiley
267cb88f4d Merge "Set up aidl for gtest" 2015-09-01 18:11:41 +00:00
Christopher Wiley
5b88363ed3 Tighten up compiler flags for aidl
Turn all warnings to errors, with special cases for places where
yacc forces us to be lenient.  Remove one variable with 0 references
elsewhere in the code.

These flags are confined to be clang only because the Windows SDK build
is using an older compiler that does not understand these flags.

Change-Id: I6407bd331c25b8845bde46e9a917bce1d6857bd8
2015-08-31 13:55:46 -07:00
Dan Willemsen
60dd5d5966 Merge "Remove USE_MINGW, whitelist windows modules" 2015-08-31 19:30:57 +00:00
Christopher Wiley
a73e004516 Merge "Revert "Tighten up compiler flags for aidl"" 2015-08-31 19:13:04 +00:00
Christopher Wiley
ecaf21c377 Revert "Tighten up compiler flags for aidl"
This reverts commit eea2353a3427f7d157c46e24ab6aba1378e16c2e.

This seems to have broken the build because whatever compiler the builder is using doesn't understand the same "turn off this warning" flags as my local host's compiler.

Change-Id: Ic68b7065b161a5ae683b7082c67147835833e0fa
2015-08-31 19:07:40 +00:00
Christopher Wiley
2f77417cce aidl: Pull main() into dedicated file
This separates the main() entry point from the functionality we're
hoping to test.  While here, redo the header guards to be consistent
accross the codebae.

Bug: 23516947
Change-Id: I61666126bdba0941f14bd0f031caaa30367b864a
Test: Compiles
2015-08-31 10:54:26 -07:00
Christopher Wiley
eea2353a34 Tighten up compiler flags for aidl
Turn all warnings to errors, with special cases for places where
yacc forces us to be lenient.  Remove one variable with 0 references
elsewhere in the code.

Change-Id: Ia7819795eb162e9c77d215088aee4c45bd87c1af
2015-08-30 11:01:31 -07:00
Casey Dahlin
8a8775c1db Set up aidl for gtest
Bug: 23516947

Change-Id: I1c004868525f462d04894a7b96c671b626061ab5
Signed-off-by: Casey Dahlin <sadmac@google.com>
2015-08-28 16:21:53 -07:00
Dan Willemsen
4aa679ff96 Remove USE_MINGW, whitelist windows modules
Bug: 23566667
Change-Id: Ie6b8c51e2b6d6273f99f4e361c440136d7c6915c
2015-08-28 15:28:26 -07:00
Christopher Wiley
1eaa9ed334 Do not merge namespaces
It is good practice to not include the whole std:: namespace into
the global namespace.  This is doubly true in headers.

TEST=aidl compiles

Change-Id: I910ca8082f61cce4f23f8564b8a12c2828b75b3c
2015-08-24 14:28:36 -07:00
Elliott Hughes
e17788ceff Replace HAVE_MS_C_RUNTIME with _WIN32 in frameworks/base/tools.
Change-Id: Ideef62acbf53a442167c9b8038021affffef9e8a
2015-08-17 12:41:46 -07:00
Elliott Hughes
ba3fe56edc Lose HAVE_ANDROID_OS from frameworks/base.
Change-Id: I713881fdbaec7cbbb5e7f2f4be6f9b8be3d2ca4e
2015-08-12 14:49:53 -07:00
Yusuke Sato
158560ad66 Merge "Distinguish user-requested shutdown from power-related ones" 2015-07-31 23:13:16 +00:00
Yusuke Sato
705ffd1efe Distinguish user-requested shutdown from power-related ones
With this patch, when the user requested shutdown,
PowerManagerService sets sys.powerctl is set to
"shutdown,userrequested", and init runs fsck on shutdown.

When shutdown is triggered due to a low power state etc.,
the service sets the property to "shutdown,", and init
immediately shuts down the system without running the
command.

This is a follow-up CL for http://r.android.com/158525.

Bug: 21853106
Change-Id: Iae72990130fe9aa479c802f77301438190dbbfb3
2015-07-30 23:47:13 -07:00
Elliott Hughes
9ec96f9756 Move frameworks/base/tools/ off AndroidConfig.h.
Change-Id: Ibc7abb67a56945a9618bc91ccdbebe4c806879a5
2015-07-29 14:35:18 -07:00
Elliott Hughes
98c11b511a Use _WIN32 rather than HAVE_WINDOWS_PATHS.
Change-Id: Ib1ae71dfbb20e3e5309ed737f48382cc42d2583f
2015-07-29 08:44:17 -07:00
Ying Wang
430c8c3e48 Merge "Add phony source target in the generated dependency file of aidl." 2015-07-24 00:38:08 +00:00
Colin Cross
01efd7e820 Merge "Use build_number from file" 2015-07-23 18:23:06 +00:00
Ying Wang
50fb02da53 Add phony source target in the generated dependency file of aidl.
This fixes make error when the source .aidl file is moved around but
its path relative to LOCAL_PATH doesn't change.

Bug: 22666539
Change-Id: Idf2492145e4927779d184932a09d61e4fe8ded0f
2015-07-22 17:49:56 -07:00
Elliott Hughes
b48adad2ed aapt: expat exports its header files now.
(cherrypick of 51348d2007b801c7bd7350f72e2300f1a5a41dd1)
Change-Id: Iddf0133919d38fc896f97c6796f8228a6decf174
2015-07-21 17:25:01 -07:00
Colin Cross
06e04f7671 Use build_number from file
Improve incremental ninja builds by keeping the command line the same
across builds.

Change-Id: If9dfcee74a4d282c183f9669e14a89104c115a71
2015-07-21 12:55:13 -07:00
Elliott Hughes
ba7e659b55 Revert "frameworks/base: libexpat now exports its headers."
This reverts commit 2f31b66c04b1e80fd039418edf41e74f67b68143.

Change-Id: Ib4ce610d1767db5c72c54d33520e8bdf50171a18
2015-07-11 01:07:39 +00:00
Elliott Hughes
2f31b66c04 frameworks/base: libexpat now exports its headers.
Change-Id: Iaba3d57db18ebdd89e4a993436e9bf844722ff87
2015-07-10 11:12:22 -07:00
Igor Viarheichyk
cbb1e676b5 ICU format support for pseudolocalizes.
Custom parser can handle nested ICU messages even if they
are split into multiple fragments. Code reworked to encapsulate
all pseudolocalization logic in Pseudolocalizer and PseudoMethods
classes. To minimize a changelist size, some static functions
remained. Fake BiDi pseudolocalization method is reimplemented
to handle word boundaries correctly. Unit tests added.

Change-Id: I9fb4baf4e3123df5dd6d182cca02bb7b0489ca71
2015-06-09 11:28:20 +01:00
Chih-Hung Hsieh
97627314a4 Remove unused aapt target.
BUG: 20765163
Change-Id: I13f36f76541216c5c1c20ae8866e09038e08e6f8
2015-05-04 15:49:46 -07:00
Narayan Kamath
9c8ba9666d Add a static dependency on libbase.
Used by libziparchive.

Change-Id: I120494b620c72b36a725b01f1f274f5dc862a9a3
2015-04-29 14:07:41 +00:00
Adam Langley
6bf52c4271 frameworks/base: switch to using NativeConstants.
NativeCrypto is a conscrypt class that contained several OpenSSL
constants. NativeConstants is the new class that contains the same
thing, but the latter is automatically generated and thus won't drift
from the C headers.

Bug: 20521989

Change-Id: I45c7b9a6844a06e3ffd09be692ebf733e1ebbbcc
2015-04-24 10:00:45 -07:00
Colin Cross
1be312dfb0 Merge "Re-enable -Wall and -Werror that were lost in a merge" 2015-04-09 00:49:56 +00:00
Colin Cross
01f185633c Re-enable -Wall and -Werror that were lost in a merge
-Wall and -Werror were lost during a merge when they were added to
aaptCFLAGS instead of aaptCFlags.  Fix the typo, and the warnings
that crept in while it was disabled.

Change-Id: Ib944b8d6149278e4f3861c1acac277bcd95cc7c2
2015-04-08 17:48:23 -07:00
Elliott Hughes
b12f2410c7 Only Windows doesn't have %zd.
Change-Id: I0e4b0fdc61641c5ecb724fd096bd2315dcf8ed4a
2015-04-03 12:56:45 -07:00
Elliott Hughes
e519c81f35 Remove unused printapk.cpp.
This is one of the few remaining users of libzipfile, but doesn't get built.
Not worth porting to libziparchive.

Change-Id: Ica466b22e3a7ebaf123727c0d703af39cc89cf9c
2015-03-19 09:03:41 -07:00
Dan Albert
f8d6a4ba87 resolved conflicts for merge of 701f9c2f to stage-aosp-master
Change-Id: I42e0411c0acef4b15137491ecaaed95d9b1cd0c1
2015-03-05 15:41:39 -08:00
Dan Albert
030f536009 Stop using namespace std.
The pattern of #include and using namespace std here fails to build
with GCC. At first glance it's a GCC bug rather than libc++ doing
something wrong. Regardless, it can be worked around by just
specifying std:: where appropriate.

Bug: 19606303
Change-Id: I5652682eae7ca7559cf2a9307909859013440781
2015-03-04 13:54:20 -08:00
Chris Warrington
4308c2aea4 am 510c24e8: Merge "Fix AAPT daemon mode with paths containg spaces." into lmp-mr1-dev
automerge: 4499888

* commit '449988872be61f273c91db13069d5b7172429032':
  Fix AAPT daemon mode with paths containg spaces.
2015-02-10 20:14:44 +00:00
Chris Warrington
de3ab0a9e8 Fix AAPT daemon mode with paths containg spaces.
Use new line as a delimiter rather than space.
Fixes: https://code.google.com/p/android/issues/detail?id=135757
Gradle CL: https://android-review.googlesource.com/130423

Change-Id: I7c73e680b0417b0e7cff9e0110822675c53ae20f
2015-02-09 21:20:52 -08:00
Deepanshu Gupta
df5a198710 am 3d5535cf: Merge "Limited AppCompat support" into lmp-dev automerge: 7789447 automerge: 580937f
automerge: c053438

* commit 'c05343828611ed0b82fae4edf7fe11e0e9087db1':
  Limited AppCompat support
2015-01-31 04:18:58 +00:00
Deepanshu Gupta
6a439908fc am 1d59871e: Merge "Resource resolution fixes." into lmp-dev automerge: 7e683bd automerge: 1575ca6
automerge: 862cdd6

* commit '862cdd6f11490c060842599a58a400e284c937d9':
  Resource resolution fixes.
2015-01-31 04:17:35 +00:00
Deepanshu Gupta
580937fc45 am 3d5535cf: Merge "Limited AppCompat support" into lmp-dev
automerge: 7789447

* commit '7789447bd97c851b7a09623a417300590e5439d5':
  Limited AppCompat support
2015-01-31 03:02:42 +00:00
Deepanshu Gupta
1575ca6e1a am 1d59871e: Merge "Resource resolution fixes." into lmp-dev
automerge: 7e683bd

* commit '7e683bdaddff77a24a36d420c5782b47795c5ccb':
  Resource resolution fixes.
2015-01-31 03:01:20 +00:00