Re: [android-building] How to use build vars like PRODUCT_XXX in genrule cmd?

2019-11-22 Thread 'Dan Willemsen' via Android Building
We've recently updated our documentation around conditionals (and most use
of make variables fall into the same category):

https://android.googlesource.com/platform/build/soong/+/master/README.md#how-do-i-write-conditionals

tl;dr: we'd prefer you didn't use them, but if you need to, you can via a
Go plugin.

- Dan

On Fri, Nov 22, 2019, 7:11 AM Chih-Wei Huang 
wrote:

> I have the same question.
> I'd like to use product variables like TARGET_PRODUCT in Android.bp.
> I searched the whole AOSP tree but still can't find a way to do that.
> Sigh,,, Is it possible?
>
> DavidRobin於 2019年7月16日星期二 UTC+8下午11時13分22秒寫道:
>>
>> Thanks for your reply.
>> Our purpose is to generate "License checking code" for specific product
>> build.
>> So we have a shell script to generate the code based on the PRODUCT_XXX
>> properties.
>>
>> Are you implying that Android.bp should only be used in generic (product
>> independent) modules?
>> And this kind of code should be put in device/product specific stuff and
>> use Android.mk to achieve the goal?
>> (P.S. will Android.mk be kept or will Android.bp take over the whole
>> build?)
>>
>> On Tuesday, July 16, 2019 at 2:13:13 AM UTC+8, Dan Willemsen wrote:
>>>
>>> Those variables aren't exposed, partially because it becomes very
>>> difficult to understand which pieces of the system are then
>>> product-specific vs generic. Is there a reason why you wouldn't just read
>>> the runtime properties rather than trying to embed those values in code?
>>>
>>> - Dan
>>>
>>> On Mon, Jul 15, 2019 at 9:31 AM DavidRobin  wrote:
>>>
 I saw that in external/libmojo/Android.bp there is an example to
 generate header files for later build process.

 genrule {
 name: "libmojo_mojom_headers",
 cmd: "$(location mojom_source_generator_sh)" +
 "--mojom_bindings_generator=$(location
 mojom_bindings_generator)" +
 "--package=external/libmojo" +
 "--output_dir=$(genDir)" +
 "--bytecode_path=$(genDir)" +
 "--typemap=$(location
 gen/mojo/common/common_custom_types__type_mappings)" +
 "--generators=c++" +
 "--use_new_wrapper_types" +
 "$(in)",

 However, I cannot find how to use vars like $(PRODUCT_BRAND)
 $(PRODUCT_MANUFACTURER) etc in this cmd line.
 Please help.
 Thanks.

>>> --
> --
> You received this message because you are subscribed to the "Android
> Building" mailing list.
> To post to this group, send email to android-building@googlegroups.com
> To unsubscribe from this group, send email to
> android-building+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-building?hl=en
>
> ---
> You received this message because you are subscribed to the Google Groups
> "Android Building" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to android-building+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/android-building/6a64020b-1413-4723-aabe-3d6ce27f3ae9%40googlegroups.com
> 
> .
>

-- 
-- 
You received this message because you are subscribed to the "Android Building" 
mailing list.
To post to this group, send email to android-building@googlegroups.com
To unsubscribe from this group, send email to
android-building+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-building+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-building/CALQgHdnnDnFR31OzHoFh22CPTiF4L7vtr0JqHdJuCUNAMiSn1Q%40mail.gmail.com.


Re: [android-building] How to use build vars like PRODUCT_XXX in genrule cmd?

2019-11-22 Thread Chih-Wei Huang
I have the same question.
I'd like to use product variables like TARGET_PRODUCT in Android.bp.
I searched the whole AOSP tree but still can't find a way to do that.
Sigh,,, Is it possible?

