You are not logged in.

#1 2012-05-18 17:03:29

freaks
Member
Registered: 2010-11-10
Posts: 63

java version

hello
i first installed openJDK then official java
yaourt -Sf jre6
yaourt -Sf jdk6


but when i execute which java i have this response :

java version "1.7.0_03-icedtea"
OpenJDK Runtime Environment (IcedTea7 2.1) (ArchLinux build 7.b147_2.1-3-x86_64)
OpenJDK 64-Bit Server VM (build 22.0-b10, mixed mode)

but

pacman -R jre7-openjdk
say this target is not installed

what can i do ?
i can't find the command : update-java-alternatives

Last edited by freaks (2012-05-18 17:05:42)

Offline

#2 2012-05-18 17:23:30

KingX
Member
From: CA
Registered: 2010-03-24
Posts: 324

Re: java version

Can you post the output of "pacman -Qs java". I would also recommend not using the "f" switch when installing a package, no need to force a install. Did you try installing openjdk again using pacman? I am not familiar with java (do not have it on my system), this is speculation on my part, but there is a good chance that when you installed the official jre/jdk, using yaourt, it removed the openjdk due to a conflict. I do not use yaourt so not sure if it has the capability to remove a package installed by pacman... but maybe it does. So, first you should decide which java version you want to work with and then just install that.

PS: You also posted this in the wrong section, not sure what this has to do with "Installation". smile

Offline

#3 2012-05-18 17:30:42

freaks
Member
Registered: 2010-11-10
Posts: 63

Re: java version

KingX wrote:

Can you post the output of "pacman -Qs java". I would also recommend not using the "f" switch when installing a package, no need to force a install. Did you try installing openjdk again using pacman? I am not familiar with java (do not have it on my system), this is speculation on my part, but there is a good chance that when you installed the official jre/jdk, using yaourt, it removed the openjdk due to a conflict. I do not use yaourt so not sure if it has the capability to remove a package installed by pacman... but maybe it does. So, first you should decide which java version you want to work with and then just install that.

PS: You also posted this in the wrong section, not sure what this has to do with "Installation". smile

hello thanks for your response
this is the output

pacman -Qs java
local/ca-certificates-java 20120225-1
    Common CA certificates (JKS keystore)
local/eclipse 3.7.2-2
    An IDE for Java and other languages
local/java-jline 1.0-2
    Java library for handling console input
local/java-rhino 1.7R3-3
    Open-source implementation of JavaScript written entirely in Java - JAR
local/jdk6 6u31-b04
    Java 6 Development Kit
local/jre6 6-1
    Java 6 Runtime Environment
local/jre7-openjdk-headless 7.b147_2.1-3
    Free Java environment based on OpenJDK 7.0 with IcedTea7 replacing binary plugs - Minimal Java runtime - needed for executing non GUI Java programs
local/rhino 1.7R3-3
    Open-source implementation of JavaScript written entirely in Java

for the moment i resolved the pb by  deleting /usr/bin/java and linking : ln -s /opt/java/jre/bin/java /usr/bin/java

Last edited by freaks (2012-05-18 17:31:45)

Offline

#4 2012-05-18 17:31:51

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,941
Website

Re: java version

shit happens if you use -Sf and that was the point you messed up.
!next


Give what you have. To someone, it may be better than you dare to think.

Offline

#5 2012-05-18 17:35:33

KingX
Member
From: CA
Registered: 2010-03-24
Posts: 324

Re: java version

Well, as you can see from that list of packages you do not have jre7-openjdk installed.. so pacman has nothing to uninstall. smile

Edit: Moral of the story, if you had NOT used "Sf" yaourt would have give you some warning, that "package jre7-openjdk is in conflict with jre6. Do you want to remove jre7-openjdk?" But since you forced the install the package was removed without your notice.

Last edited by KingX (2012-05-18 17:39:00)

Offline

#6 2012-05-18 17:41:28

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,941
Website

Re: java version

as a solution remove jre7-openjdk-headless and reinstall jre6/jdk6


Give what you have. To someone, it may be better than you dare to think.

Offline

#7 2012-05-18 18:35:15

adamrehard
Member
From: NY, USA
Registered: 2011-11-03
Posts: 154

Re: java version

First of all, you don't want to be using the -f flag in pacman or yaourt. It will cause breakage.
Second of all, You installed version 6 of both and you are trying to remove version 7.

You said that you installed them separately, have you tried removing them separately?

EDIT: Oops, someone else beat me to it.

Last edited by adamrehard (2012-05-18 18:36:04)


"The box said requires Vista or better, so I installed Arch"
Windows != Linux

Offline

#8 2012-05-18 21:46:55

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: java version

adamrehard wrote:

EDIT: Oops, someone else beat me to it.

by a huge margin ;-)


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

Board footer

Powered by FluxBB