small medium large xlarge

07 Jul 2014, 17:30
David Coopersmith (6 posts)

Hi all,

First of all, thank you, Andy, for this book. It’s been a lot of fun.

Sorry if I do this wrong. This is my first post to this forum.

I’ve looked through this forum and can’t seem to find anyone else with this issue. The craftbukkit server works fine. But, when trying to build the HelloWorld plugin, I get an ‘error in opening zip file’ error and compilation stops. Here’s what I copied from the shell:

C:\Users\D\Desktop>C:\Windows\system32\cmd.exe /c sh.exe -l
~ $ cd Desktop
~/Desktop $ cd code/HelloWorld
~/Desktop/code/HelloWorld $ ls
bin    dist        plugin.yml  src
~/Desktop/code/HelloWorld $ ./
Compiling with javac...
error: error reading C:\Users\D\Desktop\server\bukkit.jar; error in opening zip file
warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 error
1 warning
~/Desktop/code/HelloWorld $

I’m running Windows 8.1.

Thank you for your help!


07 Jul 2014, 17:48
David Coopersmith (6 posts)

When I run: javac -version

I get: javac 1.8.0_05

And when I run: java -version

I get: java version “1.8.0_05”

So, I’m thinking maybe it’s a problem with the -source and the -target both being set to 1.6 ??

I’ll try setting to 1.8 and post what happens…

Thanks! David

07 Jul 2014, 17:52
David Coopersmith (6 posts)

Okay changing the file so that -source and -target are set to 1.8 didn’t get rid of the error, but it did get rid of the warning listed in my first post. Weird…

Here’s the code from

# 1. Compile
echo "Compiling with javac..."
javac -Xlint:deprecation src/*/*.java -d bin -classpath "$BUKKIT" -sourcepath src -target 1.8 -g:lines,vars,source -source 1.8 || exit 2

07 Jul 2014, 17:54
David Coopersmith (6 posts)

Okay, I tried setting source and target to 1.7. The error remained, and it brought back the ‘bootstrap’ warning…

Any help would be much appreciated :)

~ David

07 Jul 2014, 18:11
Andrew Hunt (218 posts)

Could be a corrupted jar file, I suppose. Make sure it downloaded ok. Also, the JAVA_HOME setting could be wrong. Make sure that it points to the root of the Java JDK (not the JRE, which doesn’t have the development tools). So it should be set to something like C:\Program Files (x86)\Java\jdk1.6.0_15


08 Jul 2014, 02:23
David Coopersmith (6 posts)

Thank you, Andy!

I created a JAVA_HOME environment variable and pointed it at my jdk folder. But that didn’t fix it.

Then, I deleted the bukkit.jar file from the server directory, re-downloaded it from the BukkitWikki page into the server directory (renamed it to bukkit.jar during the download), and it worked! Thanks so much! :)

~ David

08 Jul 2014, 13:06
Andrew Hunt (218 posts)

Ah, so it was corrupted somehow. The simplest explanation is usually the right one!


08 Jul 2014, 18:28
David Coopersmith (6 posts)

Yes. Definitely another learning experience. :)

  You must be logged in to comment