oasp / oasp4j-ide

tool to automate setup and update of development environment (for Java projects)
Apache License 2.0
14 stars 15 forks source link

java JDKs not copied on linux #108

Closed maybeec closed 7 years ago

maybeec commented 7 years ago

Currently the fscopy task is failing if the folder already exists. I am not sure, whether the folder is added manually beforehand and thus conflicting with this task, or if it is a bug in the fscopy task. I installed into a clean folder. Nothing was existing to be "upgraded". Please evaluate.

Performing File System Copy fscopy.java.7
Copying /usr/lib/jvm/java-1.7.0-openjdk-amd64 to /home/malte/eclipse/test-neon/software/additionalJDKs/java-1.7
Created destination /home/malte/eclipse/test-neon/software/additionalJDKs/java-1.7
Caught FileAlreadyExistsException for /home/malte/eclipse/test-neon/software/additionalJDKs/java-1.7 Continue.
Performing File System Copy fscopy.java.8
Copying /usr/lib/jvm/java-1.8.0-openjdk-amd64 to /home/malte/eclipse/test-neon/software/java
Created destination /home/malte/eclipse/test-neon/software/java
Caught FileAlreadyExistsException for /home/malte/eclipse/test-neon/software/java Continue.
themetalone commented 7 years ago

I ran into a similiar problem. I found that the 'default' JVM the installer chooses is a link to somewhere. The copy task seems not to follow the link (although I told him otherwise).

If it is the same Problem you need to change the JVM to that one that is actually present in +usr/lib/jvm/+

maybeec commented 7 years ago

You are right, it does not follow symlinks. However, this may be a special case as the folder/link you are intent to be copied is a already a link. Thus it may just copy the link. However, it does not copy the link, but interprets the link as an empty folder instead.

You are copying files with nio Path, are you? Maybe you have to treat the root folder to be copied by hand to follow the symlink.

themetalone commented 7 years ago

The current oomph-task-fscopy implementation does the following: