268 Commits

Author SHA1 Message Date
Iliyan Malchev
64ef6b47e0 add -ldl to host executables
This fixes the build on Linux when RefBase is compiled with reference tracking
enabled.

Change-Id: I3e931e0b463ce836f6fdb30c37068d77144631a3
Signed-off-by: Iliyan Malchev <malchev@google.com>
2011-10-20 16:21:25 -07:00
Dianne Hackborn
bd9d2bcdeb Whoops, remove left-over debug output.
Change-Id: Ib30571b22a6750629f975319a403d38de5e9462c
2011-10-16 14:17:07 -07:00
Dianne Hackborn
e6b680364d New aapt feature to do smarter filtering of configurations.
This adds a --preferred-configurations flag that specifies the
specific configurations you would like to have.

It is smarter than "-c" because it will avoid stripping a
configuration if that would result in there being no value
for the resource.

It is dumber than "-c" because it can't process as many kinds
of resources.  It is really only intended for bitmaps and use
with density configs.

This required re-arranging AaptAssets to group files together
by config again, like they used to be.  I think this hasn't
broken anything.  Hopefully.

Change-Id: I4e9d12ff6e6dbd1abb8fd4cb1814c6674b19d0e5
2011-10-16 11:52:17 -07:00
Kenny Root
56088a55ca Add package-verifier to aapt dump badging
Print out the package-verifier information when printing out badging.

Change-Id: I9c79c163261d5d4f1094bda76d90b3ff6e1ce540
2011-09-29 13:49:48 -07:00
Eric Fischer
914f7e683a Don't lose product variant strings that also vary between locales.
Localized strings with product variants were not being included in the APK,
apparently because the check to ensure that a different variation of the
string had not already been included in the APK was matching the version
of it from the default, untranslated configuration.

Now check to make sure that the string not only exists but also exists in
the correct configuration.

Bug 5372711

Change-Id: I52975570b75e0f11827dc6bcf1cb4a987d0541aa
2011-09-27 16:09:41 -07:00
Xavier Ducrohet
1797d6086f am d98e1be2: am f4750724: am 9d829f98: am 21e6e2de: Merge "Change generated dependency file names"
* commit 'd98e1be20e1cca5c36c7e0344500d4a5574568aa':
  Change generated dependency file names
2011-08-18 14:51:43 -07:00
Xavier Ducrohet
d98e1be20e am f4750724: am 9d829f98: am 21e6e2de: Merge "Change generated dependency file names"
* commit 'f4750724cf8db972a052cb388dc9a39fc7aa6dd6':
  Change generated dependency file names
2011-08-18 14:48:49 -07:00
Josiah Gaskin
b711f3f7ee Change generated dependency file names
This changes the name of the generated dependency files to R.java.d
and <ApkName>.ap_.d respectively.

Change-Id: I17e18770fc0d0a5d31c7b37b40ac1949f45ef13a
2011-08-16 08:14:51 -07:00
Xavier Ducrohet
395c86f7f6 am 6abf2f50: am 0b45ca88: am cd01ad7c: am 20339b24: Merge "Remove Debug Code"
* commit '6abf2f501e60132a5369ad5b15b388912c8e9e5b':
  Remove Debug Code
2011-07-27 18:43:32 -07:00
Xavier Ducrohet
6abf2f501e am 0b45ca88: am cd01ad7c: am 20339b24: Merge "Remove Debug Code"
* commit '0b45ca8884acfd2e9ccdcb3fbe641a46b116bda0':
  Remove Debug Code
2011-07-27 18:40:49 -07:00
Josiah Gaskin
7a09ccfb50 Remove Debug Code
This change removes debugging code from FileFinder.
This code was considered harmful because it uses the std::cout
from <iostream>.

Change-Id: Iad9b5e8a631883bd4854abdb29bc6df8a5b4a056
2011-07-27 17:45:32 -07:00
Kenny Root
af2872d1e3 Change ZipFile flags anonymous enum
The arguments that ZipFile takes were apparently meant to be a typed
enum, but the name of the type was taken out because it creates invalid
conversion warnings in C++ since this is an invalid use of enum.

Just change the typedef enum to an anonymous enum so we get rid of the
compiler warnings. It will be implicitly converted to int instead.