DavidRobin於 2019年7月16日星期二 UTC+8下午11時13分22秒寫道:
>
> Thanks for your reply.
> Our purpose is to generate "License checking code" for specific product 
> build.
> So we have a shell script to generate the code based on the PRODUCT_XXX 
> properties.
>
> Are you implying that Android.bp should only be used in generic (product 
> independent) modules?
> And this kind of code should be put in device/product specific stuff and 
> use Android.mk to achieve the goal?
> (P.S. will Android.mk be kept or will Android.bp take over the whole 
> build?)
>
> On Tuesday, July 16, 2019 at 2:13:13 AM UTC+8, Dan Willemsen wrote:
>>
>> Those variables aren't exposed, partially because it becomes very 
>> difficult to understand which pieces of the system are then 
>> product-specific vs generic. Is there a reason why you wouldn't just read 
>> the runtime properties rather than trying to embed those values in code?
>>
>> - Dan
>>
>> On Mon, Jul 15, 2019 at 9:31 AM DavidRobin  wrote:
>>
>>> I saw that in external/libmojo/Android.bp there is an example to 
>>> generate header files for later build process.
>>>
>>> genrule {
>>> name: "libmojo_mojom_headers",
>>> cmd: "$(location mojom_source_generator_sh)" +
>>> "--mojom_bindings_generator=$(location 
>>> mojom_bindings_generator)" +
>>> "--package=external/libmojo" +
>>> "--output_dir=$(genDir)" +
>>> "--bytecode_path=$(genDir)" +
>>> "--typemap=$(location 
>>> gen/mojo/common/common_custom_types__type_mappings)" +
>>> "--generators=c++" +
>>> "--use_new_wrapper_types" +
>>> "$(in)",
>>>
>>> However, I cannot find how to use vars like $(PRODUCT_BRAND) 
>>> $(PRODUCT_MANUFACTURER) etc in this cmd line.
>>> Please help.
>>> Thanks.
>>>
>>

-- 
-- 
You received this message because you are subscribed to the "Android Building" 
mailing list.
To post to this group, send email to android-building@googlegroups.com
To unsubscribe from this group, send email to
android-building+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-building+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-building/6a64020b-1413-4723-aabe-3d6ce27f3ae9%40googlegroups.com.


[android-building] Re: cant build aosp src (oreo 8.1.0 r3), always fails (tried different targets)

2019-11-22 Thread Eliane Fonseca


oh sorry, i didn't see that post, but i will try the solution mentioned 
there

-- 
-- 
You received this message because you are subscribed to the "Android Building" 
mailing list.
To post to this group, send email to android-building@googlegroups.com
To unsubscribe from this group, send email to
android-building+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-building+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-building/1d5ac5cc-234a-48bb-a55a-22344cc7a449%40googlegroups.com.


[android-building] Re: building trusty tee

2019-11-22 Thread Semw
Trusty is included in AOSP (according to Trusty working documentation) when 
you built it but need to find out where it is included. Whether it is 
included as lk.bin or as source code which gets compiled when aosp gets 
compiled. I am also working on it. 

On Friday, November 15, 2019 at 9:28:05 PM UTC+5, Aaron Simmons wrote:
>
> I'm having the same problem and asked about it here 
> .  
> Now that I've built the Trusty TEE image, I don't know what to do with it.  
> There's no documentation for how to deploy Trusty to a real dev board.
>
> On Friday, November 15, 2019 at 8:01:14 AM UTC-7, Weitian Xing wrote:
>>
>> Hi, do you know how to build Android image with trusty os? What should we 
>> do with the generated "lk.bin"? Can this little kernel file run with qemu? 
>> Thanks in advance!
>>
>> On Tuesday, November 12, 2019 at 2:28:58 PM UTC-5, Aaron Simmons wrote:
>>>
>>> I'm trying to build AOSP along with the Trusty TEE 
>>> .  
>>> However, the build falls down due to OpenSSL:
>>>
>>> building 
>>> /home/paleozogt/Development/trusty/build-root/build-generic-arm64/host_tests/obj/storage_test/trusty/user/app/storage/test/../block_cache.o
>>> trusty/user/app/storage/test/../block_cache.c:27:10: fatal error: 
>>> 'openssl/crypto.h' file not found
>>> #include 
>>>  ^~
>>> 1 error generated.
>>>
>>> Any ideas on how to get Trusty TEE to build?  I'd report this as a bug, 
>>> but I'm not sure where to file Trusty bugs.
>>>
>>>

