<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Thu, May 21, 2015 at 4:03 PM, Jonas Smedegaard <span dir="ltr"><<a href="mailto:dr@jones.dk" target="_blank">dr@jones.dk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Quoting Martin Abente (2015-05-21 21:23:59)<br>
<span class="">> By having  the application-x-squeak-project.svg file in ./activity/<br>
> directory, the "setup.py install" step will create a symlink to that<br>
</span>> file in /usr/share/ icons/sugar/scalable/mimetypes/, in order to<br>
<span class="">> install that file as the icon for a custom mime type declared in<br>
> ./activty/<a href="http://activity.info" target="_blank">activity.info</a>.<br>
<br>
</span>Thanks for the analysis.<br>
<span class=""><br>
<br>
> That same mime type icon is already provided by sugar-artwork<br>
> (sugar-icon-theme), so there is no need for Etoys to provide this<br>
> icon. I have contacted the upstream maintainer, but for the time being<br>
> I recommend to remove the icon with a patch in debian/patches. I have<br>
> attached to this reply the patch<br>
> for <a href="https://anonscm.debian.org/cgit/pkg-sugar/sugar-etoys-activity.git/" target="_blank">https://anonscm.debian.org/cgit/pkg-sugar/sugar-etoys-activity.git/</a><br>
> to do so.<br>
<br>
</span>While it might be the best approach upstream to remove the SVG file<br>
(when possible to ensure that sugar-icon-theme provides it), a smaller<br>
workaround in Debian packaging is to remove the file after it is<br>
installed, with something like this in debian/rules:<br>
<br>
# avoid SVG file already included in sugar-*-icon-theme<br>
install/$(pkg)::<br>
        rm $(cdbs_curdestdir)usr/share/icons/sugar/scalable/mimetypes/application-x-squeak-project.svg </blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<br>
(Order is ensured because CDBS per-binary-package install/* targets are<br>
run after common install target.)<br></blockquote><div><br></div><div>looks ok to me, but it really doesn't make much sense to have different modules/activities providing the same files.<br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<br>
...but, given your analysis, I suspect an even simpler workaround is to<br>
build-depend on sugar-*-icon-theme to not have the symlink generated at<br>
all.  I will test that now...<br>
<br></blockquote><div> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
(...and I will also try patch sugar-toolkit-gtk3 to create relative<br>
symlinks, as they currently reference a path specific to the build<br>
environment build home).<br></blockquote><div><br></div><div>+1</div><div><br></div><div>These [1] are the bits you might be interested in looking. I am working on a related patch to prevent update-mime-database from running while we are building the packages [2] (a related problem).</div><div><br></div><div>Refs:</div><div>1. <a href="https://github.com/sugarlabs/sugar-toolkit-gtk3/blob/master/src/sugar3/bundle/activitybundle.py#L331">https://github.com/sugarlabs/sugar-toolkit-gtk3/blob/master/src/sugar3/bundle/activitybundle.py#L331</a></div><div>2. <a href="https://github.com/tchx84/sugar-toolkit-gtk3/commit/a92b61d6d213cec74485b5dd5aa11acc3a72732b">https://github.com/tchx84/sugar-toolkit-gtk3/commit/a92b61d6d213cec74485b5dd5aa11acc3a72732b</a></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<span class=""><font color="#888888"><br>
 - Jonas<br>
<br>
--<br>
 * Jonas Smedegaard - idealist & Internet-arkitekt<br>
 * Tlf.: <a href="tel:%2B45%2040843136" value="+4540843136">+45 40843136</a>  Website: <a href="http://dr.jones.dk/" target="_blank">http://dr.jones.dk/</a><br>
<br>
 [x] quote me freely  [ ] ask before reusing  [ ] keep private<br>
</font></span></blockquote></div><br></div></div>