FAQ
This has been on my TODO list for a long time but I haven't got it
done yet because it has a lot of corner cases in the design. It is
https://golang.org/issue/9985.

The main issue is whatever we do, we would want it to be portable
across both Android and iOS. So simply copying the res directory won't
do, because an icon in there won't be used by an iOS app.

For now the easiest thing to do would be to use aapt to add the res/
directory to your .apk in a step after running gomobile build, and
then resign it.
On Tue, Sep 1, 2015 at 10:12 PM, wrote:
o(∩_∩)o Hello,everyone.
I am a new developer to use gomobile. I hope that I could get the answer
here.


I build the example successfully and these can run okay.
However,when I try to change the default application icon,I get the problem.
I create the subdirectory named "res/drawable" ,put the ic_launcher.png into
it.Then, modify AndroidManifest.xml :

<application android:label="DebugApp"
android:icon="@drawable/ic_launcher" >
...others...
</application>

After build, I use 7z to unzip the apk file , then found that the "res" is
not copied to output.
YES,the problem is Here.


When I get help from "gomobile build -help",I can saw these:
"If the package directory contains an assets subdirectory, its contents are
copied into the output."
But,the document above is not mention the "RES" subdirectory.


After look up googing and GoDoc, I really have no idea how to include the
"res" subdirectory and generate resources.arsc.
So,is anyone get the answer? Or, will the gomobile project support this in
the future ?


Thank you.
Waiting for your reply.

--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Previous

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 2 | next ›
Discussion Overview
groupgolang-nuts @
categoriesgo
postedSep 2, '15 at 4:12a
activeSep 2, '15 at 6:59p
posts2
users2
websitegolang.org

2 users in discussion

Moonyuyangzhou: 1 post David Crawshaw: 1 post

People

Translate

site design / logo © 2021 Grokbase