Trying to compile libgdx in html but it cannot clear assets

Failed to compile libgdx project in html.

Looking at the log, I think the problem is:

Copying resources from ../android/assets to war/ C:\TomsProjects\MeshExplorerV2\html\..\android\assets C:\TomsProjects\MeshExplorerV2\html\assets [ERROR] Generator 'com.badlogic.gdx.backends.gwt.preloader.PreloaderBundleGenerator' threw an exception while rebinding 'com.badlogic.gdx.backends.gwt.preloader.PreloaderBundle' java.lang.RuntimeException: Couldn't clean target path 'war\assets' 

Now it seems a little strange to me in the second line; Since there was no html \ assets folder. The assets folder was in html \ war \ assets, as in the last line.

However, by creating an empty resource folder in html and manually deleting the contents of html \ war \ assets, I still get the same error.

Theres also a "html \ webapp" directory without any resource folder. Not sure what it should be.

I tried to clean / restore from the eclipse, and also by accident and try Gradle -> Update All.

In addition, the Java version works fine.

Any pointers, thanks :)

+6
source share
2 answers

While I do not exactly catch the problem route, I noticed that this allows me to compile again while I restarted eclipse inbetween. This means that some file locks continue, perhaps the server is still working, although nothing but gwt will compile as I called. However, restarting is a great way to get around me, as it only takes a minute or two.

Oh

Attached file: close the FTP program at compilation - at least CoreFTP blocks the directory. Closing works every time.

+2
source

I had a similar problem when I was getting the following error

 [ERROR] Generator 'com.badlogic.gdx.backends.gwt.preloader.PreloaderBundleGenerator' threw an exception while rebinding 'com.badlogic.gdx.backends.gwt.preloader.PreloaderBundle' java.lang.RuntimeException: Couldn't clean target path 'war/assets' 

All my files in the html/war/assets directory were only read, re-starting the IDE did not help. To fix this, I needed to change the permissions of chmod -R 777 html/war/assets (you probably don't need 777 ).

0
source

Source: https://habr.com/ru/post/974397/


All Articles