I am having a hard time finding a solution for the following error that occurs when trying to build an app bundle:
Module files can be only in pre-defined directories, but found 'libs/android-support-v4.jar
My application compiles fine, I deploy it via Bridge to my phone, no problem.
I am using Windows 11 Pro, B4A 11.80 & sometimes NOX to test different resolutions.
Fixes that I have tried, but that didn't solve the problem:
- TargetSDK=31 (Changed it to 30 & 29, no change)
- Re-installed Java, extracted all the necessary Android archives, to no avail.
- Removed android-support-v4.jar out of my additional libraries folder, no luck
- Tried to fix it with SDK-manager, which gives me an extra error: Error reading recommended items list
Can anybody help me with this?
Module files can be only in pre-defined directories, but found 'libs/android-support-v4.jar
Error building app bundle:
B4A Version: 11.80
Parsing code. (0.11s)
Java Version: 8
Building folders structure. (0.03s)
Compiling code. (0.08s)
ObfuscatorMap.txt file created in Objects folder.
Compiling layouts code. (0.03s)
Organizing libraries. (0.00s)
(AndroidX SDK)
Compiling resources (0.35s)
Linking resources (1.67s)
Compiling generated Java code. (1.35s)
Finding libraries that need to be dexed. (0.01s)
Dex code (1.83s)
Dex merge (1.82s)
Copying libraries resources (3.79s)
Building app bundle Error
[BT:1.5.0] Error: Module files can be only in pre-defined directories, but found 'libs/android-support-v4.jar'.
com.android.tools.build.bundletool.model.exceptions.InvalidBundleException: Module files can be only in pre-defined directories, but found 'libs/android-support-v4.jar'.
at com.android.tools.build.bundletool.model.exceptions.UserExceptionBuilder.build(UserExceptionBuilder.java:58)
at com.android.tools.build.bundletool.validation.BundleFilesValidator.validateModuleFile(BundleFilesValidator.java:156)
at com.android.tools.build.bundletool.validation.ValidatorRunner.validateBundleModulesUsingSubValidator(ValidatorRunner.java:81)
at com.android.tools.build.bundletool.validation.ValidatorRunner.lambda$validateBundleModules$4(ValidatorRunner.java:64)
at com.google.common.collect.ImmutableList.forEach(ImmutableList.java:406)
at com.android.tools.build.bundletool.validation.ValidatorRunner.validateBundleModules(ValidatorRunner.java:63)
at com.android.tools.build.bundletool.validation.BundleModulesValidator.validate(BundleModulesValidator.java:82)
at com.android.tools.build.bundletool.commands.BuildBundleCommand.execute(BuildBundleCommand.java:231)
at com.android.tools.build.bundletool.BundleToolMain.main(BundleToolMain.java:71)
at com.android.tools.build.bundletool.BundleToolMain.main(BundleToolMain.java:47)
My application compiles fine, I deploy it via Bridge to my phone, no problem.
I am using Windows 11 Pro, B4A 11.80 & sometimes NOX to test different resolutions.
Fixes that I have tried, but that didn't solve the problem:
- TargetSDK=31 (Changed it to 30 & 29, no change)
- Re-installed Java, extracted all the necessary Android archives, to no avail.
- Removed android-support-v4.jar out of my additional libraries folder, no luck
- Tried to fix it with SDK-manager, which gives me an extra error: Error reading recommended items list
Socket error:
B4A Sdk Manager: 4.00
TempFolder = C:\Users\bigba\AppData\Roaming\ANYWHE~1\BASIC4~1\temp
DataFolder: C:\Users\bigba\AppData\Roaming\B4ASdkManager
SDK version: 6609375
Downloading: https://dl.google.com/dl/android/maven2/master-index.xml
error: java.net.SocketException: Connection reset by peer: socket write error
Can anybody help me with this?