[PATCH 2/9] Find modules and config files relative to the installed libraries.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



'Twas brillig, and Colin Guthrie at 20/03/11 13:13 did gyre and gimble:
> 'Twas brillig, and Maarten Bosmans at 19/03/11 12:47 did gyre and gimble:
>> 2011/3/18 Colin Guthrie <gmane at colin.guthr.ie>:
>>> 'Twas brillig, and Maarten Bosmans at 16/03/11 09:55 did gyre and gimble:
>>>> +#ifdef OS_IS_WIN32
>>>> +    {
>>>> +        char *toplevel = pa_win32_get_toplevel(NULL);
>>>> +        c->dl_search_path = pa_sprintf_malloc("%s" PA_PATH_SEP "lib" PA_PATH_SEP "pulse-1.0" PA_PATH_SEP "modules", toplevel);
>>>> +    }
>>>> +#else
>>>
>>> Is there no nicer way to get this path than hard-coding pulse-1.0 here?
>>
>> Makes sense. I didn't do it before because PA_MAJORMINOR is not easily
>> exported to a C define. I now used the fact that VERSION starts with
>> major.minor-. A bit ugly, but this code is only to provide some sane
>> default for the dl_search_path, before this patch you had to always
>> specify it at the command line on Windows.
> 
> In version.h PA_MAJOR and PA_MINOR are defines which might be usable in
> a slightly neater fashion? 

As a coincidence, I had to make a similar change in paprefs a moment ago:

http://git.0pointer.de/?p=paprefs.git;a=commitdiff;h=d7589d48d26289f333fdd623a21e76c5fcb07c8d

-- 

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mageia Contributor [http://www.mageia.org/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]




[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux