<div dir="ltr"><div><div>> Thomas Guillem: You should use asprintf here<br></div></div><div><br></div><div>Gotcha.</div><div><br></div><div><br></div><div>> Thomas Guillem: This code is weird to read.</div><div>> Rémi Denis-Courmont: This would probably be simpler with GLOB_APPEND.</div><div><br></div><div>Yeah, looks like GLOB_APPEND could help here.</div><div><br></div><div><br></div><div><div>> And I don't think VLC has any business in /usr/local unless that is the</div><div>> installation prefix. At this point, you are probably better off with</div><div>> config_GetDataDir().<br></div></div><div><div><br></div><div>Well, that will¹ default to /usr/local/share/vlc, which means that the sound</div><div>fonts installed by the package manager won't be visible unless pointed to by</div><div>the $XDG_DATA_DIRS, but they should(!) because it should default to</div><div>/usr/local/share:/usr/share, as mentioned earlier.</div><div><br></div><div>1 — judging by</div><div> 1. vlc/src/posix/dirs.c: return strdup ((path != NULL) ? path : PKGDATADIR);</div><div> 2. src/Makefile.am: -DPKGDATADIR=\"$(vlcdatadir)\" \</div><div> 3. <a href="http://configure.ac:47">configure.ac:47</a>: vlcdatadir="\${datadir}/\${PKGDIR}"</div><div> 4. <a href="http://configure.ac:12">configure.ac:12</a>: PKGDIR="vlc"</div><div> 5. <a href="https://www.gnu.org/prep/standards/html_node/Directory-Variables.html">https://www.gnu.org/prep/standards/html_node/Directory-Variables.html</a></div><div><br></div><div>So either config_GetDataDir isn't the right source for the information</div><div>or it has incorrect contents. So which one is it?</div></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Feb 25, 2018 at 9:38 PM, Rémi Denis-Courmont <span dir="ltr"><<a href="mailto:remi@remlab.net" target="_blank">remi@remlab.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">Le perjantaina 23. helmikuuta 2018, 11.09.40 EET Raitis V a écrit :<br>
> Hi,<br>
><br>
> The attached patch fixes the issue #19795: <a href="https://trac.videolan" rel="noreferrer" target="_blank">https://trac.videolan</a>.<br>
> org/vlc/ticket/19795<br>
><br>
> I've compiled and tested the functionality on the 2.x branch, but it merges<br>
> with should work on master too.<br>
><br>
> Out of the box soundfont detection didn't work for me on Arch Linux and not<br>
> it doesn't work on NixOS, so that's why I wanted to fix this.<br>
<br>
</span>This would probably be simpler with GLOB_APPEND.<br>
<br>
And I don't think VLC has any business in /usr/local unless that is the<br>
installation prefix. At this point, you are probably better off with<br>
config_GetDataDir().<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
雷米‧德尼-库尔蒙<br>
<a href="https://www.remlab.net/" rel="noreferrer" target="_blank">https://www.remlab.net/</a><br>
</font></span><div class="HOEnZb"><div class="h5"><br>
______________________________<wbr>_________________<br>
vlc-devel mailing list<br>
To unsubscribe or modify your subscription options:<br>
<a href="https://mailman.videolan.org/listinfo/vlc-devel" rel="noreferrer" target="_blank">https://mailman.videolan.org/<wbr>listinfo/vlc-devel</a></div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>Raitis Veinbahs, +371 2236 4708<br></div></div></div>
</div>