Change-Id: Ie72c4c235c8f9ee8fd1b795e1010b77c55e983de
2011-07-25 16:49:17 -07:00
Xavier Ducrohet
3a8801e059 am b3ab070e: am 3a2d1c23: am ddb8e3b2: am 9bac0a9f: Merge "Fix to compile for windows"
* commit 'b3ab070edb17f00a4b2d0f511ca539c885b28b6f':
  Fix to compile for windows
2011-07-20 18:56:52 -07:00
Xavier Ducrohet
b3ab070edb am 3a2d1c23: am ddb8e3b2: am 9bac0a9f: Merge "Fix to compile for windows"
* commit '3a2d1c2351c0b4eeb4dc4d91d1c334b9f8ba00ed':
  Fix to compile for windows
2011-07-20 18:55:21 -07:00
Josiah Gaskin
9102165fd8 Fix to compile for windows
This change includes a workaround for dirent.h on windows not
including d_type.

Change-Id: Ieaa3f298d2e6b32f2d8367384a1d02a2f5d06cca
2011-07-20 18:22:26 -07:00
Xavier Ducrohet
ac1fe6f846 am 84be06e4: resolved conflicts for merge of ea9e6d24 to honeycomb-plus-aosp
* commit '84be06e4ce0778fbf0c1ac72f94795ef8433439b':
  Added Caching for PreProcessed PNGs
2011-07-20 17:49:26 -07:00
Xavier Ducrohet
84be06e4ce resolved conflicts for merge of ea9e6d24 to honeycomb-plus-aosp
Change-Id: I8e047147a4d2c899b6654c03a5f32b04d929e602
2011-07-20 17:45:11 -07:00
Xavier Ducrohet
e53365f6f1 am a125c937: resolved conflicts for merge of 2c311be7 to honeycomb-plus-aosp
* commit 'a125c937de06b1cc43368743592f47513eb88b76':
  Add generation of dependency file for .ap_ package
2011-07-20 17:18:04 -07:00
Xavier Ducrohet
a125c937de resolved conflicts for merge of 2c311be7 to honeycomb-plus-aosp
Change-Id: I806c7b4ae95f66df621587e52497dd8739a115fe
2011-07-20 16:31:25 -07:00
Josiah Gaskin
8a39da80b3 Added Caching for PreProcessed PNGs
Added a cache management system for pre-processed PNG files
along with unit tests. The cache system will be used if
the --no-crunch flag is passed to AAPT during the package
phase. The cache can be updated by a call to 'aapt crunch'
(see usage statement). Also put in benchmarking code.

Change-Id: I58271fb2ee2f5f9075fd74d4ff6f15e7afabd05c
2011-07-20 15:20:26 -07:00
Xavier Ducrohet
c810fffe1f am 9139868b: am ba6c98db: am 82943ecf: am d40c93f6: Merge "Add dependency generation to Aapt for R.java"
* commit '9139868b6c5cb29b3665984225dceb0193fec31d':
  Add dependency generation to Aapt for R.java
2011-07-19 10:23:19 -07:00
Xavier Ducrohet
e242042b81 am bf31250b: am d5431ed5: am 2e659ae5: am 42755155: Merge "Copy once-created R.java into library projects"
* commit 'bf31250ba0858a2e72a3906a1f0216846683bc2e':
  Copy once-created R.java into library projects
2011-07-19 10:23:16 -07:00
Xavier Ducrohet
9139868b6c am ba6c98db: am 82943ecf: am d40c93f6: Merge "Add dependency generation to Aapt for R.java"
* commit 'ba6c98db8f21016f81ecac35bb0ea3c433044bb7':
  Add dependency generation to Aapt for R.java
2011-07-19 10:18:28 -07:00
Xavier Ducrohet
bf31250ba0 am d5431ed5: am 2e659ae5: am 42755155: Merge "Copy once-created R.java into library projects"
* commit 'd5431ed5505a42e5e33c8bf7cc2ff72792979be9':
  Copy once-created R.java into library projects
2011-07-19 10:18:25 -07:00
Josiah Gaskin
03589cc653 Add generation of dependency file for .ap_ package
Make Aapt generate a dependency file in the same directory as the
output ap_ file if the --generate-dependencies flag is set.
This dependency file can then be read by the ant exec loop task
to see whether to repackage resources.

