Skip to content Skip to sidebar Skip to footer

Non-numeric Second Argument To 'wordlist'

I'm building a c project in Eclipse-android and get the following error: This is a ndk build error (independent to my code) /Users/eladb/MyWorkspace/android-ndk-r8e/build/gmsl/__gm

Solution 1:

This is a known problem due to the r8d NDK not picking up properly the android:minSdkVersion property from the AndroidManifest.xml.

To work around that issue change the line 512 of the file /android-ndk-r8d/build/gmsl/__gmsl to:

int_encode = $(__gmsl_tr1)$(wordlist 1,$(words $1),$(__gmsl_input_int))

Solution 2:

In your AndroidManifest, add the following line:

<uses-sdkandroid:minSdkVersion="3" />

This fixed the problem for me. You generally get this when importing a project you downloaded, as newly generated projects don't have that kind of error.

For information, this issue is also reproductible from the command-line.

Solution 3:

Looks like the XML parsing code in ndk-build is sensitive to whitespace (as of r8e.) I was getting this error when I had the following line in my manifest:

<uses-sdkandroid:minSdkVersion ="10"android:targetSdkVersion="11" />

The problem went away when I replaced it with the following line, removing the whitespace between minSdkVersion and the = sign:

<uses-sdkandroid:minSdkVersion="10"android:targetSdkVersion="11" />

Ugh.

It's debatable whether you should patch the ndk (as described in the accepted answer) or do a workaround on the application side. I chose the workaround, as I work on a team with several different environments where we need to build, including a shared CI server, and I didn't want to go around patching the ndk for each environment and for each new developer. If you work solo, the accepted answer may be more appropriate as it will be fixed for your future projects as well.

Solution 4:

Try to change your file carriage control (\r\n) to linux format (\n) To fix this, I edited the file in vi and did a "set filetype=unix"

Solution 5:

just got into the same issue

"....android-ndk-r12b/build/gmsl/__gmsl:512: *** non-numeric second argument to `wordlist' function: '18e'. Stop."

if you get this 18e, the e can be anything this is because that in the Application.mk you added a letter to the APP_PLATFORM

"APP_PLATFORM := android-18e" and it should be "APP_PLATFORM := android-18"

with no letter in the end, this solve the misstype which by the way i don't know when and how it has been added as i didn't open this file for weeks now, STRANGE !

Post a Comment for "Non-numeric Second Argument To 'wordlist'"