サーバー上でJavaビルドツールantを使用してAndroidアプリをコンパイルしています。
root ユーザーとして以下を実行すると、ビルドは成功します。
export ANT_HOME=/usr/local/ant
export JAVA_HOME=/usr/local/jdk
export PATH=${PATH}:${ANT_HOME}/bin
cd /path/to/android/file
/usr/local/ant/bin/ant release
ただし、netuser(またはテストした他のユーザー)として次を実行すると:
export ANT_HOME=/usr/local/ant
export JAVA_HOME=/usr/local/jdk
export PATH=${PATH}:${ANT_HOME}/bin
cd /path/to/android/file
sudo /usr/local/ant/bin/ant release
次のエラーが表示されます。
BUILD FAILED
/path/to/android/file/build.xml:83: The following error occurred while executing this line:
/usr/share/android-sdk/tools/ant/build.xml:206: Class org.apache.tools.ant.taskdefs.condition.And doesn't support the nested "matches" element.
sudoers ファイルを変更して、netuser ALL=(ALL) ALL を使用して netuser にすべてのアクセス許可を付与しようとしましたが、同じ結果が得られます...誰かが私が間違っていることを教えてもらえますか?
助けてくれてありがとう。