2

I just installed Debian for the first time. I use KDE. I'm trying to install Google Chrome and Steam. I download the installation package, then I double-click it. Instead of installing, both display the error

Failed to execute child process "ar" no file or directory

Anthon
  • 78,313
  • 42
  • 165
  • 222
Villa Caleb
  • 23
  • 1
  • 5
  • `ar` is a tool for creating code libraries, part of the development toolchain. It's very surprising to say the least that installation of either Google Chrome or Steam would involve running `ar` in any way. Only if you were building them from source (and even then it wouldn't be a natural thing to expect). Can you provide any more details about what you're doing exactly, for example what commands you're running? – Celada May 01 '15 at 02:48
  • I'm downloading the Google chrome install, and then double clicking it. – Villa Caleb May 01 '15 at 03:34
  • 2
    @VillaCaleb by default the file manager is set to open dpkg files with `ar` because it's a "safer" default. Just use `dpkg -i ` or install `gdebi-kde `and open it from the file manager with that. – jordanm May 01 '15 at 04:09
  • 1
    @jordanm Good catch. I see how that could happen now. Please post that as an answer because it's almost certainly the problem and syntaxerror's existing answer is off base. – Celada May 01 '15 at 12:34
  • @Celada Listen, I am seriously willing to delete my answer IF I have a proof that it is off base. But the OP has got to return first to know exactly...You're merely *assuming* that Jordan's answer is spot-on, but you can't know for sure either unless we get some feedback from that dude... – syntaxerror May 01 '15 at 14:52
  • 1
    `.deb` files are Debian packages. They *should* be associated with a program like `gdebi-kde` that can install them. It happens that the `.deb` format is a special kind of `ar` file; your system lacks an association for `.deb` files and instead falls back to the generic `ar` file handler, which will not help you at all. You need to associate `.deb` files with a package management application. I don't know how to do this with KDE. – Gilles 'SO- stop being evil' May 01 '15 at 21:03

2 Answers2

6

You can change which program opens a file when you single/double-click it in KDE by:

  • Temporarily, for this open only: Right click, Open With, select a program.
  • Permanently: Right click, Properties. On the General tab, File Type Options. Change the order of apps under "Application Preference Order". They're tried from the top.

Most likely, to get this to work, you should probably install gdebi-kde. It'll probably become the default "open" action, but if not one of the two methods above let you change the default.

(You've currently got something that is trying to use ar to list the contents of the package. Listing the contents isn't your goal, so installing ar isn't really going to help.)

derobert
  • 107,579
  • 20
  • 231
  • 279
-6

Debian feels very non-standard here again (as usual). For instance, in Debian Jessie, the physical ar program usually shows up as /usr/bin/i486-linux-gnu-ar resp. /usr/bin/i586-linux-gnu-ar resp. /usr/bin/x86_64-linux-gnu-ar.
Though I have no Debian here at my disposal, I assume that /usr/bin/ar is merely a symbolic link. (Please note that this is just an assumption - it would require me direct access to a live system to verify on location.)

So maybe the following line will help you out of your misery, provided your aptitude works:

$ sudo apt-get install binutils

In the negative case (i. e. if it does NOT work), download e. g. binutils_x.yy-p_i386.deb (x.yy is version number (e. g. 2.25), p is patch level) from a Debian FTP server and install it using dpkg -i (must be superuser).

Rui F Ribeiro
  • 55,929
  • 26
  • 146
  • 227
syntaxerror
  • 2,236
  • 2
  • 27
  • 49
  • I did sudo apt-get install binutils and where do i do the dpkg -i? – Villa Caleb May 01 '15 at 15:30
  • 2
    The OP should not require `binutils` to be installed in order to install packages and I don't believe installing it would help anyway because `dpkg` does not require `binutils` or the `ar` command in order to work: it does its own archive processing on deb packages. `binutils` is for development. I believe instead that VillaCaleb's hypothesis is the correct one: something is trying to invoke `ar` where it should just have invoked `dpkg` in the first place. – Celada May 01 '15 at 16:35
  • FWIW, `/usr/bin/ar` is not a symlink. There is a symlink called `-linux-gnu-ar` which points back to `ar` but that's more `gcc`/`GNU` thing (for supporting cross compilers) than a Debian thing. – Celada May 01 '15 at 16:39
  • @VillaCaleb Well, you would actually have done `dpkg -i` at the same place where you did the `aptitude` call, and that is at the terminal prompt in `bash`. **Please note that this is only necessary once `apt-get` fails.** As in your case it did not fail, you may just disregard that.---Besides, thanks for accepting my answer; frankly, I would not even have dreamt about it, as I got some criticism for it ("off base" and things) ;) But: _who laughs last laughs best_ (proverb). :P – syntaxerror May 01 '15 at 18:05
  • 3
    Opening a .deb file with `ar` is completely useless under most circumstances. It certainly won't help install the software packaged in those files. – Gilles 'SO- stop being evil' May 01 '15 at 20:59
  • 1
    `$ lsb_release -d && ls -l /usr/bin/ar`      `Description: Debian GNU/Linux 8.0 (jessie)`      `-rwxr-xr-x 1 root root 56280 Feb 25 03:00 /usr/bin/ar`     So no, it's not a symlink. In fact `/usr/bin/x86_64-linux-gnu-ar` is the symlink. – derobert May 01 '15 at 21:26
  • @derobert Thank you for speaking up and for pointing that out in full detail. – syntaxerror May 01 '15 at 23:28