-
-
Notifications
You must be signed in to change notification settings - Fork 371
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
Build directory #802
Build directory #802
Conversation
The actual path is I could set it up to go in |
Reconsidering file structure:
|
Windows counts characters, not folder levels, so "android-release" would be exactly the same. Going back to "android" would help, but if someone wants to store a project in " But why would someone who's that picky about folders want a build directory like this? The reason is that everything in the build directory is entirely disposable, and will most likely never need to be checked into version control. (Like OpenFL's
Gradle refers to them as both "dependencies" (less specific) and "subprojects" (more specific). I'd say "deps" is fine.
It helps fix a compiler error on Windows and does almost nothing on Mac and Linux. There are other ways to fix the error, but this was the most convenient.
As in, setting
It has to be under 240 characters. The exact path length varies based on lots of factors, but here's the path that caused the error in my tests:
Here's the same path with
The first is 247 characters, the second is 194 characters, and the third is 219 characters. However, you should add at least three to each of those numbers, because these were all in the |
Also, have you seen if newer Gradle versions work? I wonder if they have done anything to rein in the long paths since 2.1.0? |
I don't think the Gradle devs consider this their problem, since it's caused by a Windows limitation, and the files causing the error belong to Google Play Services. I searched around some more, but no one's suggested updating Gradle as a solution to this. The Google Play Services devs don't seem to care either; these files have been there ever since version 3.1.36 (the current version is 9.6.1). The images changed each time Google released a new logo, but the paths stayed the same. |
I believe I have this merged, but let me know if you find any issues. Thank you! |
Windows has a hard limit (240 characters) on the length of a file path. Gradle uses deeply nested files, and some libraries (looking at you, Google Play Game Services!) include extremely long file names.
Gradle's paths are still under the limit, but Lime's directory structure
Export/android/release/bin
is enough to push it over in some cases.Fortunately, Gradle lets you put its build folders somewhere else; ideally somewhere with a very short filepath. For instance, by setting
<android gradle-build-directory="C:/Build" />
, you'll dramatically reduce your file path length without having to move your project. (If you don't setgradle-build-directory
, everything works exactly as before.)