-- 
-- 
You received this message because you are subscribed to the "Android Building" 
mailing list.
To post to this group, send email to android-building@googlegroups.com
To unsubscribe from this group, send email to
android-building+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-building+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-building/18eeb91c-60a8-4b66-84fb-529c4354b1d4%40googlegroups.com.


Re: [android-building] Re: Android Security Backport Released

2019-11-22 Thread Chih-Wei Huang


James Muir於 2019年11月18日星期一 UTC+8下午4時04分45秒寫道:
>
> > Please manage the thing right, Google! 
>
> I'm not sure if comments like that are helpful. 
>
> Maybe there is a valid  reason not to touch the SPL when google has not 
> published a device release from a given tag, or maybe it is just a 
> process issue (e.g. may be the release manager is in charge of changing 
> the SPL). 
>

What's the valid reason to keep it to a very old date?
That's inconceivable.

-- 
-- 
You received this message because you are subscribed to the "Android Building" 
mailing list.
To post to this group, send email to android-building@googlegroups.com
To unsubscribe from this group, send email to
android-building+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-building+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-building/2854a15b-ef9d-4f20-971e-414a9123fc4f%40googlegroups.com.


Re: [android-building] AOSP sepolicy_tests_intermediates/sepolicy_tests error on building using MAC Catalina

2019-11-22 Thread Jianwu Gao
Hi
I got same errors,not fixed yet
Have you fix this issue?

Dr. Dhanyu Eshaka  于2019年11月18日周一 上午1:23写道:

> After updating MAC OSX to 10.15.1 (Catalina) I get the following errors on
> sepolicy.
>
> The target build device is Pixel 3a XL ( android-10.0.0_r10)
>
> I need to resolve this ASAP. Any help would be appreciated.
>
> [ 77% 78861/101937] build
> out/target/product/bonito/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests
>
> FAILED:
> out/target/product/bonito/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests
>
> /bin/bash -c "(out/host/darwin-x86/bin/sepolicy_tests -l
> out/host/darwin-x86/lib64/libsepolwrap.dylib  -f
> out/target/product/bonito/obj/ETC/plat_file_contexts_intermediates/plat_file_contexts
> -f
> out/target/product/bonito/obj/ETC/vendor_file_contexts_intermediates/vendor_file_contexts
> -p out/target/product/bonito/obj/ETC/sepolicy_intermediates/sepolicy ) &&
> (touch
> out/target/product/bonito/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests
> )"
>
> /bin/bash: line 1:  8780 Segmentation fault: 11  (
> out/host/darwin-x86/bin/sepolicy_tests -l
> out/host/darwin-x86/lib64/libsepolwrap.dylib -f
> out/target/product/bonito/obj/ETC/plat_file_contexts_intermediates/plat_file_contexts
> -f
> out/target/product/bonito/obj/ETC/vendor_file_contexts_intermediates/vendor_file_contexts
> -p out/target/product/bonito/obj/ETC/sepolicy_intermediates/sepolicy )
>
> 06:54:50 ninja failed with: exit status 1
>
> --
> --
> You received this message because you are subscribed to the "Android
> Building" mailing list.
> To post to this group, send email to android-building@googlegroups.com
> To unsubscribe from this group, send email to
> android-building+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-building?hl=en
>
> ---
> You received this message because you are subscribed to the Google Groups
> "Android Building" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to android-building+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/android-building/3abf0458-046d-4e69-8faf-fa483941e10b%40googlegroups.com
> 
> .
>

-- 
-- 
You received this message because you are subscribed to the "Android Building" 
mailing list.
To post to this group, send email to android-building@googlegroups.com
To unsubscribe from this group, send email to
android-building+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-building+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-building/CAPDXgOt0NEhCmrn501JCpWyA8bWiPiQOkrUA1MQmcycdkNpAug%40mail.gmail.com.