Original directory structure
Compile the java ,and the shell make.sh
mkdir -p target
javac -sourcepath ./src/ ./src/com/tencent/Example.java -d ./target/
and Two folders named target appeared.One of them has compiled files and the other is empty
Then execute another shell start.sh
cd target
echo "shell parameters: $*"
java -classpath . com.tencent.Example $*
the compiled file cannot be found.If I copy the compiled files in a target to an another empty folder.The program can be executed normally.
I want to know why a folder with the same name is generated and how to solve this problem.