Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot use Java TAR file #811

Closed
farzadmf opened this issue Aug 7, 2016 · 4 comments
Closed

Cannot use Java TAR file #811

farzadmf opened this issue Aug 7, 2016 · 4 comments

Comments

@farzadmf
Copy link

farzadmf commented Aug 7, 2016

I tried to use Java the same way I do in normal Ubuntu:

  • Download and untar the official Java from oracle
  • Create a soft link to the extracted directory
  • Set my PATH and JAVA_HOME in ~/.bashrc to point to those
  • To set my PATH, I do the following
export JAVA_HOME=/my/symbolic/link
export PATH="${JAVA_HOME}/bin:$PATH"

So, I have two problems:

  • If I set JAVA_HOME to my symbolic link, it doesn't recognize it, and if I do which java, it's still using /usr/bin/java
  • If I set JAVA_HOME to the actual extracted directory, it recognizes that it should run java in that directory, but when I try java -version, it just freezes and does nothing!
@onomatopellan
Copy link

onomatopellan commented Aug 8, 2016

Duplicate of #746
Fix coming in a future insider build.

About the tar, try to untar it in a VolFs folder like /home. DrvFs folders like /mnt/c have still problems with symlinks.

@farzadmf
Copy link
Author

farzadmf commented Aug 8, 2016

Actually, I have created a subdirectory under my home directory that contains jdk-1.8.0_101 and I have a symlink in the same directory, pointing to that:

lrwxrwxrwx 1 farza farza    13 Aug  7 19:04 java -> jdk1.8.0_101//
drwxr-xr-x 2 farza farza     0 Aug  7 19:04 jdk1.8.0_101/

UPDATE: I noticed the double slash at the end of the link target, so I ran my ln command again, and now I have:

lrwxrwxrwx 1 farza farza    13 Aug  7 19:04 java -> jdk1.8.0_101/
drwxr-xr-x 2 farza farza     0 Aug  7 19:04 jdk1.8.0_101/

It seems that the link issue is now solved (although I think an extra slash wouldn't make that much of a difference), but the problem with freezing still exists, which I hope will be resolved by later builds

@onomatopellan
Copy link

Yes, the symlink with slash at the end of the path is also a known bug. It's very easy to hit especially if you use TAB to complete a path. Should be fixed in next builds too.

@farzadmf
Copy link
Author

farzadmf commented Aug 9, 2016

Cool, I would really dream of being able to use a full bash on Windows (if that ever becomes a reality)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants