我安装了oracle java 8 JDK并尝试运行sdkmanager命令行。这就是我得到的
# tools/bin/sdkmanager "build-tools:27.0.3" "platforms:android-25"
Exception in thread "main" java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: /usr/share/ca-certificates/mozilla/Certinomis_-_Autorit??_Racine.crt
at sun.nio.fs.UnixPath.encode(UnixPath.java:147)
at sun.nio.fs.UnixPath.<init>(UnixPath.java:71)
at sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:281)
at com.android.repository.io.impl.FileSystemFileOp.toPath(FileSystemFileOp.java:284)
at com.android.repository.io.impl.FileSystemFileOp.isDirectory(FileSystemFileOp.java:169)
at com.android.repository.impl.manager.LocalRepoLoaderImpl.collectPackages(LocalRepoLoaderImpl.java:225)
at com.android.repository.impl.manager.LocalRepoLoaderImpl.collectPackages(LocalRepoLoaderImpl.java:226)
at com.android.repository.impl.manager.LocalRepoLoaderImpl.collectPackages(LocalRepoLoaderImpl.java:226)
at com.android.repository.impl.manager.LocalRepoLoaderImpl.collectPackages(LocalRepoLoaderImpl.java:226)
at com.android.repository.impl.manager.LocalRepoLoaderImpl.collectPackages(LocalRepoLoaderImpl.java:226)
at com.android.repository.impl.manager.LocalRepoLoaderImpl.collectPackages(LocalRepoLoaderImpl.java:201)
at com.android.repository.impl.manager.LocalRepoLoaderImpl.getPackages(LocalRepoLoaderImpl.java:123)
at com.android.repository.impl.manager.RepoManagerImpl$LoadTask.run(RepoManagerImpl.java:517)
at com.android.repository.api.RepoManager$DummyProgressRunner.runSyncWithProgress(RepoManager.java:397)
at com.android.repository.impl.manager.RepoManagerImpl.load(RepoManagerImpl.java:364)
at com.android.repository.api.RepoManager.loadSynchronously(RepoManager.java:290)
at com.android.sdklib.repository.AndroidSdkHandler$RepoConfig.createRepoManager(AndroidSdkHandler.java:718)
at com.android.sdklib.repository.AndroidSdkHandler.getSdkManager(AndroidSdkHandler.java:295)
at com.android.sdklib.tool.SdkManagerCli.<init>(SdkManagerCli.java:134)
at com.android.sdklib.tool.SdkManagerCli.main(SdkManagerCli.java:118)
at com.android.sdklib.tool.SdkManagerCli.main(SdkManagerCli.java:93)
如何解决此格式错误的证书问题?
答案 0 :(得分:0)
令人惊讶的是,解决方案非常简单
export LANG=en_US.UTF-8
export LANGUAGE=en_US.UTF-8