Modifying AndroidManifest.xml with build tag causes infinite rebuilding in Eclipse

二次信任 提交于 2019-12-11 04:06:00

问题


I've added a tagging / date-stamping system to my Android build system similar to the thread found here on Stack Overflow: embed version details in android APK

This worked out great for me, The post was awesome and I simply modified the Perl to put in a datestamp like thus:

perl -npi -e 's/(Build Date:)(.+)(DEV-MOB)/"Build Date: " . localtime() . " DEV-MOB"/e;' $MANIFEST

The issue I'm dealing with now is that Eclipse wants to continue building over and over. As soon as it sees that the AndroidManifest.xml has changed, it starts another autobuild, thereby changing the AndroidManifest.xml and sparking another autobuild... Rinse, lather, repeat.

I've turned off the "Build Automatically," and the result are fine for me (i.e. only build on a debugging deployment and/or after a clean), not on every single file save and/or change as Eclipse is want to do. Co-worker wants the Autobuild functioning as normal, and says my date stamping is defective otherwise.

How do I get the "Builder" to mark the tree as refreshed and/or up-to-date after modifying the AndroidManifest.xml, so that the tree doesn't keep looping? Looks like the flag that says "refreshed" is evaluated and triggers a new build after the previous build.

Thanks, I can post more details on the date stamping if desired.

DD


回答1:


Check that your builder comes first in the Project builders list order.



来源:https://stackoverflow.com/questions/5096998/modifying-androidmanifest-xml-with-build-tag-causes-infinite-rebuilding-in-eclip

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!