The solution of NDK compile system LongPaths issue on windows platform

The solution of NDK compile system LongPaths issue on windows platform
0

#1

Recently, somebody have issue with ndk compile at windows platform with LongPaths source files, also I also met the issue, so I try to write a patch to let ndk compile system to support LongPaths anywhere, fortunately, it’s work well, so I think I need to share the patch as a standalone topic

there is the solution:

finally:
Now, this solution support clang and gcc at windows7 & windows 10 platform.

Android Studio + ndk-r17 + cocos2d-x-3.17 cpp-empty-test:

No patch installed:

With patch installed:

How to install this patch:
1: set env var ANDROID_NDK_ROOT to your ndk-bundle directory
2: right click dists/ndk-wsls-2.0-final/install.bat, run as administrator.


#2

Just 3 days back we faced this problem and we have to switch folders.
Monday i will try this first. :slight_smile:


#3

Updates:

  1. Fix win7 command ‘md’ do not support Long Path
  2. Fix cc1.exe do not support Long Path

#4

Update
ndk-r16b, please use: ndk-wsls-3.0.zip (283.6 KB)

ndk-r17, please use: ndk-wsls-2.2.1.zip (281.1 KB)