Change-Id: I763679414daf76369700aa599c26dcf78d4de099
2011-07-18 16:37:55 -07:00
Josiah Gaskin
9bf34ca6f8 Add dependency generation to Aapt for R.java
Make Aapt generate a dependency file in the location specified
by RClassDir for R.java if the --generate-dependencies flag is set.
This dependency file is then read by the ant exec loop task
to see whether to recreate R.java.

Change-Id: I7152dac86b6ea0e448ef65e3a95694afe233c789
2011-06-27 16:44:57 -07:00
Josiah Gaskin
ce89f1531e Copy once-created R.java into library projects
This change adds functionality in Aapt to allow specification of
library projects to copy the generated R.java file into rather
than regenerating the file for each library project.

Change-Id: I05939d1dc875bd875be9298ca47cb639235070c6
2011-06-27 16:29:38 -07:00
Ying Wang
45ccfa5870 Output Proguard options for also overlay layouts.
Change-Id: I7bfac476247bd7b532510e295cb1a3e61e9af88b
2011-06-20 15:41:08 -07:00
Dianne Hackborn
810dc5980c am f1c5dbbd: am abd4dffc: Merge "New orientation handling. Only impacts SDK (aapt dump badging)." into honeycomb-mr2
* commit 'f1c5dbbd457bb14d3673508aaba497cdc328a1ef':
  New orientation handling.  Only impacts SDK (aapt dump badging).
2011-06-16 14:55:01 -07:00
Dianne Hackborn
f77ae6e65a New orientation handling. Only impacts SDK (aapt dump badging).
This is a new way of determining whether an application requires
specific orientations, done by looking at any requirements in its
activity tags.  Note that this won't catch all possible issues,
because applications can still force an orientation through Java
APIs, but the vast majority of applications that actually require
a specific orientation should be doing it this way because it the
easiest way and the only way to cleanly launch into the app from
a different orientation without doing some serious activity tricks.

Change-Id: I11d32104f6bc3d2a72aeeff1ca150b8f1c9f5588
2011-06-16 11:13:20 -07:00
Dianne Hackborn
77fc8b8066 am 6c0533f9: am c5193c62: Merge "Add new landscape and portrait orientation features." into honeycomb-mr2
* commit '6c0533f994e7991b3bd60cab48362e8e2e6d86f0':
  Add new landscape and portrait orientation features.
2011-06-14 11:40:06 -07:00
Dianne Hackborn
e289bff0ec Add new landscape and portrait orientation features.
Updates aapt to know about these.  Also updates aapt badging to:

- No longer crash due to the change to how we match unspecified
configuration resources.
- Report the new "smallest screen" supported screen configs.
- Infer old screen size buckets based on new smallest width attrs.
- Report all of the different labels and icons in an app.

Change-Id: I7376042b817391bd070f549cebbc7f03be4635c8
2011-06-14 11:23:52 -07:00
Dianne Hackborn
f14dff1219 am c6adfed6: am f795e9a8: Okay *now* really enforce the limit on non-public styles.
* commit 'c6adfed6dcea8482e482db58bd396ea8de08426a':
  Okay *now* really enforce the limit on non-public styles.
2011-06-10 07:45:38 -07:00
Dianne Hackborn
9980043e93 am 820caf7b: am 8821ba86: Ummm... f*, stop breaking the build.
* commit '820caf7b04f1e5c83599437e9e783e91322eb4f9':
  Ummm...  f*, stop breaking the build.
2011-06-09 16:18:07 -07:00
Dianne Hackborn
f795e9a86d Okay *now* really enforce the limit on non-public styles.
Change-Id: Ie8df6acf7cc3dec00f615b2fa9a5122ec79a0aae
2011-06-09 16:17:53 -07:00
Dianne Hackborn
8821ba8606 Ummm... f*, stop breaking the build.
Change-Id: I6a42cb60e7cebda6d17222e6af1f327889323c40
2011-06-09 16:09:15 -07:00
Dianne Hackborn
f51ded0f8f am a8d7ea06: am 220cd77d: Merge "Enforce public resource restriction on bag parents." into honeycomb-mr2
* commit 'a8d7ea067cf22baeee2ff0a33e5a8c5a35936942':
  Enforce public resource restriction on bag parents.
2011-06-09 16:06:07 -07:00
Dianne Hackborn
426431adcc Enforce public resource restriction on bag parents.
Need to put some more styles in the SDK to avoid breaking apps.

Also, welcome Android 3.2.

