Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[Solved] Android developement on multiarch

Programming languages, Coding, Executables, Package Creation, and Scripting.
Post Reply
Message
Author
krita
Posts: 31
Joined: 2012-03-10 13:19

[Solved] Android developement on multiarch

#1 Post by krita »

Hi,
I'm trying to setup tools for developing android apps on my Debian Wheezy (backport) system. Eclipse with android plugins is installed. Android SDK installed using android-sdk_r22.6.2-linux.tgz available from https://developer.android.com/sdk/index.html. Neccessary Android SDK Tools, Platform-tools, Build-tools and APIs etc was fetched too.

My problem is I can't build the android app. The console in Eclipse tells me something (translated) like this;

Code: Select all

[2014-05-30 16:36:45 - adb] Unexpected exception 'Cannot run program "/usr/lib/android-sdk-linux/platform-tools/adb": java.io.IOException: error=2, No such file or directory' while attempting to get adb version from '/usr/lib/android-sdk-linux/platform-tools/adb'
I have searched the web quite extensively but found no solution. It seems the issue may be due to I'm having a 64bit system but building the app requires some 32bit stuff.
Some older posts suggest adding package by "apt-get install ia32-libs". In later posts (i.e. http://stackoverflow.com/questions/2710 ... ux-machine) it appears ia32-libs isn't the preferred way anymore and suggests something like

Code: Select all

dpkg --add-architecture i386
apt-get update
apt-get install libc6:i386 libncurses5:i386 libstdc++6:i386
However doing apt-get install libc6:i386 asks me to remove 1536 installed packages and installing just 5 new... Hmm :shock: That gives me the feeling I will be sitting in front of a dead brick when done.

I didn't expect it to be this tricky to get it working... What can be wrong?
Any help highly appreciated!

Some info about my system if it helps;

Code: Select all

>uname -mrv
3.14-0.bpo.1-amd64 #1 SMP Debian 3.14.4-1~bpo70+1 (2014-05-14) x86_64
Last edited by krita on 2014-05-29 21:29, edited 1 time in total.

User avatar
edbarx
Posts: 5401
Joined: 2007-07-18 06:19
Location: 35° 50 N, 14 º 35 E
Been thanked: 2 times

Re: Android developement on multiarch

#2 Post by edbarx »

My post is about using android-studio instead of eclipse. You can install it as instructed in my howto. I tested it and it works. The downside: it is too slow for someone used to using an optimized Debian GNU/Linux installation.

See here for any installation details.
Debian == { > 30, 000 packages }; Debian != systemd
The worst infection of all, is a false sense of security!
It is hard to get away from CLI tools.

krita
Posts: 31
Joined: 2012-03-10 13:19

Re: Android developement on multiarch

#3 Post by krita »

Hi,
While downloading the Android Studio, i tried to "apt-get install lib32stdc++6".
Unfortunately this fails with (freely translated) output

Code: Select all

 lib32stdc++6 : Dependent of: lib32gcc1 (>= 1:4.1.1) but it will not be installed
                Dependent of: libc6-i386 (>= 2.3.2) but it will not be installed
E: Could not correct the problem, you have keept back broken packages.
Any idea?

User avatar
edbarx
Posts: 5401
Joined: 2007-07-18 06:19
Location: 35° 50 N, 14 º 35 E
Been thanked: 2 times

Re: Android developement on multiarch

#4 Post by edbarx »

What happens when you issue the command:

Code: Select all

apt-get -f install
If you are unsure, post before affirming to execute the command.
Debian == { > 30, 000 packages }; Debian != systemd
The worst infection of all, is a false sense of security!
It is hard to get away from CLI tools.

krita
Posts: 31
Joined: 2012-03-10 13:19

Re: Android developement on multiarch

#5 Post by krita »

apt-get -f install gives something like

Reading packages... done
Building dependency tree
Read state information... done
0 to upgrade, 0 new to install, 0 to remove and 1 to not update.

User avatar
edbarx
Posts: 5401
Joined: 2007-07-18 06:19
Location: 35° 50 N, 14 º 35 E
Been thanked: 2 times

Re: Android developement on multiarch

#6 Post by edbarx »

Code: Select all

E: Could not correct the problem, you have keept back broken packages.
If you have any broken packages, first you should remove those. This should allow apt to install what you need. In my case, the procedure explained in my howto worked.
Debian == { > 30, 000 packages }; Debian != systemd
The worst infection of all, is a false sense of security!
It is hard to get away from CLI tools.

krita
Posts: 31
Joined: 2012-03-10 13:19

Re: Android developement on multiarch

#7 Post by krita »

Yes suppose so. Just had a hard time understand what was actually broke.
But maybe...

It seems lib32stdc++6 needs
lib32gcc1 (>= 1:4.1.1) which needs
libc6-i386 (>= 2.11) which needs
libc6 (= 2.13-38+deb7u1) but libc6 2.18-5 will be installed

I tried to downgrade libc6 and at least now lib32cstdc++6 was successfully installed! Maybe this will make me come further. (And maybe eclipse will actually work too). Let's see...

Thanks for your help!

krita
Posts: 31
Joined: 2012-03-10 13:19

[Solved] Re: Android developement on multiarch

#8 Post by krita »

YEEES! Finally Eclipse works! I may try out Android Studio as well later but for now I will just enjoy the technical victory running Eclipse :D
Thanks a lot!

User avatar
edbarx
Posts: 5401
Joined: 2007-07-18 06:19
Location: 35° 50 N, 14 º 35 E
Been thanked: 2 times

Re: [Solved] Android developement on multiarch

#9 Post by edbarx »

For your future reference, please be informed that eclipse is in the official Debian repositories. If your system is not broken, to install it, you only need to run as root:

Code: Select all

apt-get install eclipse
On the other hand, android-studio is not in the repositories implying its installation may require different steps other than a normal package installation.
Debian == { > 30, 000 packages }; Debian != systemd
The worst infection of all, is a false sense of security!
It is hard to get away from CLI tools.

Post Reply