web-dev-qa-db-ja.com

libpng警告:iCCP:編集された既知のsRGBプロファイルを認識しません

Titanium Android app。のTextFieldでカーソルの色を変更しようとしています。そのために、platform/Android/res/values/フォルダーを作成しました。

次のコードをtiapp.xmlに配置しました。

<Android xmlns:Android="http://schemas.Android.com/apk/res/Android">
  <manifest>
    <application Android:theme="@style/Theme.Titanium">
    </application>
    <uses-sdk Android:minSdkVersion="22" Android:targetSdkVersion="22"/>
  </manifest>
</Android>

アプリを実行しようとすると、次のエラーが発生します。私は3.4.1に取り組んでいます。 APIレベルは22のみです。

[ERROR] :  Failed to package application:
[ERROR] :  
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-mdpi/abc_ab_share_pack_holo_dark.9.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-hdpi/abc_ab_share_pack_holo_dark.9.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xhdpi/abc_ab_share_pack_holo_dark.9.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-hdpi/abc_ab_share_pack_holo_light.9.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xhdpi/abc_ab_share_pack_holo_light.9.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-mdpi/abc_ic_clear_disabled.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-hdpi/abc_ic_clear_disabled.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xhdpi/abc_ic_clear_disabled.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xxhdpi/abc_ic_clear_disabled.png: libpng warning: iCCP: profile 'icc': 'GRAY': Gray color space not permitted on RGB PNG
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-hdpi/abc_ic_clear_normal.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xxhdpi/abc_ic_clear_normal.png: libpng warning: iCCP: profile 'icc': 'GRAY': Gray color space not permitted on RGB PNG
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-mdpi/abc_ic_go.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-hdpi/abc_ic_go.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xhdpi/abc_ic_go.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xxhdpi/abc_ic_go.png: libpng warning: iCCP: profile 'icc': 'GRAY': Gray color space not permitted on RGB PNG
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-mdpi/abc_ic_search.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-hdpi/abc_ic_search.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xhdpi/abc_ic_search.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xxhdpi/abc_ic_search.png: libpng warning: iCCP: profile 'icc': 'GRAY': Gray color space not permitted on RGB PNG
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-mdpi/abc_ic_voice_search.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-hdpi/abc_ic_voice_search.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xhdpi/abc_ic_voice_search.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited
[ERROR] :  /var/folders/7f/5k6k5fvn2fdc5bgtv3hjmgnh0000gn/T/11558-48051-1806d86/res/drawable-xxhdpi/abc_ic_voice_search.png: libpng warning: iCCP: profile 'icc': 'GRAY': Gray color space not permitted on RGB PNG
[ERROR] :  /Users/murali/Documents/Titanium_Studio_Workspace/textboxapp/build/Android/res/values/styles.xml:3: error: A 'type' attribute is required for <item>
[ERROR] Application Installer abnormal process termination. Process exit value was 1.
12
user3921674

警告が示すように、無効なカラープロファイルを持つPNGファイルがたくさんあります。 Libpng16はそれらに関する警告を発行します。アプリケーションは警告をエラーとして扱います。

これを回避するには、次の1つ以上を実行できます。

  • PNGエディターを使用して、エラーレポートにリストされているPNGファイルからiCCPチャンクを削除します。たとえば、ImageMagickの「convert-define png:exclude-chunk = iCCP、zCCP」を使用します。

  • PNGエディターを使用して、すべての補助チャンクを削除します(例:convert -strip)

  • Libpngをバージョン1.5.x(現在はlibpng-1.5.23)にダウングレードします

  • Libpng-1.6.x(現在はlibpng-1.6.17)を「-DPNG_sRGB_PROFILE_CHECKS = -1」で再インストールします

  • アプリケーションに警告をエラーではなく警告として処理させる方法があるかどうかを調べ、それを実行します。

12