Change-Id: Ia31d07c9b1b91ad868d8630437fdc1b5ae24f37d
2011-06-09 15:27:39 -07:00
Dianne Hackborn
54cb63e26e am 528c49f1: am b96cbbd1: Add "tv" density for 720p screens.
* commit '528c49f112dce5f9687f30a9751e783196eca0c6':
  Add "tv" density for 720p screens.
2011-05-27 14:27:46 -07:00
Dianne Hackborn
b96cbbd11c Add "tv" density for 720p screens.
Change-Id: I028969b007f2fceea66947d77a2ae31ef1d1a630
2011-05-27 13:40:26 -07:00
Dianne Hackborn
bbca81334e am 4bb78889: am 40277df7: Merge "Add "television" mode." into honeycomb-mr2
* commit '4bb78889d04594c01a6af7f6d38c1764e9f575f9':
  Add "television" mode.
2011-05-23 16:16:54 -07:00
Dianne Hackborn
e360bb6bd8 Add "television" mode.
Change-Id: Ida1fdb61b036a8b489dbeda196fb4bc82e651b2b
2011-05-23 15:11:08 -07:00
Dianne Hackborn
06a8ceacb0 am c851ea56: am 69cb8757: Add new "-swNNNdp" resource qualifier.
* commit 'c851ea5672f6e042c2e89b2a2ce4a2467e1fcd2a':
  Add new "-swNNNdp" resource qualifier.
2011-05-19 19:34:21 -07:00
Dianne Hackborn
69cb87576b Add new "-swNNNdp" resource qualifier.
Change-Id: I0101e88ca9d8d44138bdcaf571f24b0352f4f6ce
2011-05-19 18:23:29 -07:00
Dianne Hackborn
2e4a3236a7 am 46a282f3: am 0ed2e845: Merge "DO NOT MERGE. Integrate add new screen width/height in "dp" configs." into honeycomb-mr2
* commit '46a282f323bc05606e4fe1eba795bd9ac7c99819':
  DO NOT MERGE.  Integrate add new screen width/height in "dp" configs.
2011-05-13 11:21:26 -07:00
Dianne Hackborn
ebff8f92f1 DO NOT MERGE. Integrate add new screen width/height in "dp" configs.
You can now specify resource configuration variants "wNNNdp"
and "hNNNdp".  These are the minimum screen width/height in "dp"
units.  This allows you to do things like have your app adjust
its layout based only on the about of horizontal space available.

This introduces a new configuration change flag for screen size.
Note that this configuration change happens each time the orientation
changes.  Applications often say they handle the orientation change
to avoid being restarted at a screen rotation, and this will now
cause them to be restarted.  To address this, we assume the app can
handle this new config change if its target SDK version is < ICS.

Change-Id: I4acb73d82677b74092c1da9e4046a4951921f9f4
2011-05-12 18:39:51 -07:00
Conley Owens
4a4d96e7ee Merge changes I0ab47e2f,Ib8016996
* changes:
  Remove errant tag terminator
  Normalize output of XMLtree content
2011-04-27 13:06:46 -07:00
Kenny Root
18490fb93e resolved conflicts for merge of 87b3c0dc to honeycomb-plus-aosp
Change-Id: Ia1a0024aabf531438203eb9fea3a10dd15eabe53
2011-04-12 10:27:15 -07:00
Shachar Shemesh
7c94b34b52 Normalize output of XMLtree content
Make the output from aapt dump xmltree normalized, so that it is unambigously
displayed regardless of the content of the strings. Previous patch left out
handling of XML element content.

Change-Id: Ib8016996c769f3dde7a87f7ecbdf850333f2426a
2011-04-11 13:32:19 +03:00
Mårten Kongstad
57f4b77c89 Runtime resource overlay, iteration 1.
Runtime resource overlay allows unmodified applications to appear
as if they had been compiled with additional resources defined. See
libs/utils/README for more information.

This commit is the first iteration of runtime resource overlay. It
provides the actual overlay modifications and loading of trusted overlay
packages (ie residing in /vendor) targeting framework-res.apk.

This commit loads exactly one overlay package. The overlay,
if present, must target framework-res.apk and be located at
/vendor/overlay/framework/framework-res.apk.

Change-Id: If26ee7754813004a96c043dba37fbe99fa3919db
2011-04-01 14:12:10 +02:00